From 80fad5b959398f347e3b67d8ffdc5a81af1eff82 Mon Sep 17 00:00:00 2001 From: "trenn@suse.de" Date: Tue, 14 Oct 2014 16:40:23 +0200 Subject: [PATCH] ipmi: Unregister previously registered driver in error case Signed-off-by: Thomas Renninger Signed-off-by: Corey Minyard --- drivers/char/ipmi/ipmi_msghandler.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/char/ipmi/ipmi_msghandler.c b/drivers/char/ipmi/ipmi_msghandler.c index 5b08b92c6441..3e8663b1a62b 100644 --- a/drivers/char/ipmi/ipmi_msghandler.c +++ b/drivers/char/ipmi/ipmi_msghandler.c @@ -4435,6 +4435,7 @@ static int ipmi_init_msghandler(void) proc_ipmi_root = proc_mkdir("ipmi", NULL); if (!proc_ipmi_root) { printk(KERN_ERR PFX "Unable to create IPMI proc dir"); + driver_unregister(&ipmidriver.driver); return -ENOMEM; } -- 2.39.5