提交 0919e444 编写于 作者: F Francesco Lavra 提交者: Wim Van Sebroeck

watchdog: sunxi: fix activation of system reset

Commit f2147de3 ("watchdog: sunxi: support parameterized compatible
strings") introduced a regression in sunxi_wdt_start(), by which
the system reset function of the watchdog is not enabled upon
starting the watchdog. As a result, the system is not reset when the
watchdog expires. Fix it.

Fixes: f2147de3 ("watchdog: sunxi: support parameterized compatible strings")
Signed-off-by: NFrancesco Lavra <francescolavra.fl@gmail.com>
Acked-by: NMaxime Ripard <maxime.ripard@free-electrons.com>
Reviewed-by: NGuenter Roeck <linux@roeck-us.net>
Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
Cc: stable@vger.kernel.org
上级 5724485b
......@@ -184,7 +184,7 @@ static int sunxi_wdt_start(struct watchdog_device *wdt_dev)
/* Set system reset function */
reg = readl(wdt_base + regs->wdt_cfg);
reg &= ~(regs->wdt_reset_mask);
reg |= ~(regs->wdt_reset_val);
reg |= regs->wdt_reset_val;
writel(reg, wdt_base + regs->wdt_cfg);
/* Enable watchdog */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册