提交 124e9deb 编写于 作者: B Benjamin Gaignard 提交者: Lee Jones

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: NBenjamin Gaignard <benjamin.gaignard@linaro.org>
Signed-off-by: NLee Jones <lee.jones@linaro.org>
上级 11ee55d9
......@@ -676,7 +676,7 @@ static int palmas_i2c_probe(struct i2c_client *i2c,
* 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) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册