From: Adrian Hunter Date: Tue, 21 Nov 2017 13:42:29 +0000 (+0200) Subject: mmc: core: Do not leave the block driver in a suspended state X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=94497458fbb519dbc230e5156f58d4b3a49ba0c1;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git mmc: core: Do not leave the block driver in a suspended state commit ebe7dd45cf49e3b49cacbaace17f9f878f21fbea upstream. The block driver must be resumed if the mmc bus fails to suspend the card. Signed-off-by: Adrian Hunter Reviewed-by: Linus Walleij Signed-off-by: Ulf Hansson Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/mmc/core/bus.c b/drivers/mmc/core/bus.c index 301246513a37..7f428e387de3 100644 --- a/drivers/mmc/core/bus.c +++ b/drivers/mmc/core/bus.c @@ -157,6 +157,9 @@ static int mmc_bus_suspend(struct device *dev) return ret; ret = host->bus_ops->suspend(host); + if (ret) + pm_generic_resume(dev); + return ret; }