X-Git-Url: http://git.openwrt.org/?a=blobdiff_plain;f=target%2Flinux%2Fcns21xx%2Fpatches-3.10%2F202-cns21xx-add-watchdog-device.patch;fp=target%2Flinux%2Fcns21xx%2Fpatches-3.10%2F202-cns21xx-add-watchdog-device.patch;h=0000000000000000000000000000000000000000;hb=83539ea4ce8f21260b9800189b78ef271f614728;hp=48c69ad232f283cf7a3e2d334b12cf3b5ad41495;hpb=4143cf90aec229f8541d472540ec891a710dc29b;p=openwrt%2Fsvn-archive%2Farchive.git diff --git a/target/linux/cns21xx/patches-3.10/202-cns21xx-add-watchdog-device.patch b/target/linux/cns21xx/patches-3.10/202-cns21xx-add-watchdog-device.patch deleted file mode 100644 index 48c69ad232..0000000000 --- a/target/linux/cns21xx/patches-3.10/202-cns21xx-add-watchdog-device.patch +++ /dev/null @@ -1,63 +0,0 @@ ---- a/arch/arm/mach-cns21xx/common.h -+++ b/arch/arm/mach-cns21xx/common.h -@@ -21,5 +21,6 @@ extern struct sys_timer cns21xx_timer; - int cns21xx_register_uart0(void); - int cns21xx_register_uart1(void); - int cns21xx_register_usb(void); -+int cns21xx_register_wdt(void); - - #endif /* _MACH_CNS21XX_COMMON_H */ ---- a/arch/arm/mach-cns21xx/devices.c -+++ b/arch/arm/mach-cns21xx/devices.c -@@ -11,6 +11,7 @@ - #include - #include - #include -+#include - - #include - #include -@@ -77,3 +78,32 @@ int __init cns21xx_register_uart1(void) - HAL_MISC_ENABLE_UART1_PINS(); - return platform_device_register(&cns21xx_uart1_device); - } -+ -+static struct resource cns21xx_wdt_resources[] = { -+ { -+ .start = CNS21XX_WDT_BASE, -+ .end = CNS21XX_WDT_BASE + SZ_4K - 1, -+ .flags = IORESOURCE_MEM, -+ }, -+}; -+ -+#define CNS21XX_WDT_CLOCK 10 /* 10 Hz */ -+ -+static struct fa_wdt_platform_data cns21xx_wdt_data = { -+ .clock = CNS21XX_WDT_CLOCK, -+}; -+ -+static struct platform_device cns21xx_wdt_device = { -+ .name = "fa-wdt", -+ .id = -1, -+ .resource = cns21xx_wdt_resources, -+ .num_resources = ARRAY_SIZE(cns21xx_wdt_resources), -+ .dev = { -+ .platform_data = &cns21xx_wdt_data, -+ }, -+}; -+ -+int __init cns21xx_register_wdt(void) -+{ -+ return platform_device_register(&cns21xx_wdt_device); -+} ---- a/drivers/watchdog/Kconfig -+++ b/drivers/watchdog/Kconfig -@@ -393,7 +393,7 @@ config RETU_WATCHDOG - - config FA_WATCHDOG - tristate "Faraday watchdog" -- depends on ARCH_GEMINI -+ depends on ARCH_GEMINI || ARCH_CNS21XX - help - Say Y here if you want support for the built-in watchdog timer - found in some Faraday FA526 based SoCs.