mfd: exynos: 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>
This commit is contained in:
Benjamin Gaignard 2017-05-29 17:45:56 +02:00 committed by Lee Jones
parent a55196eff6
commit 11ee55d94e

View File

@ -138,7 +138,7 @@ static int exynos_lpass_probe(struct platform_device *pdev)
pm_runtime_enable(dev); pm_runtime_enable(dev);
exynos_lpass_enable(lpass); exynos_lpass_enable(lpass);
return of_platform_populate(dev->of_node, NULL, NULL, dev); return devm_of_platform_populate(dev);
} }
static int exynos_lpass_remove(struct platform_device *pdev) static int exynos_lpass_remove(struct platform_device *pdev)