mtd: nand: sunxi: fix NFC_CTL setting
authorBoris Brezillon <boris.brezillon@free-electrons.com>
Fri, 4 Mar 2016 16:29:20 +0000 (17:29 +0100)
committerBoris Brezillon <boris.brezillon@free-electrons.com>
Tue, 19 Apr 2016 20:05:41 +0000 (22:05 +0200)
NFC_PAGE_SHIFT() already takes the real page_shift value and subtract 10
to it.

Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
drivers/mtd/nand/sunxi_nand.c

index 4cb5c6f866ff5daf2fcf51e2b6f29db981195bf7..f8b3a7281af0aa8d3ff8ca1d5bea5e3e59ca5037 100644 (file)
@@ -410,7 +410,7 @@ static void sunxi_nfc_select_chip(struct mtd_info *mtd, int chip)
                sel = &sunxi_nand->sels[chip];
 
                ctl |= NFC_CE_SEL(sel->cs) | NFC_EN |
-                      NFC_PAGE_SHIFT(nand->page_shift - 10);
+                      NFC_PAGE_SHIFT(nand->page_shift);
                if (sel->rb.type == RB_NONE) {
                        nand->dev_ready = NULL;
                } else {