Commit dc0b69fa9f97df90cbcabf16a51d7eb88f26cd2d
Committed by
Stefano Babic
1 parent
5346c31e30
Exists in
smarc_8mq_lf_v2020.04
and in
11 other branches
mtd: nand: mxs_nand: allow to enable BBT support
Add config option which allows to enable on flash bad block table support. This has the same effect as when using the device tree property "nand-on-flash-bbt" in Linux. Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
Showing 1 changed file with 4 additions and 0 deletions Side-by-side Diff
drivers/mtd/nand/mxs_nand.c
... | ... | @@ -1213,6 +1213,10 @@ |
1213 | 1213 | |
1214 | 1214 | memset(&fake_ecc_layout, 0, sizeof(fake_ecc_layout)); |
1215 | 1215 | |
1216 | +#ifdef CONFIG_SYS_NAND_USE_FLASH_BBT | |
1217 | + nand->bbt_options |= NAND_BBT_USE_FLASH | NAND_BBT_NO_OOB; | |
1218 | +#endif | |
1219 | + | |
1216 | 1220 | nand_set_controller_data(nand, nand_info); |
1217 | 1221 | nand->options |= NAND_NO_SUBPAGE_WRITE; |
1218 | 1222 |