From 1597704bf03a54bca917420f89bbfda67d617d96 Mon Sep 17 00:00:00 2001
From: Sergio Lopez <slp@redhat.com>
Date: Mon, 16 May 2022 16:04:27 +0200
Subject: [PATCH 02/11] krunfw: Ignore run_cmd on orderly reboot

We don't really support restarting the conventional way, so ignore
"run_cmd" so we can fall back to an emergency sync and reboot.

Signed-off-by: Sergio Lopez <slp@redhat.com>
---
 kernel/reboot.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/kernel/reboot.c b/kernel/reboot.c
index a08a8a9b4d88..838b7a293e43 100644
--- a/kernel/reboot.c
+++ b/kernel/reboot.c
@@ -835,7 +835,11 @@ static int __orderly_reboot(void)
 {
 	int ret;
 
+#ifdef VERBOSE_LIBKRUN
 	ret = run_cmd(reboot_cmd);
+#else
+	ret = 1;
+#endif
 
 	if (ret) {
 		pr_warn("Failed to start orderly reboot: forcing the issue\n");
-- 
2.40.0

