diff options
| author | Christophe JAILLET <christophe.jaillet@wanadoo.fr> | 2021-02-20 15:29:35 +0100 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-05-11 14:04:02 +0200 |
| commit | 06e48bb631d38215b2c1ccb05930fc97d55fe6e6 (patch) | |
| tree | 377ebee9b4013bab08173c8607e5e638c6b264fd /drivers/mmc/host | |
| parent | 21171ede433752497e8be9805aa2f8585d715d17 (diff) | |
| download | linux-06e48bb631d38215b2c1ccb05930fc97d55fe6e6.tar.gz linux-06e48bb631d38215b2c1ccb05930fc97d55fe6e6.tar.bz2 linux-06e48bb631d38215b2c1ccb05930fc97d55fe6e6.zip | |
mmc: uniphier-sd: Fix an error handling path in uniphier_sd_probe()
commit b03aec1c1f337dfdae44cdb0645ecac34208ae0a upstream.
A 'uniphier_sd_clk_enable()' call should be balanced by a corresponding
'uniphier_sd_clk_disable()' call.
This is done in the remove function, but not in the error handling path of
the probe.
Add the missing call.
Fixes: 3fd784f745dd ("mmc: uniphier-sd: add UniPhier SD/eMMC controller driver")
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Reviewed-by: Masahiro Yamada <masahiroy@kernel.org>
Link: https://lore.kernel.org/r/20210220142935.918554-1-christophe.jaillet@wanadoo.fr
Cc: stable@vger.kernel.org
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/mmc/host')
| -rw-r--r-- | drivers/mmc/host/uniphier-sd.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/mmc/host/uniphier-sd.c b/drivers/mmc/host/uniphier-sd.c index aec9c8ae694c..ec59bef22daa 100644 --- a/drivers/mmc/host/uniphier-sd.c +++ b/drivers/mmc/host/uniphier-sd.c @@ -639,7 +639,7 @@ static int uniphier_sd_probe(struct platform_device *pdev) ret = tmio_mmc_host_probe(host); if (ret) - goto free_host; + goto disable_clk; ret = devm_request_irq(dev, irq, tmio_mmc_irq, IRQF_SHARED, dev_name(dev), host); @@ -650,6 +650,8 @@ static int uniphier_sd_probe(struct platform_device *pdev) remove_host: tmio_mmc_host_remove(host); +disable_clk: + uniphier_sd_clk_disable(host); free_host: tmio_mmc_host_free(host); |
