@@ -523,6 +523,9 @@ sbsa_gwdt:
nowayout:
Watchdog cannot be stopped once started
(default=kernel config parameter)
+ panicnotify:
+ Watchdog to be stopped after kernel panic
+ (default=0, don't stop watchdog on panic)
-------------------------------------------------
@@ -116,6 +116,9 @@ MODULE_PARM_DESC(nowayout,
"Watchdog cannot be stopped once started (default="
__MODULE_STRING(WATCHDOG_NOWAYOUT) ")");
+static int panicnotify;
+module_param(panicnotify, int, 0);
+MODULE_PARM_DESC(panicnotify, "after kernel panic, do: 0 = don't stop wd(*) 1 = stop wd");
/*
* Arm Base System Architecture 1.0 introduces watchdog v1 which
* increases the length watchdog offset register to 48 bits.
@@ -307,6 +310,9 @@ static int sbsa_gwdt_probe(struct platform_device *pdev)
if (status & SBSA_GWDT_WCS_EN)
set_bit(WDOG_HW_RUNNING, &wdd->status);
+ if (!nowayout && panicnotify)
+ watchdog_stop_on_panic(wdd);
+
if (action) {
irq = platform_get_irq(pdev, 0);
if (irq < 0) {
Enable the watchdog stop on panic feature if the module parameter panicnotify is set. sbsa_gwdt.panicnotify=1 will disable the watchdog in panic situations. This helps in avoiding watchdog reset while booting kdump kernel. Signed-off-by: George Cherian <george.cherian@marvell.com> --- Documentation/watchdog/watchdog-parameters.rst | 3 +++ drivers/watchdog/sbsa_gwdt.c | 6 ++++++ 2 files changed, 9 insertions(+)