summaryrefslogtreecommitdiff
path: root/drivers/mmc/host/sdhci-sprd.c
diff options
context:
space:
mode:
authorBaolin Wang <baolin.wang@linaro.org>2020-02-12 07:12:59 +0300
committerUlf Hansson <ulf.hansson@linaro.org>2020-03-24 16:35:39 +0300
commit4730831c7d2e28c2e912b2c71066b9cf072f7625 (patch)
tree76d0a990efac4b7c7763194edb336f946e35edc4 /drivers/mmc/host/sdhci-sprd.c
parent1774b0021405b4d312499095f6d3919b5bdf3e3b (diff)
downloadlinux-4730831c7d2e28c2e912b2c71066b9cf072f7625.tar.xz
mmc: host: sdhci: Add a variable to defer to complete requests if needed
When using the host software queue, it will trigger the next request in irq handler without a context switch. But the sdhci_request() can not be called in interrupt context when using host software queue for some host drivers, due to the get_cd() ops can be sleepable. But for some host drivers, such as Spreadtrum host driver, the card is nonremovable, so the get_cd() ops is not sleepable, which means we can complete the data request and trigger the next request in irq handler to remove the context switch for the Spreadtrum host driver. As suggested by Adrian, we should introduce a request_atomic() API to indicate that a request can be called in interrupt context to remove the context switch when using mmc host software queue. But this should be done in another thread to convert the users of mmc host software queue. Thus we can introduce a variable in struct sdhci_host to indicate that we will always to defer to complete requests when using the host software queue. Suggested-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Baolin Wang <baolin.wang@linaro.org> Signed-off-by: Baolin Wang <baolin.wang7@gmail.com> Link: https://lore.kernel.org/r/e693e7a29beb3c1922b333f4603ea81f43d5c5b1.1581478568.git.baolin.wang7@gmail.com Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/mmc/host/sdhci-sprd.c')
0 files changed, 0 insertions, 0 deletions