[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1529497606-3857-1-git-send-email-minyard@acm.org>
Date: Wed, 20 Jun 2018 07:26:46 -0500
From: minyard@....org
To: Meelis Roos <mroos@...ux.ee>
Cc: Linux Kernel list <linux-kernel@...r.kernel.org>,
openipmi-developer@...ts.sourceforge.net,
Corey Minyard <cminyard@...sta.com>
Subject: [PATCH] ipmi: Cleanup oops on initialization failure
From: Corey Minyard <cminyard@...sta.com>
Commit 93c303d2045b3 "ipmi_si: Clean up shutdown a bit" didn't
copy the behavior of the cleanup in one spot, it needed to
check for a non-NULL interface before cleaning it up.
Signed-off-by: Corey Minyard <cminyard@...sta.com>
---
This patch should fix the issue.
BTW, can you send me at least the IPMI portion of the output of
dmidecode for your machine? I have seen a lot of these where the
address in the SMBIOS tables is incorrect, and I'm wondering if
it's something in the driver, or if it's really the tables that
are bad.
Thanks for reporting this. On your tested-by I'll send this up
to Linus.
-corey
drivers/char/ipmi/ipmi_si_intf.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c
index 3d0add6..a5987f8 100644
--- a/drivers/char/ipmi/ipmi_si_intf.c
+++ b/drivers/char/ipmi/ipmi_si_intf.c
@@ -2088,8 +2088,10 @@ static int try_smi_init(struct smi_info *new_smi)
return 0;
out_err:
- ipmi_unregister_smi(new_smi->intf);
- new_smi->intf = NULL;
+ if (new_smi->intf) {
+ ipmi_unregister_smi(new_smi->intf);
+ new_smi->intf = NULL;
+ }
kfree(init_name);
--
2.7.4
Powered by blists - more mailing lists