]> www.infradead.org Git - users/jedix/linux-maple.git/commit
mmc: core: Take into account MMC_CAP_NEED_RSP_BUSY for eMMC HPI commands
authorUlf Hansson <ulf.hansson@linaro.org>
Tue, 4 May 2021 16:12:13 +0000 (18:12 +0200)
committerUlf Hansson <ulf.hansson@linaro.org>
Mon, 24 May 2021 13:12:28 +0000 (15:12 +0200)
commit8c0a2922fa465999b172df646e972c179bfde11a
tree529de0b93aa1cc45c3904d634cf14f2aebb5925d
parent955a0bf2000f0e989b8a196ea788da4ed953233e
mmc: core: Take into account MMC_CAP_NEED_RSP_BUSY for eMMC HPI commands

In mmc_send_hpi_cmd() the host->max_busy_timeout is being validated towards
the timeout for the eMMC HPI command, as to decide whether an R1 or R1B
response should be used.

Although, it has turned out the some host can't cope with that conversion,
but needs R1B, which means MMC_CAP_NEED_RSP_BUSY is set for them. Let's
take this into account, via using the common mmc_prepare_busy_cmd() when
doing the validation, which also avoids some open coding.

Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Shawn Lin <shawn.lin@rock-chips.com>
Acked-by: Avri Altman <avri.altman@wdc.com>
Link: https://lore.kernel.org/r/20210504161222.101536-3-ulf.hansson@linaro.org
drivers/mmc/core/mmc_ops.c