]> git.hungrycats.org Git - linux/commitdiff
sdhci-bcm2807: Increase sync_after_dma timeout
authorpopcornmix <popcornmix@gmail.com>
Wed, 10 Jul 2013 22:53:31 +0000 (23:53 +0100)
committerpopcornmix <popcornmix@gmail.com>
Wed, 10 Jul 2013 22:54:23 +0000 (23:54 +0100)
The current timeout is being hit with some cards that complete successfully with a longer timeout.
The timeout is not handled well, and is believed to be a code path that causes corruption.
872a8ff suggests that crappy cards can take up to 3 seconds to respond

drivers/mmc/host/sdhci-bcm2708.c

index a5988019c39a6cc464c730ec63b2c2f20e806619..50ff6bf63ce9a077d36c378e5abf904e23fdc21f 100644 (file)
@@ -842,7 +842,7 @@ static void sdhci_bcm2708_dma_complete_irq(struct sdhci_host *host,
                           We get CRC and DEND errors unless we wait for
                           the SD controller to finish reading/writing to the card. */
                        u32 state_mask;
-                       int timeout=30*5000;
+                       int timeout=3*1000*1000;
 
                        DBG("PDMA over - sync card\n");
                        if (data->flags & MMC_DATA_READ)