summaryrefslogtreecommitdiff
path: root/drivers/mmc/host
diff options
context:
space:
mode:
authorMichał Zegan <webczat@webczatnet.pl>2017-02-18 20:06:47 +0300
committerUlf Hansson <ulf.hansson@linaro.org>2017-04-24 22:41:17 +0300
commita01fc2a295af6418d665d8f9c18af6017a929065 (patch)
treeebd9c36f3190e6db764b2da5543712b045e3340b /drivers/mmc/host
parenteb7c00e1461124ad0e85f1a9a3954d7164809c13 (diff)
downloadlinux-a01fc2a295af6418d665d8f9c18af6017a929065.tar.xz
mmc: meson-gx: remove mmc host on device removal
The mmc host was added in meson_mmc_probe, but never removed in meson_mmc_remove. Fix that by removing the host before deallocating other resources. Signed-off-by: Michał Zegan <webczat@webczatnet.pl> Tested-by: Michał Zegan <webczat@webczatnet.pl> Acked-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/mmc/host')
-rw-r--r--drivers/mmc/host/meson-gx-mmc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/mmc/host/meson-gx-mmc.c b/drivers/mmc/host/meson-gx-mmc.c
index 62597638ccaf..c574e1519623 100644
--- a/drivers/mmc/host/meson-gx-mmc.c
+++ b/drivers/mmc/host/meson-gx-mmc.c
@@ -793,6 +793,8 @@ static int meson_mmc_remove(struct platform_device *pdev)
{
struct meson_host *host = dev_get_drvdata(&pdev->dev);
+ mmc_remove_host(host->mmc);
+
/* disable interrupts */
writel(0, host->regs + SD_EMMC_IRQ_EN);