* [PATCH] mmc: host: sdhci: prevent mmcqd from becoming locked on mmc timeout
@ 2013-11-09 11:06 Neal Buckendahl
0 siblings, 0 replies; 3+ messages in thread
From: Neal Buckendahl @ 2013-11-09 11:06 UTC (permalink / raw)
To: nealb001, cjb; +Cc: linux-mmc, linux-kernel
fixed a condition where device issues a status cmd to sdcard but no response
comes from sdcard. The sdhci irq fires and we hit a timeout case which calls
sdhci_finish_data(). sdhci_finish_data eventually attempt to reset controller
and issues stop cmd. However mmcdq is wait_for_completion(&mrq->completion)
in function mmc_wait_for_req_done which never occurs.
Signed-off-by: Neal Buckendahl <nealb001@gmail.com>
---
drivers/mmc/host/sdhci.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index 6785fb1..480730f 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -973,6 +973,8 @@ static void sdhci_finish_data(struct sdhci_host *host)
if (data->error) {
sdhci_reset(host, SDHCI_RESET_CMD);
sdhci_reset(host, SDHCI_RESET_DATA);
+ host->mrq->cmd->error = -ETIMEDOUT;
+ tasklet_schedule(&host->finish_tasklet);
}
sdhci_send_command(host, data->stop);
--
1.7.10.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH] mmc: host: sdhci: prevent mmcqd from becoming locked on mmc timeout
@ 2013-11-14 4:22 Neal Buckendahl
0 siblings, 0 replies; 3+ messages in thread
From: Neal Buckendahl @ 2013-11-14 4:22 UTC (permalink / raw)
To: nealb001, cjb, narayan.1979, prakity; +Cc: linux-mmc, linux-kernel
fixed a condition where device issues a status cmd to sdcard but no response
comes from sdcard. The sdhci irq fires and we hit a timeout case which calls
sdhci_finish_data(). sdhci_finish_data eventually attempt to reset controller
and issues stop cmd. However mmcdq is wait_for_completion(&mrq->completion)
in function mmc_wait_for_req_done which never occurs.
Signed-off-by: Neal Buckendahl <nealb001@gmail.com>
Signed-off-by: Narayanan Gopalakrishnan <narayan.1979@gmail.com>
Signed-off-by: Philip Rakity <prakity@nvidia.com>
---
drivers/mmc/host/sdhci.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index 6785fb1..21620d2 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -973,6 +973,11 @@ static void sdhci_finish_data(struct sdhci_host *host)
if (data->error) {
sdhci_reset(host, SDHCI_RESET_CMD);
sdhci_reset(host, SDHCI_RESET_DATA);
+ if (data->error == -ETIMEDOUT) {
+ host->mrq->cmd->error = -ETIMEDOUT;
+ tasklet_schedule(&host->finish_tasklet);
+ WARN_ON(1);
+ }
}
sdhci_send_command(host, data->stop);
--
1.7.10.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH] mmc: host: sdhci: prevent mmcqd from becoming locked on mmc timeout
@ 2013-11-14 16:36 Neal Buckendahl
0 siblings, 0 replies; 3+ messages in thread
From: Neal Buckendahl @ 2013-11-14 16:36 UTC (permalink / raw)
To: nealb001, cjb, narayan.1979, prakity; +Cc: linux-mmc, linux-kernel
fixed a condition where device issues a status cmd to sdcard but no response
comes from sdcard. The sdhci irq fires and we hit a timeout case which calls
sdhci_finish_data(). sdhci_finish_data eventually attempt to reset controller
and issues stop cmd. However mmcdq is wait_for_completion(&mrq->completion)
in function mmc_wait_for_req_done which never occurs.
Signed-off-by: Neal Buckendahl <nealb001@gmail.com>
Signed-off-by: Narayanan Gopalakrishnan <narayan.1979@gmail.com>
Signed-off-by: Philip Rakity <prakity@nvidia.com>
---
drivers/mmc/host/sdhci.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index 6785fb1..2a703f0 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -973,6 +973,10 @@ static void sdhci_finish_data(struct sdhci_host *host)
if (data->error) {
sdhci_reset(host, SDHCI_RESET_CMD);
sdhci_reset(host, SDHCI_RESET_DATA);
+ if (data->error == -ETIMEDOUT) {
+ host->mrq->cmd->error = -ETIMEDOUT;
+ tasklet_schedule(&host->finish_tasklet);
+ }
}
sdhci_send_command(host, data->stop);
--
1.7.10.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-11-14 16:36 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-11-14 16:36 [PATCH] mmc: host: sdhci: prevent mmcqd from becoming locked on mmc timeout Neal Buckendahl
-- strict thread matches above, loose matches on Subject: below --
2013-11-14 4:22 Neal Buckendahl
2013-11-09 11:06 Neal Buckendahl
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).