]> git.baikalelectronics.ru Git - kernel.git/commit
watchdog: imx2_wdg: notify wdog core to stop ping worker on suspend
authorGrzegorz Jaszczyk <grzegorz.jaszczyk@linaro.org>
Fri, 18 Jun 2021 19:50:33 +0000 (21:50 +0200)
committerWim Van Sebroeck <wim@linux-watchdog.org>
Sun, 22 Aug 2021 08:28:08 +0000 (10:28 +0200)
commit2638316bd56ab33d756a8c15a3f01b424e3c5966
treed6f8b4c189cd9e2baf5c4256cb457378981ee971
parent7a3d553a4b9cc2077b3fd4d95e7cea5bdb7e176d
watchdog: imx2_wdg: notify wdog core to stop ping worker on suspend

Suspend routine disables wdog clk. Nevertheless, the watchdog subsystem
is not aware of that and can still try to ping wdog through
watchdog_ping_work. In order to prevent such condition and therefore
prevent from system hang (caused by the wdog register access issued
while the wdog clock is disabled) notify watchdog core that the ping
worker should be canceled during watchdog core suspend and restored
during resume.

Signed-off-by: Michal Koziel <michal.koziel@emlogic.no>
Signed-off-by: Grzegorz Jaszczyk <grzegorz.jaszczyk@linaro.org>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20210618195033.3209598-3-grzegorz.jaszczyk@linaro.org
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@linux-watchdog.org>
drivers/watchdog/imx2_wdt.c