From: Michael Olbrich Date: Wed, 2 Feb 2022 14:33:07 +0000 (+0100) Subject: shutdown: don't stop the watchdog X-Git-Tag: v251-rc1~351^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F22375%2Fhead;p=thirdparty%2Fsystemd.git shutdown: don't stop the watchdog This basically reverts #22079. Stopping the watchdog is wrong. The reboot watchdog is supposed to cover the whole time from the point when systemd start systemd-reboot until the hardware resets. Otherwise the system may hang in the final shutdown phase. Add a comment, why keeping the watchdog running is correct here. --- diff --git a/src/shutdown/shutdown.c b/src/shutdown/shutdown.c index 15fd6f93d31..2c3cbec02c8 100644 --- a/src/shutdown/shutdown.c +++ b/src/shutdown/shutdown.c @@ -531,8 +531,9 @@ int main(int argc, char *argv[]) { need_md_detach ? " MD devices," : ""); } - /* We're done with the watchdog. */ - watchdog_close(true); + /* We're done with the watchdog. Note that the watchdog is explicitly not + * stopped here. It remains active to guard against any issues during the + * rest of the shutdown sequence. */ watchdog_free_device(); arguments[0] = NULL;