]> git.baikalelectronics.ru Git - kernel.git/commit
mtd: rawnand: marvell: support 8b/512B strength for 2kiB pages layout
authorMiquel Raynal <miquel.raynal@bootlin.com>
Thu, 19 Jul 2018 10:21:19 +0000 (12:21 +0200)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Wed, 3 Oct 2018 09:12:25 +0000 (11:12 +0200)
commit74f8319bbec950687f8e00b64668fe17ab701f2a
treeefd24805dfc987d2d283609a27a651e85d59d6ce
parent41c5461d439bead47de4c7aee7d5a5df7b1c8c59
mtd: rawnand: marvell: support 8b/512B strength for 2kiB pages layout

Add support for the layout used by 2kiB page NAND chips requesting at
least 8-bit of correction per 512 bytes. This layout requires a bit of
handling as:
1/ It can only fit if the NAND chip has at least 128 OOB bytes.
2/ The Bad Block Markers are located in the middle of the data bytes
   and shall not be used.
3/ It has been experimentally observed that, for certain layouts, the ECC
   engine tries to correct data while it should not because the errors
   are uncorrectable. While this is harmless for truly bad pages, it
   creates bitflips in empty pages. To avoid such scenario that
   augments artificially the number of bitflips we re-read in raw mode
   the entire page instead of just the ECC bytes. This is done only
   for this layout to avoid an unneeded penalty with other setups.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Reviewed-by: Boris Brezillon <boris.brezillon@bootlin.com>
drivers/mtd/nand/raw/marvell_nand.c