Commit 15447a46 authored by Leon Romanovsky's avatar Leon Romanovsky Committed by Samuel Ortiz

mfd: sec-core: Remove explicit call to mfd_remove_devices

In case mfd_add_devices will fail, it will call to mfd_remove_devices
by itself and return non-zero value.
Signed-off-by: default avatarLeon Romanovsky <leon@leon.nu>
Signed-off-by: default avatarSamuel Ortiz <sameo@linux.intel.com>
parent 45fcac1a
...@@ -230,13 +230,12 @@ static int sec_pmic_probe(struct i2c_client *i2c, ...@@ -230,13 +230,12 @@ static int sec_pmic_probe(struct i2c_client *i2c,
BUG(); BUG();
} }
if (ret < 0) if (ret)
goto err; goto err;
return ret; return ret;
err: err:
mfd_remove_devices(sec_pmic->dev);
sec_irq_exit(sec_pmic); sec_irq_exit(sec_pmic);
i2c_unregister_device(sec_pmic->rtc); i2c_unregister_device(sec_pmic->rtc);
return ret; return ret;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment