[PATCH v2 2/2] nand: brcmnand: fix hamming oob layout

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



First 2 bytes are used in large-page nand.

Signed-off-by: Álvaro Fernández Rojas <noltari@xxxxxxxxx>
---
 v2: extend original comment

 drivers/mtd/nand/raw/brcmnand/brcmnand.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mtd/nand/raw/brcmnand/brcmnand.c b/drivers/mtd/nand/raw/brcmnand/brcmnand.c
index 767343e0e6e7..0a1d76fde37b 100644
--- a/drivers/mtd/nand/raw/brcmnand/brcmnand.c
+++ b/drivers/mtd/nand/raw/brcmnand/brcmnand.c
@@ -1114,10 +1114,10 @@ static int brcmnand_hamming_ooblayout_free(struct mtd_info *mtd, int section,
 	} else {
 		/*
 		 * Small-page NAND use byte 6 for BBI while large-page
-		 * NAND use byte 0.
+		 * NAND use bytes 0 and 1.
 		 */
 		if (cfg->page_size > 512) {
-			oobregion->offset = 1;
+			oobregion->offset = 2;
 		} else {
 			oobregion->offset = 0;
 			next--;
-- 
2.26.2




[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux