[Skiboot] [PATCH] IPMI: Fix platform.cec_reboot() null ptr checks

Michael Neuling mikey at neuling.org
Wed Dec 6 11:12:33 AEDT 2017


Kudos to Hugo Landau who reported this in:
  https://github.com/open-power/skiboot/issues/142

Reported-by: Hugo Landau <hlandau at devever.net>
Signed-off-by: Michael Neuling <mikey at neuling.org>
---
 hw/ipmi/ipmi-attn.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/ipmi/ipmi-attn.c b/hw/ipmi/ipmi-attn.c
index ef7153ed7c..8ff872c626 100644
--- a/hw/ipmi/ipmi-attn.c
+++ b/hw/ipmi/ipmi-attn.c
@@ -67,7 +67,7 @@ void __attribute__((noreturn)) ipmi_terminate(const char *msg)
 {
 	/* Terminate called before initializing IPMI (early abort) */
 	if (!ipmi_present()) {
-		if (platform.cec_reboot())
+		if (platform.cec_reboot)
 			platform.cec_reboot();
 		goto out;
 	}
@@ -76,7 +76,7 @@ void __attribute__((noreturn)) ipmi_terminate(const char *msg)
 	ipmi_log_terminate_event(msg);
 
 	/* Reboot call */
-	if (platform.cec_reboot())
+	if (platform.cec_reboot)
 		platform.cec_reboot();
 
 out:
-- 
2.14.1



More information about the Skiboot mailing list