]> git.baikalelectronics.ru Git - kernel.git/commit
mtd: nand/docg4: fix and improve read of factory bbt
authorMike Dunn <mikedunn@newsguy.com>
Fri, 7 Dec 2012 20:07:23 +0000 (12:07 -0800)
committerArtem Bityutskiy <artem.bityutskiy@linux.intel.com>
Wed, 12 Dec 2012 15:03:42 +0000 (17:03 +0200)
commitdb1e4056cbe9cc38629aa8aa2b1f009732beb4e3
treef4969efdec7109ca179865f5839242a952141cf9
parent251bc3eef63df417bebe76913b3cfbb4d7b8a5d2
mtd: nand/docg4: fix and improve read of factory bbt

This patch does two things related to reading the factory badblock table during
initialization: (1) fix error where a non-zero return code from
docg4_read_page() is assumed to be an error (it was later changed to be
max_bitflips; thanks to Brian Norris for bringing this to my attention a while
back), and (2) if there is an error reading the factory bbt, it tries reading
another (redundant) factory bbt table.

Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
Acked-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
drivers/mtd/nand/docg4.c