Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 297356
b: refs/heads/master
c: 6379b23
h: refs/heads/master
v: v3
  • Loading branch information
Alexander Stein authored and Chris Ball committed Mar 27, 2012
1 parent 00b6050 commit 8a68818
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e6039832bed9a9b967796d7021f17f25b625b616
refs/heads/master: 6379b2375a0c5a6ad437616a4018e6b8fd95e97c
19 changes: 12 additions & 7 deletions trunk/drivers/mmc/host/sdhci.c
Original file line number Diff line number Diff line change
Expand Up @@ -2267,8 +2267,8 @@ static irqreturn_t sdhci_irq(int irq, void *dev_id)
{
irqreturn_t result;
struct sdhci_host *host = dev_id;
u32 intmask;
int cardint = 0;
u32 intmask, unexpected = 0;
int cardint = 0, max_loops = 16;

spin_lock(&host->lock);

Expand All @@ -2286,6 +2286,7 @@ static irqreturn_t sdhci_irq(int irq, void *dev_id)
goto out;
}

again:
DBG("*** %s got interrupt: 0x%08x\n",
mmc_hostname(host->mmc), intmask);

Expand Down Expand Up @@ -2344,19 +2345,23 @@ static irqreturn_t sdhci_irq(int irq, void *dev_id)
intmask &= ~SDHCI_INT_CARD_INT;

if (intmask) {
pr_err("%s: Unexpected interrupt 0x%08x.\n",
mmc_hostname(host->mmc), intmask);
sdhci_dumpregs(host);

unexpected |= intmask;
sdhci_writel(host, intmask, SDHCI_INT_STATUS);
}

result = IRQ_HANDLED;

mmiowb();
intmask = sdhci_readl(host, SDHCI_INT_STATUS);
if (intmask && --max_loops)
goto again;
out:
spin_unlock(&host->lock);

if (unexpected) {
pr_err("%s: Unexpected interrupt 0x%08x.\n",
mmc_hostname(host->mmc), unexpected);
sdhci_dumpregs(host);
}
/*
* We have to delay this as it calls back into the driver.
*/
Expand Down

0 comments on commit 8a68818

Please sign in to comment.