From: David Brownell <[EMAIL PROTECTED]>
Sure would be nice to have the watchdog device node created, so
the watchdog driver (already in mainline) binds to something.
Signed-off-by: David Brownell <[EMAIL PROTECTED]>
---
Hmmm ... doesn't apply against mainline.
arch/arm/mach-davinci/devices.c | 33 +++++++++++++++++++++++++++++++++
1 file changed, 33 insertions(+)
--- a/arch/arm/mach-davinci/devices.c
+++ b/arch/arm/mach-davinci/devices.c
@@ -95,6 +95,38 @@ static void davinci_init_mmcsd(void) {}
#endif
+/*-------------------------------------------------------------------------*/
+
+#if defined(CONFIG_DAVINCI_WATCHDOG) || defined(CONFIG_DAVINCI_WATCHDOG_MODULE)
+
+static struct resource wdt_resources[] = {
+ {
+ .start = 0x01c21c00,
+ .end = 0x01c21fff,
+ .flags = IORESOURCE_MEM,
+ },
+};
+
+static struct platform_device davinci_wdt_device = {
+ .name = "watchdog",
+ .id = -1,
+ .num_resources = ARRAY_SIZE(wdt_resources),
+ .resource = wdt_resources,
+};
+
+static void davinci_init_wdt(void)
+{
+ platform_device_register(&davinci_wdt_device);
+}
+
+#else
+
+static void davinci_init_wdt(void) {}
+
+#endif
+
+/*-------------------------------------------------------------------------*/
+
#if defined(CONFIG_TI_DAVINCI_EMAC) || defined(CONFIG_TI_DAVINCI_EMAC_MODULE)
static struct resource emac_resources[] = {
@@ -197,6 +229,7 @@ static int __init davinci_init_devices(v
* in alphabetical order so they're easier to sort through.
*/
davinci_init_mmcsd();
+ davinci_init_wdt();
return 0;
}
_______________________________________________
Davinci-linux-open-source mailing list
[email protected]
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source