summaryrefslogtreecommitdiffstats
path: root/drivers/mfd/palmas.c
diff options
context:
space:
mode:
authorBenjamin Gaignard2017-05-29 17:45:59 +0200
committerLee Jones2017-07-06 09:29:12 +0200
commit124e9deb1c40cc8c6fdf56bcb851500423eb9f13 (patch)
tree61ac036219ed2eda6f80ad24c8b19b05757a542a /drivers/mfd/palmas.c
parentmfd: exynos: Use devm_of_platform_populate() (diff)
downloadkernel-qcow2-linux-124e9deb1c40cc8c6fdf56bcb851500423eb9f13.tar.gz
kernel-qcow2-linux-124e9deb1c40cc8c6fdf56bcb851500423eb9f13.tar.xz
kernel-qcow2-linux-124e9deb1c40cc8c6fdf56bcb851500423eb9f13.zip
mfd: palmas: Use devm_of_platform_populate()
Use devm_of_platform_populate() to be sure that of_platform_depopulate is called when removing the driver. Signed-off-by: Benjamin Gaignard <benjamin.gaignard@linaro.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'drivers/mfd/palmas.c')
-rw-r--r--drivers/mfd/palmas.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mfd/palmas.c b/drivers/mfd/palmas.c
index 9103affedcbc..3922a93f9f92 100644
--- a/drivers/mfd/palmas.c
+++ b/drivers/mfd/palmas.c
@@ -676,7 +676,7 @@ no_irq:
* otherwise continue and add devices using mfd helpers.
*/
if (node) {
- ret = of_platform_populate(node, NULL, NULL, &i2c->dev);
+ ret = devm_of_platform_populate(&i2c->dev);
if (ret < 0) {
goto err_irq;
} else if (pdata->pm_off && !pm_power_off) {