linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v5 1/2] watchdog: wdat_wdg: Stop watchdog when rebooting the system
@ 2022-04-26  8:54 Liu Xinpeng
  2022-04-26  8:54 ` [PATCH v5 2/2] watchdog: wdat_wdg: Stop watchdog when uninstalling module Liu Xinpeng
  0 siblings, 1 reply; 2+ messages in thread
From: Liu Xinpeng @ 2022-04-26  8:54 UTC (permalink / raw)
  To: wim, linux, tzungbi; +Cc: linux-watchdog, linux-kernel, Liu Xinpeng

Executing reboot command several times on the machine "Dell
PowerEdge R740", UEFI security detection stopped machine
with the following prompt:

UEFI0082: The system was reset due to a timeout from the watchdog
timer. Check the System Event Log (SEL) or crash dumps from
Operating Sysstem to identify the source that triggered the
watchdog timer reset. Update the firmware or driver for the
identified device.

iDRAC has warning event: "The watchdog timer reset the system".

This patch fixes this issue by adding the reboot notifier.

Signed-off-by: Liu Xinpeng <liuxp11@chinatelecom.cn>
---
 drivers/watchdog/wdat_wdt.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/watchdog/wdat_wdt.c b/drivers/watchdog/wdat_wdt.c
index 9db01d165310..0ef2b918364a 100644
--- a/drivers/watchdog/wdat_wdt.c
+++ b/drivers/watchdog/wdat_wdt.c
@@ -463,6 +463,7 @@ static int wdat_wdt_probe(struct platform_device *pdev)
 		return ret;
 
 	watchdog_set_nowayout(&wdat->wdd, nowayout);
+	watchdog_stop_on_reboot(&wdat->wdd);
 	return devm_watchdog_register_device(dev, &wdat->wdd);
 }
 
-- 
2.23.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [PATCH v5 2/2] watchdog: wdat_wdg: Stop watchdog when uninstalling module
  2022-04-26  8:54 [PATCH v5 1/2] watchdog: wdat_wdg: Stop watchdog when rebooting the system Liu Xinpeng
@ 2022-04-26  8:54 ` Liu Xinpeng
  0 siblings, 0 replies; 2+ messages in thread
From: Liu Xinpeng @ 2022-04-26  8:54 UTC (permalink / raw)
  To: wim, linux, tzungbi; +Cc: linux-watchdog, linux-kernel, Liu Xinpeng

Test shows that wachdog still reboots machine after the module
is removed. Use watchdog_stop_on_unregister to stop the watchdog
on removing.

Signed-off-by: Liu Xinpeng <liuxp11@chinatelecom.cn>
---
 drivers/watchdog/wdat_wdt.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/watchdog/wdat_wdt.c b/drivers/watchdog/wdat_wdt.c
index 0ef2b918364a..6732d7fc4f94 100644
--- a/drivers/watchdog/wdat_wdt.c
+++ b/drivers/watchdog/wdat_wdt.c
@@ -464,6 +464,7 @@ static int wdat_wdt_probe(struct platform_device *pdev)
 
 	watchdog_set_nowayout(&wdat->wdd, nowayout);
 	watchdog_stop_on_reboot(&wdat->wdd);
+	watchdog_stop_on_unregister(&wdat->wdd);
 	return devm_watchdog_register_device(dev, &wdat->wdd);
 }
 
-- 
2.23.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-04-26  9:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-26  8:54 [PATCH v5 1/2] watchdog: wdat_wdg: Stop watchdog when rebooting the system Liu Xinpeng
2022-04-26  8:54 ` [PATCH v5 2/2] watchdog: wdat_wdg: Stop watchdog when uninstalling module Liu Xinpeng

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).