aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2021-09-22 14:50:32 -0400
committerTom Rini <trini@konsulko.com>2021-10-06 09:16:23 -0400
commit9d9f59dd0a97b327b784699152f7055adc7b3520 (patch)
tree9aee9b2c762a9c35ed64f85d5180698d581135c0 /drivers
parent606c377849138e58e42ddcfad5c45a5aa55558a9 (diff)
downloadu-boot-9d9f59dd0a97b327b784699152f7055adc7b3520.zip
u-boot-9d9f59dd0a97b327b784699152f7055adc7b3520.tar.gz
u-boot-9d9f59dd0a97b327b784699152f7055adc7b3520.tar.bz2
Convert CONFIG_SYS_NAND_BAD_BLOCK_POS to Kconfig
This converts the following to Kconfig: CONFIG_SYS_NAND_BAD_BLOCK_POS In order to do this, introduce a choice for HAS_LARGE/SMALL_BADBLOCK_POS as those are the only valid values. Use LARGE as the default as no in-tree boards use SMALL, but it is possible. Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/mtd/nand/raw/Kconfig21
1 files changed, 21 insertions, 0 deletions
diff --git a/drivers/mtd/nand/raw/Kconfig b/drivers/mtd/nand/raw/Kconfig
index 8739f3e..dab392e 100644
--- a/drivers/mtd/nand/raw/Kconfig
+++ b/drivers/mtd/nand/raw/Kconfig
@@ -425,6 +425,27 @@ config SYS_NAND_MAX_CHIPS
if SPL
+choice
+ prompt "NAND bad block marker/indicator positon in the OOB"
+ depends on SPL_NAND_AM33XX_BCH || SPL_NAND_DENALI || SPL_NAND_SIMPLE || \
+ SPL_NAND_SUPPORT && (NAND_ATMEL || NAND_MXC)
+ default HAS_NAND_LARGE_BADBLOCK_POS
+ help
+ In the OOB, which position contains the badblock information.
+
+config HAS_NAND_LARGE_BADBLOCK_POS
+ bool "Set the bad block marker/indicator to the 'large' position"
+
+config HAS_NAND_SMALL_BADBLOCK_POS
+ bool "Set the bad block marker/indicator to the 'small' position"
+
+endchoice
+
+config SYS_NAND_BAD_BLOCK_POS
+ int
+ default 0 if HAS_NAND_LARGE_BADBLOCK_POS
+ default 5 if HAS_NAND_SMALL_BADBLOCK_POS
+
config SYS_NAND_U_BOOT_LOCATIONS
bool "Define U-boot binaries locations in NAND"
help