> From: Guenter Roeck <groeck7@xxxxxxxxx> on behalf of Guenter Roeck <linux@xxxxxxxxxxxx> > Sent: Tuesday, February 25, 2025 18:44 > To: George Cherian; wim@xxxxxxxxxxxxxxxxxx; corbet@xxxxxxx > Cc: linux-watchdog@xxxxxxxxxxxxxxx; linux-doc@xxxxxxxxxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx > Subject: Re: [PATCH v2] drivers: watchdog: Add support for panic notifier callback >> On 2/25/25 01:52, George Cherian wrote: >> Watchdog is not turned off in kernel panic situation. >> In certain systems this might prevent the successful loading >> of kdump kernel. The kdump kernel might hit a watchdog reset >> while it is booting. >> >> To avoid such scenarios add a panic notifier call back function >> which can stop the watchdog. This provision can be enabled by >> passing watchdog.stop_on_panic=1 via kernel command-line parameter. >> >> Signed-off-by: George Cherian <george.cherian@xxxxxxxxxxx> >> --- >> Changelog: >> v1 -> v2 >> - Remove the per driver flag setting option > >You didn't actually remove it. My bad .... I didn't really remove the helper function in watchdog.h. > > >> diff --git a/drivers/watchdog/watchdog_core.c b/drivers/watchdog/watchdog_core.c >> index d46d8c8c01f2..8cbebe38b7dd 100644 >> --- a/drivers/watchdog/watchdog_core.c >> +++ b/drivers/watchdog/watchdog_core.c ...> >> +/* Use the following function to stop the watchdog on panic */ >> +static inline void watchdog_stop_on_panic(struct watchdog_device *wdd) >> +{ >> + set_bit(WDOG_STOP_ON_PANIC, &wdd->status); >> +} > >Under what circumstance could or would a _driver_ request this ? >I do not see the use case, sorry. Fixing it up right away and sending v3. Thanks for the review. >Guenter -George