[U-Boot] [RFC PATCH v2 04/10] mtd: nand: pxa3xx_nand: fix early spurious interrupt

Chris Packham judge.packham at gmail.com
Wed Oct 26 03:26:06 CEST 2016


When the nand is first probe, and upon the first command start, the
status bits should be cleared before the interrupts are unmasked.

[ Linux commit 0b14392db2e998157d924085d7913e537ec26121 ]

Cc: Robert Jarzmik <robert.jarzmik at free.fr>
Signed-off-by: Chris Packham <judge.packham at gmail.com>
---

Changes in v2:
- Add reference to Linux commit sha1

 drivers/mtd/nand/pxa3xx_nand.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mtd/nand/pxa3xx_nand.c b/drivers/mtd/nand/pxa3xx_nand.c
index 17cbc8d3d930..4cd1297e1d59 100644
--- a/drivers/mtd/nand/pxa3xx_nand.c
+++ b/drivers/mtd/nand/pxa3xx_nand.c
@@ -477,8 +477,8 @@ static void pxa3xx_nand_start(struct pxa3xx_nand_info *info)
 	ndcr |= NDCR_ND_RUN;
 
 	/* clear status bits and run */
-	nand_writel(info, NDCR, 0);
 	nand_writel(info, NDSR, NDSR_MASK);
+	nand_writel(info, NDCR, 0);
 	nand_writel(info, NDCR, ndcr);
 }
 
-- 
2.10.1



More information about the U-Boot mailing list