summaryrefslogtreecommitdiff
path: root/drivers/mfd/palmas.c
diff options
context:
space:
mode:
authorBenjamin Gaignard <benjamin.gaignard@linaro.org>2017-05-29 18:45:59 +0300
committerLee Jones <lee.jones@linaro.org>2017-07-06 10:29:12 +0300
commit124e9deb1c40cc8c6fdf56bcb851500423eb9f13 (patch)
tree61ac036219ed2eda6f80ad24c8b19b05757a542a /drivers/mfd/palmas.c
parent11ee55d94e628a9931564372df23ae054834c38f (diff)
downloadlinux-124e9deb1c40cc8c6fdf56bcb851500423eb9f13.tar.xz
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) {