[linux-yocto] [PATCH 24/29] mmc: sdhci: Fix continuous warning prints in ISR if shared interrupt
rebecca.swee.fun.chang at intel.com
rebecca.swee.fun.chang at intel.com
Mon Apr 7 08:18:15 PDT 2014
From: Maurice Petallo <mauricex.r.petallo at intel.com>
sdhc host may share same interrupt line with other IO devices that
trigger interrupt frequently, like USB. In this case, we encountered
continous prints of warning message "got irq while runtime suspended"
when the interrupt triggered by other IO devices sharing the same line.
To avoid this scenario, first check the interrupt everytime ISR enters.
Signed-off-by: Maurice Petallo <mauricex.r.petallo at intel.com>
---
drivers/mmc/host/sdhci.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index 4e36df8..a1267a8 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -2409,13 +2409,6 @@ static irqreturn_t sdhci_irq(int irq, void *dev_id)
spin_lock(&host->lock);
- if (host->runtime_suspended) {
- spin_unlock(&host->lock);
- pr_warning("%s: got irq while runtime suspended\n",
- mmc_hostname(host->mmc));
- return IRQ_HANDLED;
- }
-
intmask = sdhci_readl(host, SDHCI_INT_STATUS);
if (!intmask || intmask == 0xffffffff) {
@@ -2423,6 +2416,13 @@ static irqreturn_t sdhci_irq(int irq, void *dev_id)
goto out;
}
+ if (host->runtime_suspended) {
+ spin_unlock(&host->lock);
+ pr_warning("%s: got irq while runtime suspended\n",
+ mmc_hostname(host->mmc));
+ return IRQ_HANDLED;
+ }
+
again:
DBG("*** %s got interrupt: 0x%08x\n",
mmc_hostname(host->mmc), intmask);
--
1.7.10.4
More information about the linux-yocto
mailing list