On 5/8/25 00:24, Dmitry Baryshkov wrote:
On Wed, May 07, 2025 at 10:35:38PM +0300, Vladimir Zapolskiy wrote:
Trivial change, there is a managed device resource version of
of_platform_populate(), and its usage simplifies the code a bit.

Signed-off-by: Vladimir Zapolskiy <vladimir.zapols...@linaro.org>
---
  drivers/gpu/drm/msm/msm_mdss.c | 4 +---
  1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/msm/msm_mdss.c b/drivers/gpu/drm/msm/msm_mdss.c
index dcb49fd30402..116e8f93f8c8 100644
--- a/drivers/gpu/drm/msm/msm_mdss.c
+++ b/drivers/gpu/drm/msm/msm_mdss.c
@@ -550,7 +550,7 @@ static int mdss_probe(struct platform_device *pdev)
         * Populate the children devices, find the MDP5/DPU node, and then add
         * the interfaces to our components list.
         */
-       ret = of_platform_populate(dev->of_node, NULL, NULL, dev);
+       ret = devm_of_platform_populate(dev);
        if (ret) {
                DRM_DEV_ERROR(dev, "failed to populate children devices\n");
                msm_mdss_destroy(mdss);
@@ -564,8 +564,6 @@ static void mdss_remove(struct platform_device *pdev)
  {
        struct msm_mdss *mdss = platform_get_drvdata(pdev);
- of_platform_depopulate(&pdev->dev);
-
        msm_mdss_destroy(mdss);

Unfortunately this means that the child devices will still exist after
destroying the MDSS (IRQ domain, etc). So, it seems it can not land as
is.

Due to the essense of the change this sounds odd, anyway thanks for review.
I'll perform a test, if it's a regression or not.

  }


--
Best wishes,
Vladimir

Reply via email to