From a637d0f9ecbeae2a6bdca0fb924bf8961a4cfa47 Mon Sep 17 00:00:00 2001 From: Luca Boccassi Date: Thu, 18 Jul 2019 14:25:30 +0100 Subject: [PATCH] core: set shutdown watchdog on kexec too At the moment the shutdown watchdog is set only when rebooting. The set of "things that can go wrong" is not too far off when kexec'ing and in fact we have a use case where it would be useful - moving to a new kernel image. --- src/core/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/main.c b/src/core/main.c index c6294c2f74..8de3d4753d 100644 --- a/src/core/main.c +++ b/src/core/main.c @@ -1396,7 +1396,7 @@ static int become_shutdown( assert(pos < ELEMENTSOF(command_line)); - if (streq(shutdown_verb, "reboot") && + if (STR_IN_SET(shutdown_verb, "reboot", "kexec") && arg_shutdown_watchdog > 0 && arg_shutdown_watchdog != USEC_INFINITY) {