ARM: Merge for-2635-4/watchdog
authorBen Dooks <ben-linux@fluff.org>
Thu, 20 May 2010 10:51:40 +0000 (19:51 +0900)
committerBen Dooks <ben-linux@fluff.org>
Thu, 20 May 2010 10:51:40 +0000 (19:51 +0900)
Merge branch 'for-2635-4/watchdog' into for-2635-4/partial2

Conflicts:
arch/arm/mach-s3c64xx/mach-smdk6410.c
arch/arm/mach-s5p6440/Kconfig
arch/arm/mach-s5p6440/include/mach/map.h
arch/arm/mach-s5p6440/mach-smdk6440.c
arch/arm/mach-s5pv210/Kconfig
arch/arm/mach-s5pv210/include/mach/map.h
arch/arm/mach-s5pv210/mach-smdkv210.c

15 files changed:
arch/arm/mach-s3c2410/include/mach/map.h
arch/arm/mach-s3c64xx/Kconfig
arch/arm/mach-s3c64xx/include/mach/map.h
arch/arm/mach-s3c64xx/mach-smdk6410.c
arch/arm/mach-s5p6440/Kconfig
arch/arm/mach-s5p6440/include/mach/map.h
arch/arm/mach-s5p6440/mach-smdk6440.c
arch/arm/mach-s5pv210/Kconfig
arch/arm/mach-s5pv210/include/mach/map.h
arch/arm/mach-s5pv210/mach-smdkc110.c
arch/arm/mach-s5pv210/mach-smdkv210.c
arch/arm/plat-s3c24xx/devs.c
arch/arm/plat-samsung/Kconfig
arch/arm/plat-samsung/Makefile
arch/arm/plat-samsung/dev-wdt.c [new file with mode: 0644]

index 091c98a..cd3983a 100644 (file)
 #define S3C_PA_USBHOST S3C2410_PA_USBHOST
 #define S3C_PA_HSMMC0      S3C2443_PA_HSMMC
 #define S3C_PA_HSMMC1      S3C2416_PA_HSMMC0
+#define S3C_PA_WDT         S3C2410_PA_WATCHDOG
 #define S3C_PA_NAND        S3C24XX_PA_NAND
 
 #endif /* __ASM_ARCH_MAP_H */
index 11d2353..44a9def 100644 (file)
@@ -93,6 +93,8 @@ config MACH_SMDK6410
        select SAMSUNG_DEV_TS
        select S3C_DEV_USB_HOST
        select S3C_DEV_USB_HSOTG
+       select S3C_DEV_WDT
+       select HAVE_S3C2410_WATCHDOG
        select S3C64XX_SETUP_SDHCI
        select S3C64XX_SETUP_I2C1
        select S3C64XX_SETUP_FB_24BPP
index 9fdd50c..c3e48cd 100644 (file)
 #define S3C_PA_USB_HSOTG       S3C64XX_PA_USB_HSOTG
 #define S3C_VA_USB_HSPHY       S3C64XX_VA_USB_HSPHY
 #define S3C_PA_RTC             S3C64XX_PA_RTC
+#define S3C_PA_WDT             S3C64XX_PA_WATCHDOG
 
 #define SAMSUNG_PA_ADC         S3C64XX_PA_ADC
 
index d0c6e9b..d9a0355 100644 (file)
@@ -266,6 +266,7 @@ static struct platform_device *smdk6410_devices[] __initdata = {
        &smdk6410_smsc911x,
        &s3c_device_adc,
        &s3c_device_ts,
+       &s3c_device_wdt,
 };
 
 #ifdef CONFIG_REGULATOR
index ef00cb7..f066fae 100644 (file)
@@ -18,6 +18,8 @@ config MACH_SMDK6440
        select CPU_S5P6440
        select SAMSUNG_DEV_TS
        select SAMSUNG_DEV_ADC
+       select S3C_DEV_WDT
+       select HAVE_S3C2410_WATCHDOG
        help
          Machine support for the Samsung SMDK6440
 
index d0124f3..44011b9 100644 (file)
@@ -77,6 +77,8 @@
 /* compatibiltiy defines. */
 #define S3C_PA_UART            S5P6440_PA_UART
 #define S3C_PA_IIC             S5P6440_PA_IIC0
+#define S3C_PA_WDT             S5P6440_PA_WDT
+
 #define SAMSUNG_PA_ADC         S5P6440_PA_ADC
 
 #endif /* __ASM_ARCH_MAP_H */
index f994817..8291fec 100644 (file)
@@ -89,6 +89,7 @@ static struct platform_device *smdk6440_devices[] __initdata = {
        &s5p6440_device_iis,
        &s3c_device_adc,
        &s3c_device_ts,
+       &s3c_device_wdt,
 };
 
 static struct s3c2410_ts_mach_info s3c_ts_platform __initdata = {
index 88f81ce..96f4d9b 100644 (file)
@@ -68,6 +68,8 @@ config MACH_SMDKV210
        select ARCH_SPARSEMEM_ENABLE
        select SAMSUNG_DEV_ADC
        select SAMSUNG_DEV_TS
+       select S3C_DEV_WDT
+       select HAVE_S3C2410_WATCHDOG
        help
          Machine support for Samsung SMDKV210
 
@@ -75,6 +77,8 @@ config MACH_SMDKC110
        bool "SMDKC110"
        select CPU_S5PV210
        select ARCH_SPARSEMEM_ENABLE
+       select S3C_DEV_WDT
+       select HAVE_S3C2410_WATCHDOG
        help
          Machine support for Samsung SMDKC110
          S5PC110(MCP) is one of package option of S5PV210
index 6fb7bfd..3a44e1e 100644 (file)
@@ -38,6 +38,8 @@
 
 #define S5PV210_PA_SYSTIMER    (0xE2600000)
 
+#define S5PV210_PA_WATCHDOG    (0xE2700000)
+
 #define S5PV210_PA_UART                (0xE2900000)
 
 #define S5P_PA_UART0           (S5PV210_PA_UART + 0x0)
@@ -96,6 +98,7 @@
 #define S3C_PA_IIC1            S5PV210_PA_IIC1
 #define S3C_PA_IIC2            S5PV210_PA_IIC2
 #define S3C_PA_FB              S5PV210_PA_FB
+#define S3C_PA_WDT             S5PV210_PA_WATCHDOG
 
 #define SAMSUNG_PA_ADC         S5PV210_PA_ADC
 
index 6f9fd32..4c8903c 100644 (file)
@@ -74,6 +74,7 @@ static struct s3c2410_uartcfg smdkv210_uartcfgs[] __initdata = {
 static struct platform_device *smdkc110_devices[] __initdata = {
        &s5pv210_device_iis0,
        &s5pv210_device_ac97,
+       &s3c_device_wdt,
 };
 
 static void __init smdkc110_map_io(void)
index b92beb6..0d46279 100644 (file)
@@ -78,6 +78,7 @@ static struct platform_device *smdkv210_devices[] __initdata = {
        &s5pv210_device_ac97,
        &s3c_device_adc,
        &s3c_device_ts,
+       &s3c_device_wdt,
 };
 
 static struct s3c2410_ts_mach_info s3c_ts_platform __initdata = {
index 5858373..452e184 100644 (file)
@@ -234,32 +234,6 @@ void __init s3c24xx_udc_set_platdata(struct s3c2410_udc_mach_info *pd)
        }
 }
 
-
-/* Watchdog */
-
-static struct resource s3c_wdt_resource[] = {
-       [0] = {
-               .start = S3C24XX_PA_WATCHDOG,
-               .end   = S3C24XX_PA_WATCHDOG + S3C24XX_SZ_WATCHDOG - 1,
-               .flags = IORESOURCE_MEM,
-       },
-       [1] = {
-               .start = IRQ_WDT,
-               .end   = IRQ_WDT,
-               .flags = IORESOURCE_IRQ,
-       }
-
-};
-
-struct platform_device s3c_device_wdt = {
-       .name             = "s3c2410-wdt",
-       .id               = -1,
-       .num_resources    = ARRAY_SIZE(s3c_wdt_resource),
-       .resource         = s3c_wdt_resource,
-};
-
-EXPORT_SYMBOL(s3c_device_wdt);
-
 /* IIS */
 
 static struct resource s3c_iis_resource[] = {
index b787d57..47c8aa7 100644 (file)
@@ -190,6 +190,12 @@ config S3C_DEV_USB_HSOTG
        help
          Compile in platform device definition for USB high-speed OtG
 
+config S3C_DEV_WDT
+       bool
+       default y if ARCH_S3C2410
+       help
+         Complie in platform device definition for Watchdog Timer
+
 config S3C_DEV_NAND
        bool
        help
index 606ec84..d73ee55 100644 (file)
@@ -41,6 +41,7 @@ obj-$(CONFIG_S3C_DEV_FB)      += dev-fb.o
 obj-y                          += dev-uart.o
 obj-$(CONFIG_S3C_DEV_USB_HOST) += dev-usb.o
 obj-$(CONFIG_S3C_DEV_USB_HSOTG)        += dev-usb-hsotg.o
+obj-$(CONFIG_S3C_DEV_WDT)      += dev-wdt.o
 obj-$(CONFIG_S3C_DEV_NAND)     += dev-nand.o
 obj-$(CONFIG_S3C_DEV_RTC)      += dev-rtc.o
 
diff --git a/arch/arm/plat-samsung/dev-wdt.c b/arch/arm/plat-samsung/dev-wdt.c
new file mode 100644 (file)
index 0000000..5efca87
--- /dev/null
@@ -0,0 +1,40 @@
+/* linux/arch/arm/plat-samsung/dev-wdt.c
+ *
+ * Copyright (c) 2004 Simtec Electronics
+ *     Ben Dooks <ben@simtec.co.uk>
+ *
+ * S3C series device definition for the watchdog timer
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+*/
+
+#include <linux/kernel.h>
+#include <linux/platform_device.h>
+
+#include <mach/irqs.h>
+#include <mach/map.h>
+
+#include <plat/devs.h>
+
+static struct resource s3c_wdt_resource[] = {
+       [0] = {
+               .start  = S3C_PA_WDT,
+               .end    = S3C_PA_WDT + SZ_1M - 1,
+               .flags  = IORESOURCE_MEM,
+       },
+       [1] = {
+               .start  = IRQ_WDT,
+               .end    = IRQ_WDT,
+               .flags  = IORESOURCE_IRQ,
+       }
+};
+
+struct platform_device s3c_device_wdt = {
+       .name           = "s3c2410-wdt",
+       .id             = -1,
+       .num_resources  = ARRAY_SIZE(s3c_wdt_resource),
+       .resource       = s3c_wdt_resource,
+};
+EXPORT_SYMBOL(s3c_device_wdt);