diff options
author | Anatolij Gustschin <agust@denx.de> | 2013-09-30 12:52:38 +0200 |
---|---|---|
committer | Stefano Babic <sbabic@denx.de> | 2013-10-31 17:54:03 +0100 |
commit | 723ec69a6b7eeb3e89d35dcf8fd223702ace6125 (patch) | |
tree | e18dc88ce5e592ea93363a39f310e6991c346e96 /drivers/watchdog | |
parent | 77b0e2239a13fa83a745ea9b03994bf780a9738a (diff) | |
download | u-boot-imx-723ec69a6b7eeb3e89d35dcf8fd223702ace6125.zip u-boot-imx-723ec69a6b7eeb3e89d35dcf8fd223702ace6125.tar.gz u-boot-imx-723ec69a6b7eeb3e89d35dcf8fd223702ace6125.tar.bz2 |
imx_watchdog: do not soft-reset while watchdog init
Currently the driver clears WCR_SRS bit when enabling
the watchdog and this causes a software reset. Do not
clear WCR_SRS.
Signed-off-by: Anatolij Gustschin <agust@denx.de>
Diffstat (limited to 'drivers/watchdog')
-rw-r--r-- | drivers/watchdog/imx_watchdog.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/watchdog/imx_watchdog.c b/drivers/watchdog/imx_watchdog.c index 50e602a..d5993b4 100644 --- a/drivers/watchdog/imx_watchdog.c +++ b/drivers/watchdog/imx_watchdog.c @@ -19,6 +19,7 @@ struct watchdog_regs { #define WCR_WDBG 0x02 #define WCR_WDE 0x04 /* WDOG enable */ #define WCR_WDT 0x08 +#define WCR_SRS 0x10 #define WCR_WDW 0x80 #define SET_WCR_WT(x) (x << 8) @@ -45,7 +46,7 @@ void hw_watchdog_init(void) #define CONFIG_WATCHDOG_TIMEOUT_MSECS 128000 #endif timeout = (CONFIG_WATCHDOG_TIMEOUT_MSECS / 500) - 1; - writew(WCR_WDZST | WCR_WDBG | WCR_WDE | WCR_WDT | + writew(WCR_WDZST | WCR_WDBG | WCR_WDE | WCR_WDT | WCR_SRS | WCR_WDW | SET_WCR_WT(timeout), &wdog->wcr); hw_watchdog_reset(); } |