ar71xx: ar934x_nfc: increase DMA retry count
authorGabor Juhos <juhosg@openwrt.org>
Mon, 17 Sep 2012 20:30:54 +0000 (20:30 +0000)
committerGabor Juhos <juhosg@openwrt.org>
Mon, 17 Sep 2012 20:30:54 +0000 (20:30 +0000)
SVN-Revision: 33453

target/linux/ar71xx/files/drivers/mtd/nand/ar934x_nfc.c

index a0f2a6ad5621c383556eb154346a8a82be307c2a..67844e3a48fbf0b0bff7bcba2fdba8af0de094f0 100644 (file)
 #define AR934X_NFC_DEV_READY_TIMEOUT   25 /* msecs */
 #define AR934X_NFC_DMA_READY_TIMEOUT   25 /* msecs */
 #define AR934X_NFC_DONE_TIMEOUT                1000
+#define AR934X_NFC_DMA_RETRIES         20
 
 #define AR934X_NFC_USE_IRQ             true
 #define AR934X_NFC_IRQ_MASK            AR934X_NFC_INT_DEV_RDY(0)
@@ -465,7 +466,7 @@ retry:
                        (write) ? "write" : "read", page_addr);
 
                ar934x_nfc_restart(nfc);
-               if (retries++ < 5)
+               if (retries++ < AR934X_NFC_DMA_RETRIES)
                        goto retry;
 
                dev_err(nfc->parent, "%s operation failed on page %d\n",