]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
drm/mcde: Fix an error handling path in 'mcde_probe()'
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Thu, 22 Aug 2019 21:15:18 +0000 (23:15 +0200)
committerMarcelo Henrique Cerri <marcelo.cerri@canonical.com>
Fri, 17 Jan 2020 17:23:34 +0000 (14:23 -0300)
BugLink: https://bugs.launchpad.net/bugs/1856334
[ Upstream commit 15c665bb4637310bc8ce5f357b6a6e5a8aafc7c1 ]

If we don't find any matching components, we should go through the error
handling path, in order to free some resources.

Fixes: ca5be902a87d ("drm/mcde: Fix uninitialized variable")
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20190822211518.5578-1-christophe.jaillet@wanadoo.fr
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Connor Kuehl <connor.kuehl@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
drivers/gpu/drm/mcde/mcde_drv.c

index a810568c76df753966a7ea2e1339127e756ad800..1bd744231aada54c3e3a8402ed15b071c45cd4fc 100644 (file)
@@ -487,7 +487,8 @@ static int mcde_probe(struct platform_device *pdev)
        }
        if (!match) {
                dev_err(dev, "no matching components\n");
-               return -ENODEV;
+               ret = -ENODEV;
+               goto clk_disable;
        }
        if (IS_ERR(match)) {
                dev_err(dev, "could not create component match\n");