diff options
Diffstat (limited to 'drivers/gpu/drm/omapdrm/dss/dss.c')
-rw-r--r-- | drivers/gpu/drm/omapdrm/dss/dss.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/gpu/drm/omapdrm/dss/dss.c b/drivers/gpu/drm/omapdrm/dss/dss.c index 1aaf260aa9b8..7553c7fc1c45 100644 --- a/drivers/gpu/drm/omapdrm/dss/dss.c +++ b/drivers/gpu/drm/omapdrm/dss/dss.c | |||
@@ -1484,16 +1484,23 @@ static int dss_probe(struct platform_device *pdev) | |||
1484 | dss); | 1484 | dss); |
1485 | 1485 | ||
1486 | /* Add all the child devices as components. */ | 1486 | /* Add all the child devices as components. */ |
1487 | r = of_platform_populate(pdev->dev.of_node, NULL, NULL, &pdev->dev); | ||
1488 | if (r) | ||
1489 | goto err_uninit_debugfs; | ||
1490 | |||
1487 | omapdss_gather_components(&pdev->dev); | 1491 | omapdss_gather_components(&pdev->dev); |
1488 | 1492 | ||
1489 | device_for_each_child(&pdev->dev, &match, dss_add_child_component); | 1493 | device_for_each_child(&pdev->dev, &match, dss_add_child_component); |
1490 | 1494 | ||
1491 | r = component_master_add_with_match(&pdev->dev, &dss_component_ops, match); | 1495 | r = component_master_add_with_match(&pdev->dev, &dss_component_ops, match); |
1492 | if (r) | 1496 | if (r) |
1493 | goto err_uninit_debugfs; | 1497 | goto err_of_depopulate; |
1494 | 1498 | ||
1495 | return 0; | 1499 | return 0; |
1496 | 1500 | ||
1501 | err_of_depopulate: | ||
1502 | of_platform_depopulate(&pdev->dev); | ||
1503 | |||
1497 | err_uninit_debugfs: | 1504 | err_uninit_debugfs: |
1498 | dss_debugfs_remove_file(dss->debugfs.clk); | 1505 | dss_debugfs_remove_file(dss->debugfs.clk); |
1499 | dss_debugfs_remove_file(dss->debugfs.dss); | 1506 | dss_debugfs_remove_file(dss->debugfs.dss); |
@@ -1522,6 +1529,8 @@ static int dss_remove(struct platform_device *pdev) | |||
1522 | { | 1529 | { |
1523 | struct dss_device *dss = platform_get_drvdata(pdev); | 1530 | struct dss_device *dss = platform_get_drvdata(pdev); |
1524 | 1531 | ||
1532 | of_platform_depopulate(&pdev->dev); | ||
1533 | |||
1525 | component_master_del(&pdev->dev, &dss_component_ops); | 1534 | component_master_del(&pdev->dev, &dss_component_ops); |
1526 | 1535 | ||
1527 | dss_debugfs_remove_file(dss->debugfs.clk); | 1536 | dss_debugfs_remove_file(dss->debugfs.clk); |