From: Wolfram Sang Date: Thu, 21 Nov 2019 11:17:33 +0000 (+0100) Subject: Revert "mmc: tmio: remove workaround for NON_REMOVABLE" X-Git-Tag: v5.10.7~3803^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=478c60cea1c1e57f91d8c3f6dfe3d35784ea7eea;p=platform%2Fkernel%2Flinux-rpi.git Revert "mmc: tmio: remove workaround for NON_REMOVABLE" This reverts commit 7a7dab237027939cb95dc07c4647b80bad5fbbde. We found out that there is still a race with RuntimePM. This can lead to a hang when accessing the eMMC in some situations. Revert this change until the RPM issue is fixed. Reported-by: Geert Uytterhoeven Tested-by: Geert Uytterhoeven Signed-off-by: Wolfram Sang Signed-off-by: Ulf Hansson --- diff --git a/drivers/mmc/host/tmio_mmc_core.c b/drivers/mmc/host/tmio_mmc_core.c index 6936b04..dec5a99 100644 --- a/drivers/mmc/host/tmio_mmc_core.c +++ b/drivers/mmc/host/tmio_mmc_core.c @@ -1209,6 +1209,15 @@ int tmio_mmc_host_probe(struct tmio_mmc_host *_host) _host->reset = tmio_mmc_reset; /* + * On Gen2+, eMMC with NONREMOVABLE currently fails because native + * hotplug gets disabled. It seems RuntimePM related yet we need further + * research. Since we are planning a PM overhaul anyway, let's enforce + * for now the device being active by enabling native hotplug always. + */ + if (pdata->flags & TMIO_MMC_MIN_RCAR2) + _host->native_hotplug = true; + + /* * While using internal tmio hardware logic for card detection, we need * to ensure it stays powered for it to work. */