[PATCH 5/7] at91sam9263: add wathdog support
Jean-Christophe PLAGNIOL-VILLARD
plagnioj at jcrosoft.com
Fri Nov 16 12:03:03 EST 2012
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj at jcrosoft.com>
---
arch/arm/mach-at91/at91sam9263_devices.c | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/arch/arm/mach-at91/at91sam9263_devices.c b/arch/arm/mach-at91/at91sam9263_devices.c
index e686480..0386d79 100644
--- a/arch/arm/mach-at91/at91sam9263_devices.c
+++ b/arch/arm/mach-at91/at91sam9263_devices.c
@@ -10,6 +10,7 @@
*
*/
#include <common.h>
+#include <init.h>
#include <sizes.h>
#include <asm/armlinux.h>
#include <asm/hardware.h>
@@ -351,3 +352,13 @@ void at91_add_device_mci(short mmc_id, struct atmel_mci_platform_data *data)
void at91_add_device_mci(short mmc_id, struct atmel_mci_platform_data *data) {}
#endif
+#ifdef CONFIG_WATCHDOG_AT91SAM9X
+static int at91_add_device_watchdog(void)
+{
+ add_generic_device("at91sam9_wdt", DEVICE_ID_SINGLE, NULL,
+ AT91_WDT + AT91_BASE_SYS, 16, IORESOURCE_MEM, NULL);
+
+ return 0;
+}
+coredevice_initcall(at91_add_device_watchdog);
+#endif
--
1.7.10.4
More information about the barebox
mailing list