Commit ac97c937 authored by Eliav Farber's avatar Eliav Farber Committed by Wim Van Sebroeck

watchdog: sp805: disable watchdog on remove

Disable the watchdog if it is active while removing the module.
It is necessary in order to prevent a reset in case watchdog
hw was running before the removal.
Signed-off-by: default avatarEliav Farber <farbere@amazon.com>
Reviewed-by: default avatarGuenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20220414054233.1357-2-farbere@amazon.comSigned-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
Signed-off-by: default avatarWim Van Sebroeck <wim@linux-watchdog.org>
parent a7ceca43
...@@ -272,6 +272,7 @@ sp805_wdt_probe(struct amba_device *adev, const struct amba_id *id) ...@@ -272,6 +272,7 @@ sp805_wdt_probe(struct amba_device *adev, const struct amba_id *id)
watchdog_set_nowayout(&wdt->wdd, nowayout); watchdog_set_nowayout(&wdt->wdd, nowayout);
watchdog_set_drvdata(&wdt->wdd, wdt); watchdog_set_drvdata(&wdt->wdd, wdt);
watchdog_set_restart_priority(&wdt->wdd, 128); watchdog_set_restart_priority(&wdt->wdd, 128);
watchdog_stop_on_unregister(&wdt->wdd);
/* /*
* If 'timeout-sec' devicetree property is specified, use that. * If 'timeout-sec' devicetree property is specified, use that.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment