mtd: rawnand: marvell: fix layouts
authorElad Nachman <enachman@marvell.com>
Mon, 5 Feb 2024 13:44:35 +0000 (15:44 +0200)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Mon, 5 Feb 2024 15:16:24 +0000 (16:16 +0100)
commite6a30d0c48a1e8a68f1cc413bee65302ab03ddfb
tree914ffb854b5b9d2acea5f5236c4977038ace9ab2
parent5ab9bbf6c678444dd99afabd44665e7f04047cc5
mtd: rawnand: marvell: fix layouts

The check in nand_base.c, nand_scan_tail() : has the following code:
(ecc->steps * ecc->size != mtd->writesize) which fails for some NAND chips.
Remove ECC entries in this driver which are not integral multiplications,
and adjust the number of chunks for entries which fails the above
calculation so it will calculate correctly (this was previously done
automatically before the check and was removed in a later commit).

Fixes: 68c18dae6888 ("mtd: rawnand: marvell: add missing layouts")
Cc: stable@vger.kernel.org
Signed-off-by: Elad Nachman <enachman@marvell.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
drivers/mtd/nand/raw/marvell_nand.c