]> Pileus Git - ~andy/linux/blobdiff - drivers/mmc/core/sdio_irq.c
Merge tag 'mmc-updates-for-3.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel...
[~andy/linux] / drivers / mmc / core / sdio_irq.c
index 3d8ceb4084debf900693f07f1bb7a5d8588cdfab..aaa90460ed234c1d6744f5cef073f053c18c1afb 100644 (file)
@@ -53,6 +53,17 @@ static int process_sdio_pending_irqs(struct mmc_host *host)
                return ret;
        }
 
+       if (pending && mmc_card_broken_irq_polling(card) &&
+           !(host->caps & MMC_CAP_SDIO_IRQ)) {
+               unsigned char dummy;
+
+               /* A fake interrupt could be created when we poll SDIO_CCCR_INTx
+                * register with a Marvell SD8797 card. A dummy CMD52 read to
+                * function 0 register 0xff can avoid this.
+                */
+               mmc_io_rw_direct(card, 0, 0, 0xff, 0, &dummy);
+       }
+
        count = 0;
        for (i = 1; i <= 7; i++) {
                if (pending & (1 << i)) {