drm/omap: dss: Gather OMAP DSS components at probe time
authorLaurent Pinchart <[email protected]>
Thu, 1 Mar 2018 19:51:43 +0000 (21:51 +0200)
committerTomi Valkeinen <[email protected]>
Mon, 3 Sep 2018 13:13:25 +0000 (16:13 +0300)
The omapdss_gather_components() function walks the OF graph to create a
list of all components part of the display device. There's no need to
delay this operation until DSS bind time as we have all the information
we need at probe time.

Signed-off-by: Laurent Pinchart <[email protected]>
Reviewed-by: Sebastian Reichel <[email protected]>
Signed-off-by: Tomi Valkeinen <[email protected]>
drivers/gpu/drm/omapdrm/dss/dss.c

index cb80ddaa19d265e63f739e32d96ea0b7aecfcf65..9af7108dbf5f4b26bcf0076ebf6ac48f14608cf6 100644 (file)
@@ -1323,7 +1323,6 @@ static int dss_bind(struct device *dev)
 
        pm_set_vt_switch(0);
 
-       omapdss_gather_components(dev);
        omapdss_set_dss(dss);
 
        return 0;
@@ -1474,6 +1473,8 @@ static int dss_probe(struct platform_device *pdev)
                                                   dss);
 
        /* Add all the child devices as components. */
+       omapdss_gather_components(&pdev->dev);
+
        device_for_each_child(&pdev->dev, &match, dss_add_child_component);
 
        r = component_master_add_with_match(&pdev->dev, &dss_component_ops, match);