All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 2/2] mmc: dw_mmc: make sure of clearing HLE interrupt
@ 2012-11-28 10:26 Seungwon Jeon
  2012-11-28 10:45 ` James Hogan
  0 siblings, 1 reply; 5+ messages in thread
From: Seungwon Jeon @ 2012-11-28 10:26 UTC (permalink / raw)
  To: linux-mmc
  Cc: 'Chris Ball', 'Will Newton',
	'James Hogan', 'Jaehoon Chung'

Even though HLE interrupt is enabled, there is no touch.
This patch clears HLE interrupt which is not unhandled.

Signed-off-by: Seungwon Jeon <tgih.jun@samsung.com>
---
 drivers/mmc/host/dw_mmc.c |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)

diff --git a/drivers/mmc/host/dw_mmc.c b/drivers/mmc/host/dw_mmc.c
index 6785d62..b6db0ae 100644
--- a/drivers/mmc/host/dw_mmc.c
+++ b/drivers/mmc/host/dw_mmc.c
@@ -1009,6 +1009,11 @@ static void dw_mci_tasklet_func(unsigned long priv)
 	state = host->state;
 	data = host->data;
 
+	if (host->cmd_status & SDMMC_INT_HLE) {
+		dev_err(host->dev, "hardware locked write error\n");
+		goto unlock;
+	}
+
 	do {
 		prev_state = state;
 
@@ -1577,6 +1582,12 @@ static irqreturn_t dw_mci_interrupt(int irq, void *dev_id)
 		if (!pending)
 			break;
 
+		if (pending & SDMMC_INT_HLE) {
+			mci_writel(host, RINTSTS, SDMMC_INT_HLE);
+			host->cmd_status = pending;
+			tasklet_schedule(&host->tasklet);
+		}
+
 		if (pending & DW_MCI_CMD_ERROR_FLAGS) {
 			mci_writel(host, RINTSTS, DW_MCI_CMD_ERROR_FLAGS);
 			host->cmd_status = pending;
-- 
1.7.0.4



^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-11-30 11:50 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-11-28 10:26 [PATCH 2/2] mmc: dw_mmc: make sure of clearing HLE interrupt Seungwon Jeon
2012-11-28 10:45 ` James Hogan
2012-11-29  7:35   ` Seungwon Jeon
2012-11-29 14:59     ` Jae hoon Chung
2012-11-30 11:49       ` Seungwon Jeon

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.