aboutsummaryrefslogtreecommitdiff
path: root/board/davedenx/qong
diff options
context:
space:
mode:
authorStefano Babic <sbabic@denx.de>2011-02-02 00:49:37 +0000
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2011-04-27 19:38:04 +0200
commit8640c984633de10f6d15211077496b3705df32d0 (patch)
treec6873ddfb637e430af2e9eebf2b39b7e86d0a9cf /board/davedenx/qong
parent2cf36ae7cf897b2a942db98e9e826539961fb55d (diff)
MX31: qong: add watchdog
Signed-off-by: Stefano Babic <sbabic@denx.de>
Diffstat (limited to 'board/davedenx/qong')
-rw-r--r--board/davedenx/qong/qong.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/board/davedenx/qong/qong.c b/board/davedenx/qong/qong.c
index 8a81cfc68..3ace6cdff 100644
--- a/board/davedenx/qong/qong.c
+++ b/board/davedenx/qong/qong.c
@@ -30,9 +30,17 @@
#include <fsl_pmic.h>
#include <mxc_gpio.h>
#include "qong_fpga.h"
+#include <watchdog.h>
DECLARE_GLOBAL_DATA_PTR;
+#ifdef CONFIG_HW_WATCHDOG
+void hw_watchdog_reset(void)
+{
+ mxc_hw_watchdog_reset();
+}
+#endif
+
int dram_init (void)
{
/* dram_init must store complete ramsize in gd->ram_size */
@@ -202,6 +210,10 @@ int board_late_init(void)
pmic_reg_write(REG_POWER_CTL0, val | COINCHEN);
pmic_reg_write(REG_INT_STATUS1, RTCRSTI);
+#ifdef CONFIG_HW_WATCHDOG
+ mxc_hw_watchdog_enable();
+#endif
+
return 0;
}