]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
mtd: rawnand: marvell: fix layouts
authorElad Nachman <enachman@marvell.com>
Mon, 5 Feb 2024 13:44:35 +0000 (15:44 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 6 Mar 2024 14:48:40 +0000 (14:48 +0000)
commitad8ff8cff38d12f8da1f13b55dc634fcfb55b773
tree1037d8360143eabefabc914decc92428167aa8c4
parentba60fdf75e89ea762bb617be578dc47f27655117
mtd: rawnand: marvell: fix layouts

commit e6a30d0c48a1e8a68f1cc413bee65302ab03ddfb upstream.

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>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/mtd/nand/raw/marvell_nand.c