提交 0a8fd09c 编写于 作者: A Alexey Neyman 提交者: Chris Ball

mmc: sdhci: Avoid needless loop while handling SDIO interrupts in sdhci_irq

Ignore Card Interrupt bit in the interrupt status if we already
know that mmc_signal_sdio_irq() is going to be called at the end of
sdhci_irq(). This avoids a needless loop in sdhci_irq() repeatedly
reading interrupt status and doing nothing.
Signed-off-by: NAlexey Neyman <stilor@att.net>
Acked-by: NDong Aisheng <b29396@freescale.com>
Signed-off-by: NChris Ball <cjb@laptop.org>
上级 4d223782
......@@ -2501,6 +2501,14 @@ static irqreturn_t sdhci_irq(int irq, void *dev_id)
result = IRQ_HANDLED;
intmask = sdhci_readl(host, SDHCI_INT_STATUS);
/*
* If we know we'll call the driver to signal SDIO IRQ, disregard
* further indications of Card Interrupt in the status to avoid a
* needless loop.
*/
if (cardint)
intmask &= ~SDHCI_INT_CARD_INT;
if (intmask && --max_loops)
goto again;
out:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册