]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
mmc: core: Respect MMC_CAP_NEED_RSP_BUSY for eMMC sleep command
authorUlf Hansson <ulf.hansson@linaro.org>
Tue, 24 Mar 2020 18:06:48 +0000 (19:06 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 1 Apr 2020 08:59:32 +0000 (10:59 +0200)
commite67e04f08ad706457c71a38d5b26a50526278bcc
treed2f81773e16c084cd7e5c4764f8426abacaa8020
parent224d92041f249778bd0f5a4ca65a3045eb81685a
mmc: core: Respect MMC_CAP_NEED_RSP_BUSY for eMMC sleep command

[ Upstream commit 18d200460cd73636d4f20674085c39e32b4e0097 ]

The busy timeout for the CMD5 to put the eMMC into sleep state, is specific
to the card. Potentially the timeout may exceed the host->max_busy_timeout.
If that becomes the case, mmc_sleep() converts from using an R1B response
to an R1 response, as to prevent the host from doing HW busy detection.

However, it has turned out that some hosts requires an R1B response no
matter what, so let's respect that via checking MMC_CAP_NEED_RSP_BUSY. Note
that, if the R1B gets enforced, the host becomes fully responsible of
managing the needed busy timeout, in one way or the other.

Suggested-by: Sowjanya Komatineni <skomatineni@nvidia.com>
Cc: <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/20200311092036.16084-1-ulf.hansson@linaro.org
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/mmc/core/mmc.c