LF-3211 watchdog: imx7ulp: Add explict memory barrier for unlock sequence
Add explict memory barrier for the wdog unlock sequence. Suggested-by: Ye Li <ye.li@nxp.com> Signed-off-by: Jacky Bai <ping.bai@nxp.com> Reviewed-by: Ye Li <ye.li@nxp.com> (cherry picked from commit 59ec9bb1baaad40175aac6da16e1b000e5d5ee70) Signed-off-by: Andrey Zhizhikin <andrey.zhizhikin@leica-geosystems.com>
This commit is contained in:
parent
817fc45854
commit
b90cef338f
|
@ -179,9 +179,13 @@ static int imx7ulp_wdt_init(void __iomem *base, unsigned int timeout)
|
|||
int ret;
|
||||
|
||||
local_irq_disable();
|
||||
|
||||
mb();
|
||||
/* unlock the wdog for reconfiguration */
|
||||
writel_relaxed(UNLOCK_SEQ0, base + WDOG_CNT);
|
||||
writel_relaxed(UNLOCK_SEQ1, base + WDOG_CNT);
|
||||
mb();
|
||||
|
||||
ret = imx7ulp_wdt_wait(base, WDOG_CS_ULK);
|
||||
if (ret)
|
||||
goto init_out;
|
||||
|
|
Loading…
Reference in New Issue