]> Git Repo - linux.git/commitdiff
drm/mcde: Fix unbalanced regulator
authorLinus Walleij <[email protected]>
Sun, 8 Nov 2020 11:35:35 +0000 (12:35 +0100)
committerLinus Walleij <[email protected]>
Tue, 10 Nov 2020 23:27:53 +0000 (00:27 +0100)
Since we now turn off the EPOD regulator to reset the
hardware, we need to balance the regulators after that
point. If registering the master fails we only need
to disable one regulator. Fix this by open-coding
this leg of the error path.

Fixes: c4842d4d0f74 ("drm/mcde: Fix display pipeline restart")
Signed-off-by: Linus Walleij <[email protected]>
Reviewed-by: Sam Ravnborg <[email protected]>
Cc: Stephan Gerhold <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
drivers/gpu/drm/mcde/mcde_drv.c

index c592957ed07fc7c247db06929dd8768f11a8fa06..92f8bd907193f56c1c8916fe558414e8eb67393d 100644 (file)
@@ -413,7 +413,13 @@ static int mcde_probe(struct platform_device *pdev)
                                              match);
        if (ret) {
                dev_err(dev, "failed to add component master\n");
-               goto clk_disable;
+               /*
+                * The EPOD regulator is already disabled at this point so some
+                * special errorpath code is needed
+                */
+               clk_disable_unprepare(mcde->mcde_clk);
+               regulator_disable(mcde->vana);
+               return ret;
        }
 
        return 0;
This page took 0.057383 seconds and 4 git commands to generate.