aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitry Osipenko <[email protected]>2020-03-09 01:38:08 +0300
committerThierry Reding <[email protected]>2020-03-12 10:26:19 +0100
commit0411ea89a689531e1829fdf8af3747646c02c721 (patch)
tree6b97addab3aad4918f56a5ae3f6549c7f51d8c19
parenta858ac8f4033ee2375bfba4dc333f5c8a8ee996a (diff)
drm/tegra: dc: Release PM and RGB output when client's registration fails
Runtime PM and RGB output need to be released when host1x client registration fails. The releasing is missed in the code, let's correct it. Signed-off-by: Dmitry Osipenko <[email protected]> Signed-off-by: Thierry Reding <[email protected]>
-rw-r--r--drivers/gpu/drm/tegra/dc.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/gpu/drm/tegra/dc.c b/drivers/gpu/drm/tegra/dc.c
index 257163dda301..56d933e81797 100644
--- a/drivers/gpu/drm/tegra/dc.c
+++ b/drivers/gpu/drm/tegra/dc.c
@@ -2586,10 +2586,16 @@ static int tegra_dc_probe(struct platform_device *pdev)
if (err < 0) {
dev_err(&pdev->dev, "failed to register host1x client: %d\n",
err);
- return err;
+ goto disable_pm;
}
return 0;
+
+disable_pm:
+ pm_runtime_disable(&pdev->dev);
+ tegra_dc_rgb_remove(dc);
+
+ return err;
}
static int tegra_dc_remove(struct platform_device *pdev)