diff mbox

fast-reset: disable fast reboot in event of platform error

Message ID 1477384718-3959-1-git-send-email-stewart@linux.vnet.ibm.com
State Accepted
Headers show

Commit Message

Stewart Smith Oct. 25, 2016, 8:38 a.m. UTC
Most of the time, if we're rebooting due to a platform error, we should
trigger a checkstop. However, if we haven't been told what we should do
to trigger a checkstop (e.g. on an FSP machine), then we should still
fail to fast-reboot.

So, disable fast-reboot in the OPAL_CEC_REBOOT2 code path
for OPAL_REBOOT_PLATFORM_ERROR reboot type.

We don't save the reason for the platform error as that's already
been error logged.

Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
---
 core/platform.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox

Patch

diff --git a/core/platform.c b/core/platform.c
index b37346eddbc2..9171fa367568 100644
--- a/core/platform.c
+++ b/core/platform.c
@@ -89,6 +89,7 @@  static int64_t opal_cec_reboot2(uint32_t reboot_type, char *diag)
 		} else {
 			prerror("OPAL: failed to log an error\n");
 		}
+		disable_fast_reboot("Reboot due to Platform Error");
 		return xscom_trigger_xstop();
 	default:
 		prlog(PR_NOTICE, "OPAL: Unsupported reboot request %d\n", reboot_type);