mirror of
https://git.codelinaro.org/clo/qsdk/oss/boot/u-boot-2016.git
synced 2026-03-06 17:30:35 +01:00
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>
This commit is contained in:
parent
77b0e2239a
commit
723ec69a6b
1 changed files with 2 additions and 1 deletions
|
|
@ -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();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue