diff --git a/drivers/hwmon/ibmpex.c b/drivers/hwmon/ibmpex.c index fe2c2616c6b1e45057ce29adaa35748c71a4b0a7..c462824ffccfe9936d0f6236dc8788a3d5d2dacf 100644 --- a/drivers/hwmon/ibmpex.c +++ b/drivers/hwmon/ibmpex.c @@ -498,8 +498,7 @@ static void ibmpex_register_bmc(int iface, struct device *dev) printk(KERN_ERR DRVNAME ": Error, unable to register hwmon " "class device for interface %d\n", data->interface); - kfree(data); - return; + goto out_user; } /* finally add the new bmc data to the bmc data list */