diff mbox series

[U-Boot] Convert CONFIG_SYS_MAX_NAND_DEVICE to Kconfig and add CONFIG_NAND

Message ID 1516802421-19240-1-git-send-email-aford173@gmail.com
State Deferred
Delegated to: Tom Rini
Headers show
Series [U-Boot] Convert CONFIG_SYS_MAX_NAND_DEVICE to Kconfig and add CONFIG_NAND | expand

Commit Message

Adam Ford Jan. 24, 2018, 2 p.m. UTC
Many boards are setting NAND parameters if/when CMD_NAND is set
when in reality they should probably be doing it it CONFIG_NAND
is set.  Previuos attempts to make CMD_NAND select CONFIG_NAND
resulted in some recursive selections, so I think this should be
a better solution

Using the moveconfig tool, I searched for CONFIG_SYS_MAX_NAND_DEVICE
and then any suspicious defconfig files left behind, I added
CONFIG_NAND=y, then retested the migration against that list.

This should allows us to make the CONFIG_CMD_NAND now dependant on
CONFIG_NAND and enable a bunch of NAND parameters under the NAND
menu without appearing 'suspicious'

This converts the following to Kconfig:
   CONFIG_SYS_MAX_NAND_DEVICE

Signed-off-by: Adam Ford <aford173@gmail.com>
---
 configs/B4420QDS_SPIFLASH_defconfig                    | 1 +
 configs/B4420QDS_defconfig                             | 1 +
 configs/B4860QDS_SECURE_BOOT_defconfig                 | 1 +
 configs/B4860QDS_SPIFLASH_defconfig                    | 1 +
 configs/B4860QDS_SRIO_PCIE_BOOT_defconfig              | 1 +
 configs/B4860QDS_defconfig                             | 1 +
 configs/BSC9131RDB_SPIFLASH_SYSCLK100_defconfig        | 1 +
 configs/BSC9131RDB_SPIFLASH_defconfig                  | 1 +
 configs/BSC9132QDS_NAND_DDRCLK100_SECURE_defconfig     | 1 +
 configs/BSC9132QDS_NAND_DDRCLK133_SECURE_defconfig     | 1 +
 configs/BSC9132QDS_NOR_DDRCLK100_SECURE_defconfig      | 1 +
 configs/BSC9132QDS_NOR_DDRCLK100_defconfig             | 1 +
 configs/BSC9132QDS_NOR_DDRCLK133_SECURE_defconfig      | 1 +
 configs/BSC9132QDS_NOR_DDRCLK133_defconfig             | 1 +
 configs/BSC9132QDS_SDCARD_DDRCLK100_SECURE_defconfig   | 1 +
 configs/BSC9132QDS_SDCARD_DDRCLK100_defconfig          | 1 +
 configs/BSC9132QDS_SDCARD_DDRCLK133_SECURE_defconfig   | 1 +
 configs/BSC9132QDS_SDCARD_DDRCLK133_defconfig          | 1 +
 configs/BSC9132QDS_SPIFLASH_DDRCLK100_SECURE_defconfig | 1 +
 configs/BSC9132QDS_SPIFLASH_DDRCLK100_defconfig        | 1 +
 configs/BSC9132QDS_SPIFLASH_DDRCLK133_SECURE_defconfig | 1 +
 configs/BSC9132QDS_SPIFLASH_DDRCLK133_defconfig        | 1 +
 configs/C29XPCIE_NOR_SECBOOT_defconfig                 | 1 +
 configs/C29XPCIE_SPIFLASH_SECBOOT_defconfig            | 1 +
 configs/C29XPCIE_SPIFLASH_defconfig                    | 1 +
 configs/C29XPCIE_defconfig                             | 1 +
 configs/CHIP_pro_defconfig                             | 1 +
 configs/M5329AFEE_defconfig                            | 1 +
 configs/M5329BFEE_defconfig                            | 1 +
 configs/M5373EVB_defconfig                             | 1 +
 configs/MCR3000_defconfig                              | 1 +
 configs/MPC8313ERDB_33_defconfig                       | 1 +
 configs/MPC8313ERDB_66_defconfig                       | 1 +
 configs/MPC8315ERDB_defconfig                          | 1 +
 configs/MPC837XEMDS_HOST_defconfig                     | 1 +
 configs/MPC837XEMDS_defconfig                          | 1 +
 configs/MPC8536DS_36BIT_defconfig                      | 2 ++
 configs/MPC8536DS_SDCARD_defconfig                     | 2 ++
 configs/MPC8536DS_SPIFLASH_defconfig                   | 2 ++
 configs/MPC8536DS_defconfig                            | 2 ++
 configs/MPC8569MDS_ATM_defconfig                       | 1 +
 configs/MPC8569MDS_defconfig                           | 1 +
 configs/MPC8572DS_36BIT_defconfig                      | 2 ++
 configs/MPC8572DS_defconfig                            | 2 ++
 configs/P1010RDB-PA_36BIT_NAND_SECBOOT_defconfig       | 1 +
 configs/P1010RDB-PA_36BIT_NOR_SECBOOT_defconfig        | 1 +
 configs/P1010RDB-PA_36BIT_NOR_defconfig                | 1 +
 configs/P1010RDB-PA_36BIT_SDCARD_defconfig             | 1 +
 configs/P1010RDB-PA_36BIT_SPIFLASH_SECBOOT_defconfig   | 1 +
 configs/P1010RDB-PA_36BIT_SPIFLASH_defconfig           | 1 +
 configs/P1010RDB-PA_NAND_SECBOOT_defconfig             | 1 +
 configs/P1010RDB-PA_NOR_SECBOOT_defconfig              | 1 +
 configs/P1010RDB-PA_NOR_defconfig                      | 1 +
 configs/P1010RDB-PA_SDCARD_defconfig                   | 1 +
 configs/P1010RDB-PA_SPIFLASH_SECBOOT_defconfig         | 1 +
 configs/P1010RDB-PA_SPIFLASH_defconfig                 | 1 +
 configs/P1010RDB-PB_36BIT_NAND_SECBOOT_defconfig       | 1 +
 configs/P1010RDB-PB_36BIT_NOR_SECBOOT_defconfig        | 1 +
 configs/P1010RDB-PB_36BIT_NOR_defconfig                | 1 +
 configs/P1010RDB-PB_36BIT_SDCARD_defconfig             | 1 +
 configs/P1010RDB-PB_36BIT_SPIFLASH_SECBOOT_defconfig   | 1 +
 configs/P1010RDB-PB_36BIT_SPIFLASH_defconfig           | 1 +
 configs/P1010RDB-PB_NAND_SECBOOT_defconfig             | 1 +
 configs/P1010RDB-PB_NOR_SECBOOT_defconfig              | 1 +
 configs/P1010RDB-PB_NOR_defconfig                      | 1 +
 configs/P1010RDB-PB_SDCARD_defconfig                   | 1 +
 configs/P1010RDB-PB_SPIFLASH_SECBOOT_defconfig         | 1 +
 configs/P1010RDB-PB_SPIFLASH_defconfig                 | 1 +
 configs/P1020RDB-PC_36BIT_SDCARD_defconfig             | 1 +
 configs/P1020RDB-PC_36BIT_SPIFLASH_defconfig           | 1 +
 configs/P1020RDB-PC_36BIT_defconfig                    | 1 +
 configs/P1020RDB-PC_SDCARD_defconfig                   | 1 +
 configs/P1020RDB-PC_SPIFLASH_defconfig                 | 1 +
 configs/P1020RDB-PC_defconfig                          | 1 +
 configs/P1020RDB-PD_SDCARD_defconfig                   | 1 +
 configs/P1020RDB-PD_SPIFLASH_defconfig                 | 1 +
 configs/P1020RDB-PD_defconfig                          | 1 +
 configs/P1021RDB-PC_36BIT_SDCARD_defconfig             | 1 +
 configs/P1021RDB-PC_36BIT_SPIFLASH_defconfig           | 1 +
 configs/P1021RDB-PC_36BIT_defconfig                    | 1 +
 configs/P1021RDB-PC_SDCARD_defconfig                   | 1 +
 configs/P1021RDB-PC_SPIFLASH_defconfig                 | 1 +
 configs/P1021RDB-PC_defconfig                          | 1 +
 configs/P1022DS_36BIT_SDCARD_defconfig                 | 1 +
 configs/P1022DS_36BIT_SPIFLASH_defconfig               | 1 +
 configs/P1022DS_36BIT_defconfig                        | 1 +
 configs/P1022DS_SDCARD_defconfig                       | 1 +
 configs/P1022DS_SPIFLASH_defconfig                     | 1 +
 configs/P1022DS_defconfig                              | 1 +
 configs/P1023RDB_defconfig                             | 1 +
 configs/P1024RDB_36BIT_defconfig                       | 1 +
 configs/P1024RDB_SDCARD_defconfig                      | 1 +
 configs/P1024RDB_SPIFLASH_defconfig                    | 1 +
 configs/P1024RDB_defconfig                             | 1 +
 configs/P1025RDB_36BIT_defconfig                       | 1 +
 configs/P1025RDB_SDCARD_defconfig                      | 1 +
 configs/P1025RDB_SPIFLASH_defconfig                    | 1 +
 configs/P1025RDB_defconfig                             | 1 +
 configs/P2020RDB-PC_36BIT_SDCARD_defconfig             | 1 +
 configs/P2020RDB-PC_36BIT_SPIFLASH_defconfig           | 1 +
 configs/P2020RDB-PC_36BIT_defconfig                    | 1 +
 configs/P2020RDB-PC_SDCARD_defconfig                   | 1 +
 configs/P2020RDB-PC_SPIFLASH_defconfig                 | 1 +
 configs/P2020RDB-PC_defconfig                          | 1 +
 configs/P2041RDB_SDCARD_defconfig                      | 1 +
 configs/P2041RDB_SECURE_BOOT_defconfig                 | 1 +
 configs/P2041RDB_SPIFLASH_defconfig                    | 1 +
 configs/P2041RDB_SRIO_PCIE_BOOT_defconfig              | 1 +
 configs/P2041RDB_defconfig                             | 1 +
 configs/P3041DS_SDCARD_defconfig                       | 1 +
 configs/P3041DS_SECURE_BOOT_defconfig                  | 1 +
 configs/P3041DS_SPIFLASH_defconfig                     | 1 +
 configs/P3041DS_SRIO_PCIE_BOOT_defconfig               | 1 +
 configs/P3041DS_defconfig                              | 1 +
 configs/P5020DS_SDCARD_defconfig                       | 1 +
 configs/P5020DS_SECURE_BOOT_defconfig                  | 1 +
 configs/P5020DS_SPIFLASH_defconfig                     | 1 +
 configs/P5020DS_SRIO_PCIE_BOOT_defconfig               | 1 +
 configs/P5020DS_defconfig                              | 1 +
 configs/P5040DS_SDCARD_defconfig                       | 1 +
 configs/P5040DS_SECURE_BOOT_defconfig                  | 1 +
 configs/P5040DS_SPIFLASH_defconfig                     | 1 +
 configs/P5040DS_defconfig                              | 1 +
 configs/T1023RDB_SDCARD_defconfig                      | 1 +
 configs/T1023RDB_SECURE_BOOT_defconfig                 | 1 +
 configs/T1023RDB_SPIFLASH_defconfig                    | 1 +
 configs/T1023RDB_defconfig                             | 1 +
 configs/T1024QDS_DDR4_SECURE_BOOT_defconfig            | 1 +
 configs/T1024QDS_DDR4_defconfig                        | 1 +
 configs/T1024QDS_SDCARD_defconfig                      | 1 +
 configs/T1024QDS_SECURE_BOOT_defconfig                 | 1 +
 configs/T1024QDS_SPIFLASH_defconfig                    | 1 +
 configs/T1024QDS_defconfig                             | 1 +
 configs/T1024RDB_SDCARD_defconfig                      | 1 +
 configs/T1024RDB_SECURE_BOOT_defconfig                 | 1 +
 configs/T1024RDB_SPIFLASH_defconfig                    | 1 +
 configs/T1024RDB_defconfig                             | 1 +
 configs/T1040D4RDB_SDCARD_defconfig                    | 1 +
 configs/T1040D4RDB_SECURE_BOOT_defconfig               | 1 +
 configs/T1040D4RDB_SPIFLASH_defconfig                  | 1 +
 configs/T1040D4RDB_defconfig                           | 1 +
 configs/T1040QDS_DDR4_defconfig                        | 1 +
 configs/T1040QDS_SECURE_BOOT_defconfig                 | 1 +
 configs/T1040QDS_defconfig                             | 1 +
 configs/T1040RDB_SDCARD_defconfig                      | 1 +
 configs/T1040RDB_SECURE_BOOT_defconfig                 | 1 +
 configs/T1040RDB_SPIFLASH_defconfig                    | 1 +
 configs/T1040RDB_defconfig                             | 1 +
 configs/T1042D4RDB_SDCARD_defconfig                    | 1 +
 configs/T1042D4RDB_SECURE_BOOT_defconfig               | 1 +
 configs/T1042D4RDB_SPIFLASH_defconfig                  | 1 +
 configs/T1042D4RDB_defconfig                           | 1 +
 configs/T1042RDB_PI_SDCARD_defconfig                   | 1 +
 configs/T1042RDB_PI_SPIFLASH_defconfig                 | 1 +
 configs/T1042RDB_PI_defconfig                          | 1 +
 configs/T1042RDB_SECURE_BOOT_defconfig                 | 1 +
 configs/T1042RDB_defconfig                             | 1 +
 configs/T2080QDS_SDCARD_defconfig                      | 1 +
 configs/T2080QDS_SECURE_BOOT_defconfig                 | 1 +
 configs/T2080QDS_SPIFLASH_defconfig                    | 1 +
 configs/T2080QDS_SRIO_PCIE_BOOT_defconfig              | 1 +
 configs/T2080QDS_defconfig                             | 1 +
 configs/T2080RDB_SDCARD_defconfig                      | 1 +
 configs/T2080RDB_SECURE_BOOT_defconfig                 | 1 +
 configs/T2080RDB_SPIFLASH_defconfig                    | 1 +
 configs/T2080RDB_SRIO_PCIE_BOOT_defconfig              | 1 +
 configs/T2080RDB_defconfig                             | 1 +
 configs/T2081QDS_SDCARD_defconfig                      | 1 +
 configs/T2081QDS_SPIFLASH_defconfig                    | 1 +
 configs/T2081QDS_SRIO_PCIE_BOOT_defconfig              | 1 +
 configs/T2081QDS_defconfig                             | 1 +
 configs/T4160QDS_SDCARD_defconfig                      | 1 +
 configs/T4160QDS_SECURE_BOOT_defconfig                 | 1 +
 configs/T4160QDS_defconfig                             | 1 +
 configs/T4160RDB_defconfig                             | 1 +
 configs/T4240QDS_SDCARD_defconfig                      | 1 +
 configs/T4240QDS_SECURE_BOOT_defconfig                 | 1 +
 configs/T4240QDS_SRIO_PCIE_BOOT_defconfig              | 1 +
 configs/T4240QDS_defconfig                             | 1 +
 configs/T4240RDB_SDCARD_defconfig                      | 1 +
 configs/T4240RDB_defconfig                             | 1 +
 configs/apx4devkit_defconfig                           | 1 +
 configs/aristainetos2_defconfig                        | 1 +
 configs/aristainetos2b_defconfig                       | 1 +
 configs/aristainetos_defconfig                         | 1 +
 configs/at91sam9260ek_dataflash_cs0_defconfig          | 1 +
 configs/at91sam9260ek_dataflash_cs1_defconfig          | 1 +
 configs/at91sam9260ek_nandflash_defconfig              | 1 +
 configs/at91sam9261ek_dataflash_cs0_defconfig          | 1 +
 configs/at91sam9261ek_dataflash_cs3_defconfig          | 1 +
 configs/at91sam9261ek_nandflash_defconfig              | 1 +
 configs/at91sam9263ek_dataflash_cs0_defconfig          | 1 +
 configs/at91sam9263ek_dataflash_defconfig              | 1 +
 configs/at91sam9263ek_nandflash_defconfig              | 1 +
 configs/at91sam9263ek_norflash_boot_defconfig          | 1 +
 configs/at91sam9263ek_norflash_defconfig               | 1 +
 configs/at91sam9g10ek_dataflash_cs0_defconfig          | 1 +
 configs/at91sam9g10ek_dataflash_cs3_defconfig          | 1 +
 configs/at91sam9g10ek_nandflash_defconfig              | 1 +
 configs/at91sam9g20ek_2mmc_defconfig                   | 1 +
 configs/at91sam9g20ek_2mmc_nandflash_defconfig         | 1 +
 configs/at91sam9g20ek_dataflash_cs0_defconfig          | 1 +
 configs/at91sam9g20ek_dataflash_cs1_defconfig          | 1 +
 configs/at91sam9g20ek_nandflash_defconfig              | 1 +
 configs/at91sam9m10g45ek_mmc_defconfig                 | 1 +
 configs/at91sam9m10g45ek_nandflash_defconfig           | 1 +
 configs/at91sam9n12ek_mmc_defconfig                    | 1 +
 configs/at91sam9n12ek_nandflash_defconfig              | 1 +
 configs/at91sam9n12ek_spiflash_defconfig               | 1 +
 configs/at91sam9rlek_dataflash_defconfig               | 1 +
 configs/at91sam9rlek_mmc_defconfig                     | 1 +
 configs/at91sam9rlek_nandflash_defconfig               | 1 +
 configs/at91sam9x5ek_dataflash_defconfig               | 1 +
 configs/at91sam9x5ek_mmc_defconfig                     | 1 +
 configs/at91sam9x5ek_nandflash_defconfig               | 1 +
 configs/at91sam9x5ek_spiflash_defconfig                | 1 +
 configs/at91sam9xeek_dataflash_cs0_defconfig           | 1 +
 configs/at91sam9xeek_dataflash_cs1_defconfig           | 1 +
 configs/at91sam9xeek_nandflash_defconfig               | 1 +
 configs/axm_defconfig                                  | 1 +
 configs/bg0900_defconfig                               | 1 +
 configs/cm_fx6_defconfig                               | 1 +
 configs/colibri_imx7_defconfig                         | 1 +
 configs/colibri_t20_defconfig                          | 1 +
 configs/corvus_defconfig                               | 1 +
 configs/dns325_defconfig                               | 1 +
 configs/dockstar_defconfig                             | 1 +
 configs/ea20_defconfig                                 | 1 +
 configs/etamin_defconfig                               | 1 +
 configs/ethernut5_defconfig                            | 1 +
 configs/goflexhome_defconfig                           | 1 +
 configs/gurnard_defconfig                              | 1 +
 configs/guruplug_defconfig                             | 1 +
 configs/gwventana_nand_defconfig                       | 1 +
 configs/harmony_defconfig                              | 1 +
 configs/ib62x0_defconfig                               | 1 +
 configs/iconnect_defconfig                             | 1 +
 configs/ids8313_defconfig                              | 1 +
 configs/ipam390_defconfig                              | 1 +
 configs/k2e_evm_defconfig                              | 1 +
 configs/k2e_hs_evm_defconfig                           | 1 +
 configs/k2g_evm_defconfig                              | 1 +
 configs/k2g_hs_evm_defconfig                           | 1 +
 configs/k2hk_evm_defconfig                             | 1 +
 configs/k2hk_hs_evm_defconfig                          | 1 +
 configs/k2l_evm_defconfig                              | 1 +
 configs/km_kirkwood_128m16_defconfig                   | 1 +
 configs/km_kirkwood_defconfig                          | 1 +
 configs/km_kirkwood_pci_defconfig                      | 1 +
 configs/kmcoge4_defconfig                              | 1 +
 configs/kmcoge5ne_defconfig                            | 1 +
 configs/kmcoge5un_defconfig                            | 1 +
 configs/kmlion1_defconfig                              | 1 +
 configs/kmnusa_defconfig                               | 1 +
 configs/kmsugp1_defconfig                              | 1 +
 configs/kmsuv31_defconfig                              | 1 +
 configs/kmtegr1_defconfig                              | 1 +
 configs/ls1021aqds_ddr4_nor_defconfig                  | 1 +
 configs/ls1021aqds_ddr4_nor_lpuart_defconfig           | 1 +
 configs/ls1021aqds_nand_defconfig                      | 1 +
 configs/ls1021aqds_nor_SECURE_BOOT_defconfig           | 1 +
 configs/ls1021aqds_nor_defconfig                       | 1 +
 configs/ls1021aqds_nor_lpuart_defconfig                | 1 +
 configs/ls1021aqds_sdcard_ifc_defconfig                | 1 +
 configs/ls1043aqds_defconfig                           | 1 +
 configs/ls1043aqds_lpuart_defconfig                    | 1 +
 configs/ls1043aqds_nand_defconfig                      | 1 +
 configs/ls1043aqds_nor_ddr3_defconfig                  | 1 +
 configs/ls1043aqds_sdcard_ifc_defconfig                | 1 +
 configs/ls1043ardb_SECURE_BOOT_defconfig               | 1 +
 configs/ls1043ardb_defconfig                           | 1 +
 configs/ls1043ardb_nand_SECURE_BOOT_defconfig          | 1 +
 configs/ls1043ardb_nand_defconfig                      | 1 +
 configs/ls1043ardb_sdcard_SECURE_BOOT_defconfig        | 1 +
 configs/ls1043ardb_sdcard_defconfig                    | 1 +
 configs/ls1046aqds_SECURE_BOOT_defconfig               | 1 +
 configs/ls1046aqds_defconfig                           | 1 +
 configs/ls1046aqds_lpuart_defconfig                    | 1 +
 configs/ls1046aqds_nand_defconfig                      | 1 +
 configs/ls1046aqds_sdcard_ifc_defconfig                | 1 +
 configs/ls1046ardb_emmc_defconfig                      | 1 +
 configs/ls1046ardb_qspi_SECURE_BOOT_defconfig          | 1 +
 configs/ls1046ardb_qspi_defconfig                      | 1 +
 configs/ls1046ardb_sdcard_SECURE_BOOT_defconfig        | 1 +
 configs/ls1046ardb_sdcard_defconfig                    | 1 +
 configs/ls1088aqds_qspi_SECURE_BOOT_defconfig          | 1 +
 configs/ls1088aqds_qspi_defconfig                      | 1 +
 configs/ls1088aqds_sdcard_qspi_defconfig               | 1 +
 configs/ls1088ardb_qspi_SECURE_BOOT_defconfig          | 1 +
 configs/ls1088ardb_qspi_defconfig                      | 1 +
 configs/ls1088ardb_sdcard_qspi_SECURE_BOOT_defconfig   | 1 +
 configs/ls1088ardb_sdcard_qspi_defconfig               | 1 +
 configs/ls2080a_simu_defconfig                         | 1 +
 configs/ls2080aqds_SECURE_BOOT_defconfig               | 1 +
 configs/ls2080aqds_defconfig                           | 1 +
 configs/ls2080aqds_qspi_defconfig                      | 1 +
 configs/ls2080aqds_sdcard_defconfig                    | 1 +
 configs/ls2080ardb_SECURE_BOOT_defconfig               | 1 +
 configs/ls2080ardb_defconfig                           | 1 +
 configs/m28evk_defconfig                               | 1 +
 configs/medcom-wide_defconfig                          | 1 +
 configs/meesc_defconfig                                | 1 +
 configs/mgcoge3un_defconfig                            | 1 +
 configs/mvebu_db_armada8k_defconfig                    | 1 +
 configs/mvebu_mcbin-88f8040_defconfig                  | 1 +
 configs/mx28evk_auart_console_defconfig                | 1 +
 configs/mx28evk_defconfig                              | 1 +
 configs/mx28evk_nand_defconfig                         | 1 +
 configs/mx28evk_spi_defconfig                          | 1 +
 configs/mx6sabreauto_defconfig                         | 1 +
 configs/mx6sxsabreauto_defconfig                       | 1 +
 configs/nas220_defconfig                               | 1 +
 configs/nsa310s_defconfig                              | 1 +
 configs/openrd_base_defconfig                          | 1 +
 configs/openrd_client_defconfig                        | 1 +
 configs/openrd_ultimate_defconfig                      | 1 +
 configs/pcm058_defconfig                               | 1 +
 configs/pfla02_defconfig                               | 1 +
 configs/platinum_picon_defconfig                       | 1 +
 configs/platinum_titanium_defconfig                    | 1 +
 configs/plutux_defconfig                               | 1 +
 configs/pm9261_defconfig                               | 1 +
 configs/pm9263_defconfig                               | 1 +
 configs/pm9g45_defconfig                               | 1 +
 configs/pogo_e02_defconfig                             | 1 +
 configs/portl2_defconfig                               | 1 +
 configs/sama5d2_ptc_ek_mmc_defconfig                   | 1 +
 configs/sama5d2_ptc_ek_nandflash_defconfig             | 1 +
 configs/sama5d36ek_cmp_mmc_defconfig                   | 1 +
 configs/sama5d36ek_cmp_nandflash_defconfig             | 1 +
 configs/sama5d36ek_cmp_spiflash_defconfig              | 1 +
 configs/sama5d3_xplained_mmc_defconfig                 | 1 +
 configs/sama5d3_xplained_nandflash_defconfig           | 1 +
 configs/sama5d3xek_mmc_defconfig                       | 1 +
 configs/sama5d3xek_nandflash_defconfig                 | 1 +
 configs/sama5d3xek_spiflash_defconfig                  | 1 +
 configs/sama5d4_xplained_mmc_defconfig                 | 1 +
 configs/sama5d4_xplained_nandflash_defconfig           | 1 +
 configs/sama5d4_xplained_spiflash_defconfig            | 1 +
 configs/sama5d4ek_mmc_defconfig                        | 1 +
 configs/sama5d4ek_nandflash_defconfig                  | 1 +
 configs/sama5d4ek_spiflash_defconfig                   | 1 +
 configs/seaboard_defconfig                             | 1 +
 configs/sheevaplug_defconfig                           | 1 +
 configs/smartweb_defconfig                             | 1 +
 configs/snapper9260_defconfig                          | 1 +
 configs/snapper9g20_defconfig                          | 1 +
 configs/socrates_defconfig                             | 1 +
 configs/spear300_defconfig                             | 1 +
 configs/spear300_usbtty_defconfig                      | 1 +
 configs/spear310_defconfig                             | 1 +
 configs/spear310_pnor_defconfig                        | 1 +
 configs/spear310_usbtty_defconfig                      | 1 +
 configs/spear310_usbtty_pnor_defconfig                 | 1 +
 configs/spear320_defconfig                             | 1 +
 configs/spear320_pnor_defconfig                        | 1 +
 configs/spear320_usbtty_defconfig                      | 1 +
 configs/spear320_usbtty_pnor_defconfig                 | 1 +
 configs/spear600_defconfig                             | 1 +
 configs/spear600_usbtty_defconfig                      | 1 +
 configs/taurus_defconfig                               | 1 +
 configs/tec_defconfig                                  | 1 +
 configs/titanium_defconfig                             | 1 +
 configs/usb_a9263_dataflash_defconfig                  | 1 +
 configs/ve8313_defconfig                               | 1 +
 configs/wb45n_defconfig                                | 1 +
 configs/wb50n_defconfig                                | 1 +
 configs/work_92105_defconfig                           | 1 +
 configs/x600_defconfig                                 | 1 +
 configs/xpedite517x_defconfig                          | 2 ++
 configs/xpedite520x_defconfig                          | 1 +
 configs/xpedite537x_defconfig                          | 2 ++
 configs/xpedite550x_defconfig                          | 2 ++
 drivers/mtd/nand/Kconfig                               | 6 ++++++
 include/configs/B4860QDS.h                             | 1 -
 include/configs/BSC9131RDB.h                           | 1 -
 include/configs/BSC9132QDS.h                           | 1 -
 include/configs/C29XPCIE.h                             | 1 -
 include/configs/M5329EVB.h                             | 1 -
 include/configs/M5373EVB.h                             | 1 -
 include/configs/M54418TWR.h                            | 1 -
 include/configs/MCR3000.h                              | 1 -
 include/configs/MPC8313ERDB.h                          | 1 -
 include/configs/MPC8315ERDB.h                          | 1 -
 include/configs/MPC837XEMDS.h                          | 1 -
 include/configs/MPC8536DS.h                            | 1 -
 include/configs/MPC8569MDS.h                           | 1 -
 include/configs/MPC8572DS.h                            | 1 -
 include/configs/P1010RDB.h                             | 1 -
 include/configs/P1022DS.h                              | 1 -
 include/configs/P1023RDB.h                             | 1 -
 include/configs/P2041RDB.h                             | 1 -
 include/configs/T102xQDS.h                             | 1 -
 include/configs/T102xRDB.h                             | 1 -
 include/configs/T1040QDS.h                             | 1 -
 include/configs/T104xRDB.h                             | 1 -
 include/configs/T208xQDS.h                             | 1 -
 include/configs/T208xRDB.h                             | 1 -
 include/configs/T4240QDS.h                             | 1 -
 include/configs/T4240RDB.h                             | 1 -
 include/configs/am3517_crane.h                         | 1 -
 include/configs/apf27.h                                | 1 -
 include/configs/aristainetos-common.h                  | 1 -
 include/configs/at91sam9260ek.h                        | 1 -
 include/configs/at91sam9261ek.h                        | 1 -
 include/configs/at91sam9263ek.h                        | 1 -
 include/configs/at91sam9m10g45ek.h                     | 1 -
 include/configs/at91sam9n12ek.h                        | 1 -
 include/configs/at91sam9rlek.h                         | 1 -
 include/configs/at91sam9x5ek.h                         | 1 -
 include/configs/axs10x.h                               | 1 -
 include/configs/brppt1.h                               | 1 -
 include/configs/cm_fx6.h                               | 1 -
 include/configs/cm_t35.h                               | 1 -
 include/configs/cm_t3517.h                             | 1 -
 include/configs/colibri_imx7.h                         | 1 -
 include/configs/colibri_t20.h                          | 1 -
 include/configs/colibri_vf.h                           | 1 -
 include/configs/corenet_ds.h                           | 1 -
 include/configs/corvus.h                               | 1 -
 include/configs/da850evm.h                             | 1 -
 include/configs/devkit3250.h                           | 1 -
 include/configs/ea20.h                                 | 1 -
 include/configs/etamin.h                               | 2 --
 include/configs/ethernut5.h                            | 1 -
 include/configs/flea3.h                                | 1 -
 include/configs/gw_ventana.h                           | 1 -
 include/configs/harmony.h                              | 1 -
 include/configs/ids8313.h                              | 1 -
 include/configs/imx27lite-common.h                     | 1 -
 include/configs/imx6-engicam.h                         | 1 -
 include/configs/imx6_logic.h                           | 1 -
 include/configs/ipam390.h                              | 1 -
 include/configs/km/km83xx-common.h                     | 1 -
 include/configs/km/km_arm.h                            | 1 -
 include/configs/km/kmp204x-common.h                    | 1 -
 include/configs/km8360.h                               | 1 -
 include/configs/ls1021aqds.h                           | 1 -
 include/configs/ls1043aqds.h                           | 1 -
 include/configs/ls1043ardb.h                           | 1 -
 include/configs/ls1046aqds.h                           | 1 -
 include/configs/ls1046ardb.h                           | 1 -
 include/configs/ls1088aqds.h                           | 1 -
 include/configs/ls1088ardb.h                           | 1 -
 include/configs/ls2080a_simu.h                         | 1 -
 include/configs/ls2080aqds.h                           | 1 -
 include/configs/ls2080ardb.h                           | 1 -
 include/configs/m53evk.h                               | 1 -
 include/configs/mcx.h                                  | 1 -
 include/configs/medcom-wide.h                          | 1 -
 include/configs/meesc.h                                | 1 -
 include/configs/mv-common.h                            | 3 ---
 include/configs/mvebu_armada-8k.h                      | 1 -
 include/configs/mx31pdk.h                              | 1 -
 include/configs/mx35pdk.h                              | 1 -
 include/configs/mx53ard.h                              | 1 -
 include/configs/mx6sabreauto.h                         | 1 -
 include/configs/mx6sxsabreauto.h                       | 1 -
 include/configs/mx7dsabresd.h                          | 1 -
 include/configs/mxs.h                                  | 1 -
 include/configs/omap3_beagle.h                         | 1 -
 include/configs/omap3_cairo.h                          | 1 -
 include/configs/omap3_evm.h                            | 1 -
 include/configs/omap3_logic.h                          | 1 -
 include/configs/omapl138_lcdk.h                        | 1 -
 include/configs/p1_p2_rdb_pc.h                         | 1 -
 include/configs/pcm052.h                               | 1 -
 include/configs/pcm058.h                               | 1 -
 include/configs/pfla02.h                               | 1 -
 include/configs/platinum.h                             | 1 -
 include/configs/plutux.h                               | 1 -
 include/configs/pm9261.h                               | 1 -
 include/configs/pm9263.h                               | 1 -
 include/configs/pm9g45.h                               | 1 -
 include/configs/s32v234evb.h                           | 1 -
 include/configs/sama5d2_ptc_ek.h                       | 1 -
 include/configs/sama5d3_xplained.h                     | 1 -
 include/configs/sama5d3xek.h                           | 1 -
 include/configs/sama5d4_xplained.h                     | 1 -
 include/configs/sama5d4ek.h                            | 1 -
 include/configs/seaboard.h                             | 1 -
 include/configs/siemens-am33x-common.h                 | 1 -
 include/configs/smartweb.h                             | 1 -
 include/configs/snapper9260.h                          | 1 -
 include/configs/snapper9g45.h                          | 1 -
 include/configs/socfpga_common.h                       | 1 -
 include/configs/socrates.h                             | 1 -
 include/configs/spear-common.h                         | 1 -
 include/configs/sunxi-common.h                         | 1 -
 include/configs/suvd3.h                                | 1 -
 include/configs/tam3517-common.h                       | 1 -
 include/configs/tao3530.h                              | 1 -
 include/configs/taurus.h                               | 1 -
 include/configs/tec.h                                  | 1 -
 include/configs/ti816x_evm.h                           | 1 -
 include/configs/ti_armv7_keystone2.h                   | 1 -
 include/configs/ti_armv7_omap.h                        | 1 -
 include/configs/titanium.h                             | 1 -
 include/configs/tricorder.h                            | 1 -
 include/configs/uniphier.h                             | 1 -
 include/configs/usb_a9263.h                            | 1 -
 include/configs/ve8313.h                               | 1 -
 include/configs/vf610twr.h                             | 1 -
 include/configs/wb45n.h                                | 1 -
 include/configs/wb50n.h                                | 1 -
 include/configs/woodburn_common.h                      | 1 -
 include/configs/work_92105.h                           | 1 -
 include/configs/x600.h                                 | 1 -
 include/configs/xilinx_zynqmp.h                        | 1 -
 include/configs/xpedite517x.h                          | 1 -
 include/configs/xpedite520x.h                          | 1 -
 include/configs/xpedite537x.h                          | 1 -
 include/configs/xpedite550x.h                          | 1 -
 include/configs/zynq-common.h                          | 1 -
 scripts/config_whitelist.txt                           | 1 -
 515 files changed, 388 insertions(+), 144 deletions(-)

Comments

Christophe Leroy Jan. 25, 2018, 5:26 p.m. UTC | #1
Le 24/01/2018 à 15:00, Adam Ford a écrit :
> Many boards are setting NAND parameters if/when CMD_NAND is set
> when in reality they should probably be doing it it CONFIG_NAND
> is set.  Previuos attempts to make CMD_NAND select CONFIG_NAND
> resulted in some recursive selections, so I think this should be
> a better solution
> 
> Using the moveconfig tool, I searched for CONFIG_SYS_MAX_NAND_DEVICE
> and then any suspicious defconfig files left behind, I added
> CONFIG_NAND=y, then retested the migration against that list.
> 
> This should allows us to make the CONFIG_CMD_NAND now dependant on
> CONFIG_NAND and enable a bunch of NAND parameters under the NAND
> menu without appearing 'suspicious'
> 
> This converts the following to Kconfig:
>     CONFIG_SYS_MAX_NAND_DEVICE
> 
> Signed-off-by: Adam Ford <aford173@gmail.com>
> ---
>   configs/MCR3000_defconfig                              | 1 +
>   include/configs/MCR3000.h                              | 1 -

For the two above files:

Acked-by: <christophe.leroy@c-s.fr>
diff mbox series

Patch

diff --git a/configs/B4420QDS_SPIFLASH_defconfig b/configs/B4420QDS_SPIFLASH_defconfig
index db5cdf9..26b77df 100644
--- a/configs/B4420QDS_SPIFLASH_defconfig
+++ b/configs/B4420QDS_SPIFLASH_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/B4420QDS_defconfig b/configs/B4420QDS_defconfig
index 6ce5b69..48156af 100644
--- a/configs/B4420QDS_defconfig
+++ b/configs/B4420QDS_defconfig
@@ -33,3 +33,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/B4860QDS_SECURE_BOOT_defconfig b/configs/B4860QDS_SECURE_BOOT_defconfig
index 8354ae1..0355da8 100644
--- a/configs/B4860QDS_SECURE_BOOT_defconfig
+++ b/configs/B4860QDS_SECURE_BOOT_defconfig
@@ -37,3 +37,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/B4860QDS_SPIFLASH_defconfig b/configs/B4860QDS_SPIFLASH_defconfig
index 615e01a..6785d3e 100644
--- a/configs/B4860QDS_SPIFLASH_defconfig
+++ b/configs/B4860QDS_SPIFLASH_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/B4860QDS_SRIO_PCIE_BOOT_defconfig b/configs/B4860QDS_SRIO_PCIE_BOOT_defconfig
index 573fc2e..626bdc6 100644
--- a/configs/B4860QDS_SRIO_PCIE_BOOT_defconfig
+++ b/configs/B4860QDS_SRIO_PCIE_BOOT_defconfig
@@ -33,3 +33,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/B4860QDS_defconfig b/configs/B4860QDS_defconfig
index 8e7d868..c16740c 100644
--- a/configs/B4860QDS_defconfig
+++ b/configs/B4860QDS_defconfig
@@ -33,3 +33,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/BSC9131RDB_SPIFLASH_SYSCLK100_defconfig b/configs/BSC9131RDB_SPIFLASH_SYSCLK100_defconfig
index a10fddd..63c2ac2 100644
--- a/configs/BSC9131RDB_SPIFLASH_SYSCLK100_defconfig
+++ b/configs/BSC9131RDB_SPIFLASH_SYSCLK100_defconfig
@@ -34,3 +34,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9131RDB_SPIFLASH_defconfig b/configs/BSC9131RDB_SPIFLASH_defconfig
index 747b2ae..3755cac 100644
--- a/configs/BSC9131RDB_SPIFLASH_defconfig
+++ b/configs/BSC9131RDB_SPIFLASH_defconfig
@@ -34,3 +34,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_NAND_DDRCLK100_SECURE_defconfig b/configs/BSC9132QDS_NAND_DDRCLK100_SECURE_defconfig
index 01ab3c8..7e1e845 100644
--- a/configs/BSC9132QDS_NAND_DDRCLK100_SECURE_defconfig
+++ b/configs/BSC9132QDS_NAND_DDRCLK100_SECURE_defconfig
@@ -41,3 +41,4 @@  CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_NAND_DDRCLK133_SECURE_defconfig b/configs/BSC9132QDS_NAND_DDRCLK133_SECURE_defconfig
index 369d9d8..12d5061 100644
--- a/configs/BSC9132QDS_NAND_DDRCLK133_SECURE_defconfig
+++ b/configs/BSC9132QDS_NAND_DDRCLK133_SECURE_defconfig
@@ -41,3 +41,4 @@  CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_NOR_DDRCLK100_SECURE_defconfig b/configs/BSC9132QDS_NOR_DDRCLK100_SECURE_defconfig
index 28fc7a8..b8e9a8f 100644
--- a/configs/BSC9132QDS_NOR_DDRCLK100_SECURE_defconfig
+++ b/configs/BSC9132QDS_NOR_DDRCLK100_SECURE_defconfig
@@ -41,3 +41,4 @@  CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_NOR_DDRCLK100_defconfig b/configs/BSC9132QDS_NOR_DDRCLK100_defconfig
index a07f1b2..f3862a3 100644
--- a/configs/BSC9132QDS_NOR_DDRCLK100_defconfig
+++ b/configs/BSC9132QDS_NOR_DDRCLK100_defconfig
@@ -37,3 +37,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_NOR_DDRCLK133_SECURE_defconfig b/configs/BSC9132QDS_NOR_DDRCLK133_SECURE_defconfig
index 43a0815..bab95a3 100644
--- a/configs/BSC9132QDS_NOR_DDRCLK133_SECURE_defconfig
+++ b/configs/BSC9132QDS_NOR_DDRCLK133_SECURE_defconfig
@@ -41,3 +41,4 @@  CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_NOR_DDRCLK133_defconfig b/configs/BSC9132QDS_NOR_DDRCLK133_defconfig
index 4433f3d..9929546 100644
--- a/configs/BSC9132QDS_NOR_DDRCLK133_defconfig
+++ b/configs/BSC9132QDS_NOR_DDRCLK133_defconfig
@@ -37,3 +37,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_SDCARD_DDRCLK100_SECURE_defconfig b/configs/BSC9132QDS_SDCARD_DDRCLK100_SECURE_defconfig
index 2c515e8..f30632e 100644
--- a/configs/BSC9132QDS_SDCARD_DDRCLK100_SECURE_defconfig
+++ b/configs/BSC9132QDS_SDCARD_DDRCLK100_SECURE_defconfig
@@ -41,3 +41,4 @@  CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_SDCARD_DDRCLK100_defconfig b/configs/BSC9132QDS_SDCARD_DDRCLK100_defconfig
index b3c4833..add5d8f 100644
--- a/configs/BSC9132QDS_SDCARD_DDRCLK100_defconfig
+++ b/configs/BSC9132QDS_SDCARD_DDRCLK100_defconfig
@@ -37,3 +37,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_SDCARD_DDRCLK133_SECURE_defconfig b/configs/BSC9132QDS_SDCARD_DDRCLK133_SECURE_defconfig
index 2102a19..70825df 100644
--- a/configs/BSC9132QDS_SDCARD_DDRCLK133_SECURE_defconfig
+++ b/configs/BSC9132QDS_SDCARD_DDRCLK133_SECURE_defconfig
@@ -41,3 +41,4 @@  CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_SDCARD_DDRCLK133_defconfig b/configs/BSC9132QDS_SDCARD_DDRCLK133_defconfig
index fd2d271..b7458f6 100644
--- a/configs/BSC9132QDS_SDCARD_DDRCLK133_defconfig
+++ b/configs/BSC9132QDS_SDCARD_DDRCLK133_defconfig
@@ -37,3 +37,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_SPIFLASH_DDRCLK100_SECURE_defconfig b/configs/BSC9132QDS_SPIFLASH_DDRCLK100_SECURE_defconfig
index d484f2c..87fc6f0 100644
--- a/configs/BSC9132QDS_SPIFLASH_DDRCLK100_SECURE_defconfig
+++ b/configs/BSC9132QDS_SPIFLASH_DDRCLK100_SECURE_defconfig
@@ -41,3 +41,4 @@  CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_SPIFLASH_DDRCLK100_defconfig b/configs/BSC9132QDS_SPIFLASH_DDRCLK100_defconfig
index c7329d6..6bd6721 100644
--- a/configs/BSC9132QDS_SPIFLASH_DDRCLK100_defconfig
+++ b/configs/BSC9132QDS_SPIFLASH_DDRCLK100_defconfig
@@ -37,3 +37,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_SPIFLASH_DDRCLK133_SECURE_defconfig b/configs/BSC9132QDS_SPIFLASH_DDRCLK133_SECURE_defconfig
index 3738a10..9eda8d9 100644
--- a/configs/BSC9132QDS_SPIFLASH_DDRCLK133_SECURE_defconfig
+++ b/configs/BSC9132QDS_SPIFLASH_DDRCLK133_SECURE_defconfig
@@ -41,3 +41,4 @@  CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/BSC9132QDS_SPIFLASH_DDRCLK133_defconfig b/configs/BSC9132QDS_SPIFLASH_DDRCLK133_defconfig
index 5c0c4cf..d119d38 100644
--- a/configs/BSC9132QDS_SPIFLASH_DDRCLK133_defconfig
+++ b/configs/BSC9132QDS_SPIFLASH_DDRCLK133_defconfig
@@ -37,3 +37,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/C29XPCIE_NOR_SECBOOT_defconfig b/configs/C29XPCIE_NOR_SECBOOT_defconfig
index 29bcc9c..be2d594 100644
--- a/configs/C29XPCIE_NOR_SECBOOT_defconfig
+++ b/configs/C29XPCIE_NOR_SECBOOT_defconfig
@@ -33,3 +33,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/C29XPCIE_SPIFLASH_SECBOOT_defconfig b/configs/C29XPCIE_SPIFLASH_SECBOOT_defconfig
index a6f51cd..e6eae6f 100644
--- a/configs/C29XPCIE_SPIFLASH_SECBOOT_defconfig
+++ b/configs/C29XPCIE_SPIFLASH_SECBOOT_defconfig
@@ -34,3 +34,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/C29XPCIE_SPIFLASH_defconfig b/configs/C29XPCIE_SPIFLASH_defconfig
index 53d019f..6244f43 100644
--- a/configs/C29XPCIE_SPIFLASH_defconfig
+++ b/configs/C29XPCIE_SPIFLASH_defconfig
@@ -30,3 +30,4 @@  CONFIG_E1000=y
 CONFIG_SYS_NS16550=y
 CONFIG_FSL_ESPI=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/C29XPCIE_defconfig b/configs/C29XPCIE_defconfig
index c7422f6..7831ce1 100644
--- a/configs/C29XPCIE_defconfig
+++ b/configs/C29XPCIE_defconfig
@@ -29,3 +29,4 @@  CONFIG_E1000=y
 CONFIG_SYS_NS16550=y
 CONFIG_FSL_ESPI=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/CHIP_pro_defconfig b/configs/CHIP_pro_defconfig
index f47aead..97f2acd 100644
--- a/configs/CHIP_pro_defconfig
+++ b/configs/CHIP_pro_defconfig
@@ -20,6 +20,7 @@  CONFIG_ENV_UBI_VOLUME="uboot-env"
 # CONFIG_MMC is not set
 CONFIG_NAND=y
 CONFIG_NAND_SUNXI=y
+CONFIG_SYS_MAX_NAND_DEVICE=8
 CONFIG_AXP_ALDO3_VOLT=3300
 CONFIG_AXP_ALDO4_VOLT=3300
 CONFIG_USB_EHCI_HCD=y
diff --git a/configs/M5329AFEE_defconfig b/configs/M5329AFEE_defconfig
index f6c2288..37b736f 100644
--- a/configs/M5329AFEE_defconfig
+++ b/configs/M5329AFEE_defconfig
@@ -14,3 +14,4 @@  CONFIG_CMD_PING=y
 CONFIG_CMD_CACHE=y
 CONFIG_CMD_DATE=y
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
diff --git a/configs/M5329BFEE_defconfig b/configs/M5329BFEE_defconfig
index 2cad692..c56469e 100644
--- a/configs/M5329BFEE_defconfig
+++ b/configs/M5329BFEE_defconfig
@@ -14,3 +14,4 @@  CONFIG_CMD_PING=y
 CONFIG_CMD_CACHE=y
 CONFIG_CMD_DATE=y
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
diff --git a/configs/M5373EVB_defconfig b/configs/M5373EVB_defconfig
index 0ec9e82..dc5d5a8 100644
--- a/configs/M5373EVB_defconfig
+++ b/configs/M5373EVB_defconfig
@@ -14,3 +14,4 @@  CONFIG_CMD_PING=y
 CONFIG_CMD_CACHE=y
 CONFIG_CMD_DATE=y
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
diff --git a/configs/MCR3000_defconfig b/configs/MCR3000_defconfig
index ece2409..010ce06 100644
--- a/configs/MCR3000_defconfig
+++ b/configs/MCR3000_defconfig
@@ -70,3 +70,4 @@  CONFIG_MPC8XX_FEC=y
 CONFIG_SHA256=y
 CONFIG_LZMA=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/MPC8313ERDB_33_defconfig b/configs/MPC8313ERDB_33_defconfig
index cc07a15..b9ce2ce 100644
--- a/configs/MPC8313ERDB_33_defconfig
+++ b/configs/MPC8313ERDB_33_defconfig
@@ -24,3 +24,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_PHYLIB=y
 CONFIG_SYS_NS16550=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/MPC8313ERDB_66_defconfig b/configs/MPC8313ERDB_66_defconfig
index 5643dec..5d60ffb 100644
--- a/configs/MPC8313ERDB_66_defconfig
+++ b/configs/MPC8313ERDB_66_defconfig
@@ -24,3 +24,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_PHYLIB=y
 CONFIG_SYS_NS16550=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/MPC8315ERDB_defconfig b/configs/MPC8315ERDB_defconfig
index 473b9a6..a157b5b 100644
--- a/configs/MPC8315ERDB_defconfig
+++ b/configs/MPC8315ERDB_defconfig
@@ -28,3 +28,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/MPC837XEMDS_HOST_defconfig b/configs/MPC837XEMDS_HOST_defconfig
index 36c2fae..f9514f0 100644
--- a/configs/MPC837XEMDS_HOST_defconfig
+++ b/configs/MPC837XEMDS_HOST_defconfig
@@ -24,3 +24,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/MPC837XEMDS_defconfig b/configs/MPC837XEMDS_defconfig
index b172b92..89f7c9e 100644
--- a/configs/MPC837XEMDS_defconfig
+++ b/configs/MPC837XEMDS_defconfig
@@ -20,3 +20,4 @@  CONFIG_PHYLIB=y
 # CONFIG_PCI is not set
 CONFIG_SYS_NS16550=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/MPC8536DS_36BIT_defconfig b/configs/MPC8536DS_36BIT_defconfig
index a66baa0..aa846e2 100644
--- a/configs/MPC8536DS_36BIT_defconfig
+++ b/configs/MPC8536DS_36BIT_defconfig
@@ -24,6 +24,8 @@  CONFIG_CMD_FAT=y
 CONFIG_ENV_IS_IN_FLASH=y
 CONFIG_SYS_FSL_DDR2=y
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
+CONFIG_SYS_MAX_NAND_DEVICE=4
 CONFIG_SPI_FLASH=y
 CONFIG_SPI_FLASH_SPANSION=y
 CONFIG_PHYLIB=y
diff --git a/configs/MPC8536DS_SDCARD_defconfig b/configs/MPC8536DS_SDCARD_defconfig
index 3a19872..d8a1c8c 100644
--- a/configs/MPC8536DS_SDCARD_defconfig
+++ b/configs/MPC8536DS_SDCARD_defconfig
@@ -23,6 +23,8 @@  CONFIG_CMD_FAT=y
 CONFIG_ENV_IS_IN_MMC=y
 CONFIG_SYS_FSL_DDR2=y
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
+CONFIG_SYS_MAX_NAND_DEVICE=4
 CONFIG_SPI_FLASH=y
 CONFIG_SPI_FLASH_SPANSION=y
 CONFIG_PHYLIB=y
diff --git a/configs/MPC8536DS_SPIFLASH_defconfig b/configs/MPC8536DS_SPIFLASH_defconfig
index 2849e17..ad7665e 100644
--- a/configs/MPC8536DS_SPIFLASH_defconfig
+++ b/configs/MPC8536DS_SPIFLASH_defconfig
@@ -23,6 +23,8 @@  CONFIG_CMD_FAT=y
 CONFIG_ENV_IS_IN_SPI_FLASH=y
 CONFIG_SYS_FSL_DDR2=y
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
+CONFIG_SYS_MAX_NAND_DEVICE=4
 CONFIG_SPI_FLASH=y
 CONFIG_SPI_FLASH_SPANSION=y
 CONFIG_PHYLIB=y
diff --git a/configs/MPC8536DS_defconfig b/configs/MPC8536DS_defconfig
index 06b0448..9e93736 100644
--- a/configs/MPC8536DS_defconfig
+++ b/configs/MPC8536DS_defconfig
@@ -23,6 +23,8 @@  CONFIG_CMD_FAT=y
 CONFIG_ENV_IS_IN_FLASH=y
 CONFIG_SYS_FSL_DDR2=y
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
+CONFIG_SYS_MAX_NAND_DEVICE=4
 CONFIG_SPI_FLASH=y
 CONFIG_SPI_FLASH_SPANSION=y
 CONFIG_PHYLIB=y
diff --git a/configs/MPC8569MDS_ATM_defconfig b/configs/MPC8569MDS_ATM_defconfig
index 7682251..040095d 100644
--- a/configs/MPC8569MDS_ATM_defconfig
+++ b/configs/MPC8569MDS_ATM_defconfig
@@ -25,3 +25,4 @@  CONFIG_NETDEVICES=y
 CONFIG_E1000=y
 CONFIG_SYS_NS16550=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/MPC8569MDS_defconfig b/configs/MPC8569MDS_defconfig
index 7cd305f..b4d33a8 100644
--- a/configs/MPC8569MDS_defconfig
+++ b/configs/MPC8569MDS_defconfig
@@ -24,3 +24,4 @@  CONFIG_NETDEVICES=y
 CONFIG_E1000=y
 CONFIG_SYS_NS16550=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/MPC8572DS_36BIT_defconfig b/configs/MPC8572DS_36BIT_defconfig
index 14e2933..bfecb7d 100644
--- a/configs/MPC8572DS_36BIT_defconfig
+++ b/configs/MPC8572DS_36BIT_defconfig
@@ -22,6 +22,8 @@  CONFIG_SCSI_AHCI=y
 CONFIG_SYS_FSL_DDR2=y
 # CONFIG_MMC is not set
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
+CONFIG_SYS_MAX_NAND_DEVICE=4
 CONFIG_PHYLIB=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
diff --git a/configs/MPC8572DS_defconfig b/configs/MPC8572DS_defconfig
index 86546f0..165fb66 100644
--- a/configs/MPC8572DS_defconfig
+++ b/configs/MPC8572DS_defconfig
@@ -21,6 +21,8 @@  CONFIG_SCSI_AHCI=y
 CONFIG_SYS_FSL_DDR2=y
 # CONFIG_MMC is not set
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
+CONFIG_SYS_MAX_NAND_DEVICE=4
 CONFIG_PHYLIB=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
diff --git a/configs/P1010RDB-PA_36BIT_NAND_SECBOOT_defconfig b/configs/P1010RDB-PA_36BIT_NAND_SECBOOT_defconfig
index d004ddd..8372b0a 100644
--- a/configs/P1010RDB-PA_36BIT_NAND_SECBOOT_defconfig
+++ b/configs/P1010RDB-PA_36BIT_NAND_SECBOOT_defconfig
@@ -41,3 +41,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_36BIT_NOR_SECBOOT_defconfig b/configs/P1010RDB-PA_36BIT_NOR_SECBOOT_defconfig
index de0c7d7..4b4e997 100644
--- a/configs/P1010RDB-PA_36BIT_NOR_SECBOOT_defconfig
+++ b/configs/P1010RDB-PA_36BIT_NOR_SECBOOT_defconfig
@@ -40,3 +40,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_36BIT_NOR_defconfig b/configs/P1010RDB-PA_36BIT_NOR_defconfig
index cadd2fc..9b5ee67 100644
--- a/configs/P1010RDB-PA_36BIT_NOR_defconfig
+++ b/configs/P1010RDB-PA_36BIT_NOR_defconfig
@@ -36,3 +36,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_36BIT_SDCARD_defconfig b/configs/P1010RDB-PA_36BIT_SDCARD_defconfig
index 40ad810..873160d 100644
--- a/configs/P1010RDB-PA_36BIT_SDCARD_defconfig
+++ b/configs/P1010RDB-PA_36BIT_SDCARD_defconfig
@@ -46,3 +46,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_36BIT_SPIFLASH_SECBOOT_defconfig b/configs/P1010RDB-PA_36BIT_SPIFLASH_SECBOOT_defconfig
index 240b413..548e3f9 100644
--- a/configs/P1010RDB-PA_36BIT_SPIFLASH_SECBOOT_defconfig
+++ b/configs/P1010RDB-PA_36BIT_SPIFLASH_SECBOOT_defconfig
@@ -41,3 +41,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_36BIT_SPIFLASH_defconfig b/configs/P1010RDB-PA_36BIT_SPIFLASH_defconfig
index c159bad..8c0f8b7 100644
--- a/configs/P1010RDB-PA_36BIT_SPIFLASH_defconfig
+++ b/configs/P1010RDB-PA_36BIT_SPIFLASH_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_NAND_SECBOOT_defconfig b/configs/P1010RDB-PA_NAND_SECBOOT_defconfig
index a49c837..0e492e9 100644
--- a/configs/P1010RDB-PA_NAND_SECBOOT_defconfig
+++ b/configs/P1010RDB-PA_NAND_SECBOOT_defconfig
@@ -40,3 +40,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_NOR_SECBOOT_defconfig b/configs/P1010RDB-PA_NOR_SECBOOT_defconfig
index e149a76..618e3e9 100644
--- a/configs/P1010RDB-PA_NOR_SECBOOT_defconfig
+++ b/configs/P1010RDB-PA_NOR_SECBOOT_defconfig
@@ -39,3 +39,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_NOR_defconfig b/configs/P1010RDB-PA_NOR_defconfig
index 9f96128..0c4c07e 100644
--- a/configs/P1010RDB-PA_NOR_defconfig
+++ b/configs/P1010RDB-PA_NOR_defconfig
@@ -35,3 +35,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_SDCARD_defconfig b/configs/P1010RDB-PA_SDCARD_defconfig
index 2a62987..a2ac5f6 100644
--- a/configs/P1010RDB-PA_SDCARD_defconfig
+++ b/configs/P1010RDB-PA_SDCARD_defconfig
@@ -45,3 +45,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_SPIFLASH_SECBOOT_defconfig b/configs/P1010RDB-PA_SPIFLASH_SECBOOT_defconfig
index d51d3ff..7b85841 100644
--- a/configs/P1010RDB-PA_SPIFLASH_SECBOOT_defconfig
+++ b/configs/P1010RDB-PA_SPIFLASH_SECBOOT_defconfig
@@ -40,3 +40,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PA_SPIFLASH_defconfig b/configs/P1010RDB-PA_SPIFLASH_defconfig
index b08a0e7..ca084c7 100644
--- a/configs/P1010RDB-PA_SPIFLASH_defconfig
+++ b/configs/P1010RDB-PA_SPIFLASH_defconfig
@@ -46,3 +46,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_36BIT_NAND_SECBOOT_defconfig b/configs/P1010RDB-PB_36BIT_NAND_SECBOOT_defconfig
index eb394bf..c8f8010 100644
--- a/configs/P1010RDB-PB_36BIT_NAND_SECBOOT_defconfig
+++ b/configs/P1010RDB-PB_36BIT_NAND_SECBOOT_defconfig
@@ -41,3 +41,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_36BIT_NOR_SECBOOT_defconfig b/configs/P1010RDB-PB_36BIT_NOR_SECBOOT_defconfig
index d5cb8af..64a799d 100644
--- a/configs/P1010RDB-PB_36BIT_NOR_SECBOOT_defconfig
+++ b/configs/P1010RDB-PB_36BIT_NOR_SECBOOT_defconfig
@@ -40,3 +40,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_36BIT_NOR_defconfig b/configs/P1010RDB-PB_36BIT_NOR_defconfig
index 72d669d..332d4b0 100644
--- a/configs/P1010RDB-PB_36BIT_NOR_defconfig
+++ b/configs/P1010RDB-PB_36BIT_NOR_defconfig
@@ -36,3 +36,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_36BIT_SDCARD_defconfig b/configs/P1010RDB-PB_36BIT_SDCARD_defconfig
index b59532d..22d339f 100644
--- a/configs/P1010RDB-PB_36BIT_SDCARD_defconfig
+++ b/configs/P1010RDB-PB_36BIT_SDCARD_defconfig
@@ -46,3 +46,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_36BIT_SPIFLASH_SECBOOT_defconfig b/configs/P1010RDB-PB_36BIT_SPIFLASH_SECBOOT_defconfig
index 2ee9ec3..721f789 100644
--- a/configs/P1010RDB-PB_36BIT_SPIFLASH_SECBOOT_defconfig
+++ b/configs/P1010RDB-PB_36BIT_SPIFLASH_SECBOOT_defconfig
@@ -41,3 +41,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_36BIT_SPIFLASH_defconfig b/configs/P1010RDB-PB_36BIT_SPIFLASH_defconfig
index ca618a0..3e09f04 100644
--- a/configs/P1010RDB-PB_36BIT_SPIFLASH_defconfig
+++ b/configs/P1010RDB-PB_36BIT_SPIFLASH_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_NAND_SECBOOT_defconfig b/configs/P1010RDB-PB_NAND_SECBOOT_defconfig
index 582d1aa..3c550f1 100644
--- a/configs/P1010RDB-PB_NAND_SECBOOT_defconfig
+++ b/configs/P1010RDB-PB_NAND_SECBOOT_defconfig
@@ -40,3 +40,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_NOR_SECBOOT_defconfig b/configs/P1010RDB-PB_NOR_SECBOOT_defconfig
index 3ae5485..71b3b56 100644
--- a/configs/P1010RDB-PB_NOR_SECBOOT_defconfig
+++ b/configs/P1010RDB-PB_NOR_SECBOOT_defconfig
@@ -39,3 +39,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_NOR_defconfig b/configs/P1010RDB-PB_NOR_defconfig
index 68a68df..032e993 100644
--- a/configs/P1010RDB-PB_NOR_defconfig
+++ b/configs/P1010RDB-PB_NOR_defconfig
@@ -35,3 +35,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_SDCARD_defconfig b/configs/P1010RDB-PB_SDCARD_defconfig
index 9db32c1..8bb89aa 100644
--- a/configs/P1010RDB-PB_SDCARD_defconfig
+++ b/configs/P1010RDB-PB_SDCARD_defconfig
@@ -45,3 +45,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_SPIFLASH_SECBOOT_defconfig b/configs/P1010RDB-PB_SPIFLASH_SECBOOT_defconfig
index 80f8c27..d7f4b67 100644
--- a/configs/P1010RDB-PB_SPIFLASH_SECBOOT_defconfig
+++ b/configs/P1010RDB-PB_SPIFLASH_SECBOOT_defconfig
@@ -40,3 +40,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1010RDB-PB_SPIFLASH_defconfig b/configs/P1010RDB-PB_SPIFLASH_defconfig
index 7ba107d..3b4409a 100644
--- a/configs/P1010RDB-PB_SPIFLASH_defconfig
+++ b/configs/P1010RDB-PB_SPIFLASH_defconfig
@@ -46,3 +46,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1020RDB-PC_36BIT_SDCARD_defconfig b/configs/P1020RDB-PC_36BIT_SDCARD_defconfig
index 5c14609..b522c11 100644
--- a/configs/P1020RDB-PC_36BIT_SDCARD_defconfig
+++ b/configs/P1020RDB-PC_36BIT_SDCARD_defconfig
@@ -43,3 +43,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1020RDB-PC_36BIT_SPIFLASH_defconfig b/configs/P1020RDB-PC_36BIT_SPIFLASH_defconfig
index 6a5c1f9..10a0600 100644
--- a/configs/P1020RDB-PC_36BIT_SPIFLASH_defconfig
+++ b/configs/P1020RDB-PC_36BIT_SPIFLASH_defconfig
@@ -44,3 +44,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1020RDB-PC_36BIT_defconfig b/configs/P1020RDB-PC_36BIT_defconfig
index 0581507..14a6697 100644
--- a/configs/P1020RDB-PC_36BIT_defconfig
+++ b/configs/P1020RDB-PC_36BIT_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1020RDB-PC_SDCARD_defconfig b/configs/P1020RDB-PC_SDCARD_defconfig
index eb9d9a8..cfc0bbb 100644
--- a/configs/P1020RDB-PC_SDCARD_defconfig
+++ b/configs/P1020RDB-PC_SDCARD_defconfig
@@ -42,3 +42,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1020RDB-PC_SPIFLASH_defconfig b/configs/P1020RDB-PC_SPIFLASH_defconfig
index 256b714..880f87b 100644
--- a/configs/P1020RDB-PC_SPIFLASH_defconfig
+++ b/configs/P1020RDB-PC_SPIFLASH_defconfig
@@ -43,3 +43,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1020RDB-PC_defconfig b/configs/P1020RDB-PC_defconfig
index e39ad20..e4c2ade 100644
--- a/configs/P1020RDB-PC_defconfig
+++ b/configs/P1020RDB-PC_defconfig
@@ -33,3 +33,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1020RDB-PD_SDCARD_defconfig b/configs/P1020RDB-PD_SDCARD_defconfig
index 400471a..efaadae 100644
--- a/configs/P1020RDB-PD_SDCARD_defconfig
+++ b/configs/P1020RDB-PD_SDCARD_defconfig
@@ -45,3 +45,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1020RDB-PD_SPIFLASH_defconfig b/configs/P1020RDB-PD_SPIFLASH_defconfig
index a004df4..3387597 100644
--- a/configs/P1020RDB-PD_SPIFLASH_defconfig
+++ b/configs/P1020RDB-PD_SPIFLASH_defconfig
@@ -46,3 +46,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1020RDB-PD_defconfig b/configs/P1020RDB-PD_defconfig
index 3c88e48..424457e 100644
--- a/configs/P1020RDB-PD_defconfig
+++ b/configs/P1020RDB-PD_defconfig
@@ -36,3 +36,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1021RDB-PC_36BIT_SDCARD_defconfig b/configs/P1021RDB-PC_36BIT_SDCARD_defconfig
index 45a74b2..71292b1f 100644
--- a/configs/P1021RDB-PC_36BIT_SDCARD_defconfig
+++ b/configs/P1021RDB-PC_36BIT_SDCARD_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1021RDB-PC_36BIT_SPIFLASH_defconfig b/configs/P1021RDB-PC_36BIT_SPIFLASH_defconfig
index 14d73ed..8955859 100644
--- a/configs/P1021RDB-PC_36BIT_SPIFLASH_defconfig
+++ b/configs/P1021RDB-PC_36BIT_SPIFLASH_defconfig
@@ -48,3 +48,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1021RDB-PC_36BIT_defconfig b/configs/P1021RDB-PC_36BIT_defconfig
index a72458c..edd9987 100644
--- a/configs/P1021RDB-PC_36BIT_defconfig
+++ b/configs/P1021RDB-PC_36BIT_defconfig
@@ -38,3 +38,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1021RDB-PC_SDCARD_defconfig b/configs/P1021RDB-PC_SDCARD_defconfig
index 0cff7ff..03067a3 100644
--- a/configs/P1021RDB-PC_SDCARD_defconfig
+++ b/configs/P1021RDB-PC_SDCARD_defconfig
@@ -46,3 +46,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1021RDB-PC_SPIFLASH_defconfig b/configs/P1021RDB-PC_SPIFLASH_defconfig
index 37f7f0f..ea8b735 100644
--- a/configs/P1021RDB-PC_SPIFLASH_defconfig
+++ b/configs/P1021RDB-PC_SPIFLASH_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1021RDB-PC_defconfig b/configs/P1021RDB-PC_defconfig
index 69b5c90..50eef82 100644
--- a/configs/P1021RDB-PC_defconfig
+++ b/configs/P1021RDB-PC_defconfig
@@ -37,3 +37,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1022DS_36BIT_SDCARD_defconfig b/configs/P1022DS_36BIT_SDCARD_defconfig
index 7d29f96..ff03e14 100644
--- a/configs/P1022DS_36BIT_SDCARD_defconfig
+++ b/configs/P1022DS_36BIT_SDCARD_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1022DS_36BIT_SPIFLASH_defconfig b/configs/P1022DS_36BIT_SPIFLASH_defconfig
index a98f108..a38984d 100644
--- a/configs/P1022DS_36BIT_SPIFLASH_defconfig
+++ b/configs/P1022DS_36BIT_SPIFLASH_defconfig
@@ -48,3 +48,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1022DS_36BIT_defconfig b/configs/P1022DS_36BIT_defconfig
index 352b397..22b4699 100644
--- a/configs/P1022DS_36BIT_defconfig
+++ b/configs/P1022DS_36BIT_defconfig
@@ -38,3 +38,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1022DS_SDCARD_defconfig b/configs/P1022DS_SDCARD_defconfig
index 6b039fe..3c72819 100644
--- a/configs/P1022DS_SDCARD_defconfig
+++ b/configs/P1022DS_SDCARD_defconfig
@@ -46,3 +46,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1022DS_SPIFLASH_defconfig b/configs/P1022DS_SPIFLASH_defconfig
index f128a87..2a95cf5 100644
--- a/configs/P1022DS_SPIFLASH_defconfig
+++ b/configs/P1022DS_SPIFLASH_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1022DS_defconfig b/configs/P1022DS_defconfig
index 8690b02..5523d3f 100644
--- a/configs/P1022DS_defconfig
+++ b/configs/P1022DS_defconfig
@@ -37,3 +37,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1023RDB_defconfig b/configs/P1023RDB_defconfig
index bfe84a9..5ad1774 100644
--- a/configs/P1023RDB_defconfig
+++ b/configs/P1023RDB_defconfig
@@ -32,3 +32,4 @@  CONFIG_SYS_NS16550=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1024RDB_36BIT_defconfig b/configs/P1024RDB_36BIT_defconfig
index a310192..6ce5e79 100644
--- a/configs/P1024RDB_36BIT_defconfig
+++ b/configs/P1024RDB_36BIT_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1024RDB_SDCARD_defconfig b/configs/P1024RDB_SDCARD_defconfig
index 0bf2c36..7a6a188 100644
--- a/configs/P1024RDB_SDCARD_defconfig
+++ b/configs/P1024RDB_SDCARD_defconfig
@@ -42,3 +42,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1024RDB_SPIFLASH_defconfig b/configs/P1024RDB_SPIFLASH_defconfig
index 4f64c7e..c850d6e 100644
--- a/configs/P1024RDB_SPIFLASH_defconfig
+++ b/configs/P1024RDB_SPIFLASH_defconfig
@@ -43,3 +43,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1024RDB_defconfig b/configs/P1024RDB_defconfig
index aaa7228..384df04 100644
--- a/configs/P1024RDB_defconfig
+++ b/configs/P1024RDB_defconfig
@@ -33,3 +33,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1025RDB_36BIT_defconfig b/configs/P1025RDB_36BIT_defconfig
index de6a904..62578c3 100644
--- a/configs/P1025RDB_36BIT_defconfig
+++ b/configs/P1025RDB_36BIT_defconfig
@@ -36,3 +36,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1025RDB_SDCARD_defconfig b/configs/P1025RDB_SDCARD_defconfig
index 8049e0a..7c52bcc 100644
--- a/configs/P1025RDB_SDCARD_defconfig
+++ b/configs/P1025RDB_SDCARD_defconfig
@@ -44,3 +44,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1025RDB_SPIFLASH_defconfig b/configs/P1025RDB_SPIFLASH_defconfig
index 3e1c62d..62618ed 100644
--- a/configs/P1025RDB_SPIFLASH_defconfig
+++ b/configs/P1025RDB_SPIFLASH_defconfig
@@ -45,3 +45,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P1025RDB_defconfig b/configs/P1025RDB_defconfig
index 91ab8b8..ce63b02 100644
--- a/configs/P1025RDB_defconfig
+++ b/configs/P1025RDB_defconfig
@@ -35,3 +35,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2020RDB-PC_36BIT_SDCARD_defconfig b/configs/P2020RDB-PC_36BIT_SDCARD_defconfig
index 2f9702e..9543834 100644
--- a/configs/P2020RDB-PC_36BIT_SDCARD_defconfig
+++ b/configs/P2020RDB-PC_36BIT_SDCARD_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2020RDB-PC_36BIT_SPIFLASH_defconfig b/configs/P2020RDB-PC_36BIT_SPIFLASH_defconfig
index 539b884..01f8156 100644
--- a/configs/P2020RDB-PC_36BIT_SPIFLASH_defconfig
+++ b/configs/P2020RDB-PC_36BIT_SPIFLASH_defconfig
@@ -48,3 +48,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2020RDB-PC_36BIT_defconfig b/configs/P2020RDB-PC_36BIT_defconfig
index 8b08443..9934bb3 100644
--- a/configs/P2020RDB-PC_36BIT_defconfig
+++ b/configs/P2020RDB-PC_36BIT_defconfig
@@ -38,3 +38,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2020RDB-PC_SDCARD_defconfig b/configs/P2020RDB-PC_SDCARD_defconfig
index f2322ba..b0b8577 100644
--- a/configs/P2020RDB-PC_SDCARD_defconfig
+++ b/configs/P2020RDB-PC_SDCARD_defconfig
@@ -46,3 +46,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2020RDB-PC_SPIFLASH_defconfig b/configs/P2020RDB-PC_SPIFLASH_defconfig
index e893f78..7ab3a37 100644
--- a/configs/P2020RDB-PC_SPIFLASH_defconfig
+++ b/configs/P2020RDB-PC_SPIFLASH_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2020RDB-PC_defconfig b/configs/P2020RDB-PC_defconfig
index f470768..99d22c5 100644
--- a/configs/P2020RDB-PC_defconfig
+++ b/configs/P2020RDB-PC_defconfig
@@ -37,3 +37,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2041RDB_SDCARD_defconfig b/configs/P2041RDB_SDCARD_defconfig
index 40f4e9f..ebcf35c 100644
--- a/configs/P2041RDB_SDCARD_defconfig
+++ b/configs/P2041RDB_SDCARD_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2041RDB_SECURE_BOOT_defconfig b/configs/P2041RDB_SECURE_BOOT_defconfig
index a63df61..db281cf 100644
--- a/configs/P2041RDB_SECURE_BOOT_defconfig
+++ b/configs/P2041RDB_SECURE_BOOT_defconfig
@@ -37,3 +37,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2041RDB_SPIFLASH_defconfig b/configs/P2041RDB_SPIFLASH_defconfig
index da963b3..89663fe 100644
--- a/configs/P2041RDB_SPIFLASH_defconfig
+++ b/configs/P2041RDB_SPIFLASH_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2041RDB_SRIO_PCIE_BOOT_defconfig b/configs/P2041RDB_SRIO_PCIE_BOOT_defconfig
index d5e958c..bd78e8d 100644
--- a/configs/P2041RDB_SRIO_PCIE_BOOT_defconfig
+++ b/configs/P2041RDB_SRIO_PCIE_BOOT_defconfig
@@ -33,3 +33,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P2041RDB_defconfig b/configs/P2041RDB_defconfig
index e693adc..adf6d90 100644
--- a/configs/P2041RDB_defconfig
+++ b/configs/P2041RDB_defconfig
@@ -33,3 +33,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P3041DS_SDCARD_defconfig b/configs/P3041DS_SDCARD_defconfig
index 09b17b5..9694d3b 100644
--- a/configs/P3041DS_SDCARD_defconfig
+++ b/configs/P3041DS_SDCARD_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P3041DS_SECURE_BOOT_defconfig b/configs/P3041DS_SECURE_BOOT_defconfig
index 7befcb0..3082159 100644
--- a/configs/P3041DS_SECURE_BOOT_defconfig
+++ b/configs/P3041DS_SECURE_BOOT_defconfig
@@ -37,3 +37,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P3041DS_SPIFLASH_defconfig b/configs/P3041DS_SPIFLASH_defconfig
index 31ffc1c..ef57166 100644
--- a/configs/P3041DS_SPIFLASH_defconfig
+++ b/configs/P3041DS_SPIFLASH_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P3041DS_SRIO_PCIE_BOOT_defconfig b/configs/P3041DS_SRIO_PCIE_BOOT_defconfig
index 8a66ba7..4b025f8 100644
--- a/configs/P3041DS_SRIO_PCIE_BOOT_defconfig
+++ b/configs/P3041DS_SRIO_PCIE_BOOT_defconfig
@@ -33,3 +33,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P3041DS_defconfig b/configs/P3041DS_defconfig
index 2f28f24..787cf6e 100644
--- a/configs/P3041DS_defconfig
+++ b/configs/P3041DS_defconfig
@@ -33,3 +33,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P5020DS_SDCARD_defconfig b/configs/P5020DS_SDCARD_defconfig
index 4e0fabd..bead90e 100644
--- a/configs/P5020DS_SDCARD_defconfig
+++ b/configs/P5020DS_SDCARD_defconfig
@@ -35,3 +35,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P5020DS_SECURE_BOOT_defconfig b/configs/P5020DS_SECURE_BOOT_defconfig
index 52aafe9..ce71afd 100644
--- a/configs/P5020DS_SECURE_BOOT_defconfig
+++ b/configs/P5020DS_SECURE_BOOT_defconfig
@@ -38,3 +38,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P5020DS_SPIFLASH_defconfig b/configs/P5020DS_SPIFLASH_defconfig
index b52c41f..7b8f86a 100644
--- a/configs/P5020DS_SPIFLASH_defconfig
+++ b/configs/P5020DS_SPIFLASH_defconfig
@@ -35,3 +35,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P5020DS_SRIO_PCIE_BOOT_defconfig b/configs/P5020DS_SRIO_PCIE_BOOT_defconfig
index ab04c24..f98e027 100644
--- a/configs/P5020DS_SRIO_PCIE_BOOT_defconfig
+++ b/configs/P5020DS_SRIO_PCIE_BOOT_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P5020DS_defconfig b/configs/P5020DS_defconfig
index 04d97da..676e26a 100644
--- a/configs/P5020DS_defconfig
+++ b/configs/P5020DS_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P5040DS_SDCARD_defconfig b/configs/P5040DS_SDCARD_defconfig
index 75cdd18..a3b77df 100644
--- a/configs/P5040DS_SDCARD_defconfig
+++ b/configs/P5040DS_SDCARD_defconfig
@@ -35,3 +35,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P5040DS_SECURE_BOOT_defconfig b/configs/P5040DS_SECURE_BOOT_defconfig
index 9ccb18b..50e76ef 100644
--- a/configs/P5040DS_SECURE_BOOT_defconfig
+++ b/configs/P5040DS_SECURE_BOOT_defconfig
@@ -38,3 +38,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P5040DS_SPIFLASH_defconfig b/configs/P5040DS_SPIFLASH_defconfig
index cf35c25..44ae245 100644
--- a/configs/P5040DS_SPIFLASH_defconfig
+++ b/configs/P5040DS_SPIFLASH_defconfig
@@ -35,3 +35,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/P5040DS_defconfig b/configs/P5040DS_defconfig
index 7c94ecb..f2f2cf5 100644
--- a/configs/P5040DS_defconfig
+++ b/configs/P5040DS_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1023RDB_SDCARD_defconfig b/configs/T1023RDB_SDCARD_defconfig
index b79e56b..01d09cd 100644
--- a/configs/T1023RDB_SDCARD_defconfig
+++ b/configs/T1023RDB_SDCARD_defconfig
@@ -48,3 +48,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1023RDB_SECURE_BOOT_defconfig b/configs/T1023RDB_SECURE_BOOT_defconfig
index fa69b83..67c5094 100644
--- a/configs/T1023RDB_SECURE_BOOT_defconfig
+++ b/configs/T1023RDB_SECURE_BOOT_defconfig
@@ -42,3 +42,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1023RDB_SPIFLASH_defconfig b/configs/T1023RDB_SPIFLASH_defconfig
index 5c25c62..2cf8980 100644
--- a/configs/T1023RDB_SPIFLASH_defconfig
+++ b/configs/T1023RDB_SPIFLASH_defconfig
@@ -49,3 +49,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1023RDB_defconfig b/configs/T1023RDB_defconfig
index 50de58b..3ac2ca3 100644
--- a/configs/T1023RDB_defconfig
+++ b/configs/T1023RDB_defconfig
@@ -38,3 +38,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1024QDS_DDR4_SECURE_BOOT_defconfig b/configs/T1024QDS_DDR4_SECURE_BOOT_defconfig
index 372c74f..19c1432 100644
--- a/configs/T1024QDS_DDR4_SECURE_BOOT_defconfig
+++ b/configs/T1024QDS_DDR4_SECURE_BOOT_defconfig
@@ -47,3 +47,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1024QDS_DDR4_defconfig b/configs/T1024QDS_DDR4_defconfig
index 4a09a5c..30238a3 100644
--- a/configs/T1024QDS_DDR4_defconfig
+++ b/configs/T1024QDS_DDR4_defconfig
@@ -41,3 +41,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1024QDS_SDCARD_defconfig b/configs/T1024QDS_SDCARD_defconfig
index 66458c0..938f150 100644
--- a/configs/T1024QDS_SDCARD_defconfig
+++ b/configs/T1024QDS_SDCARD_defconfig
@@ -54,3 +54,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1024QDS_SECURE_BOOT_defconfig b/configs/T1024QDS_SECURE_BOOT_defconfig
index b974cea..8395a35 100644
--- a/configs/T1024QDS_SECURE_BOOT_defconfig
+++ b/configs/T1024QDS_SECURE_BOOT_defconfig
@@ -48,3 +48,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1024QDS_SPIFLASH_defconfig b/configs/T1024QDS_SPIFLASH_defconfig
index 768d302..234fe09 100644
--- a/configs/T1024QDS_SPIFLASH_defconfig
+++ b/configs/T1024QDS_SPIFLASH_defconfig
@@ -55,3 +55,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1024QDS_defconfig b/configs/T1024QDS_defconfig
index 0e536d9..1221d60 100644
--- a/configs/T1024QDS_defconfig
+++ b/configs/T1024QDS_defconfig
@@ -44,3 +44,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1024RDB_SDCARD_defconfig b/configs/T1024RDB_SDCARD_defconfig
index c1b6b96..2ce895b 100644
--- a/configs/T1024RDB_SDCARD_defconfig
+++ b/configs/T1024RDB_SDCARD_defconfig
@@ -50,3 +50,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1024RDB_SECURE_BOOT_defconfig b/configs/T1024RDB_SECURE_BOOT_defconfig
index d86235b..ee67fb8 100644
--- a/configs/T1024RDB_SECURE_BOOT_defconfig
+++ b/configs/T1024RDB_SECURE_BOOT_defconfig
@@ -44,3 +44,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1024RDB_SPIFLASH_defconfig b/configs/T1024RDB_SPIFLASH_defconfig
index 4dd6c9a..084f3e5 100644
--- a/configs/T1024RDB_SPIFLASH_defconfig
+++ b/configs/T1024RDB_SPIFLASH_defconfig
@@ -51,3 +51,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1024RDB_defconfig b/configs/T1024RDB_defconfig
index 39952e1..be7d973 100644
--- a/configs/T1024RDB_defconfig
+++ b/configs/T1024RDB_defconfig
@@ -40,3 +40,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040D4RDB_SDCARD_defconfig b/configs/T1040D4RDB_SDCARD_defconfig
index d098b0c..07c62c3 100644
--- a/configs/T1040D4RDB_SDCARD_defconfig
+++ b/configs/T1040D4RDB_SDCARD_defconfig
@@ -48,3 +48,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040D4RDB_SECURE_BOOT_defconfig b/configs/T1040D4RDB_SECURE_BOOT_defconfig
index fdfa753..e86120e 100644
--- a/configs/T1040D4RDB_SECURE_BOOT_defconfig
+++ b/configs/T1040D4RDB_SECURE_BOOT_defconfig
@@ -42,3 +42,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040D4RDB_SPIFLASH_defconfig b/configs/T1040D4RDB_SPIFLASH_defconfig
index 0874adf..06166c5 100644
--- a/configs/T1040D4RDB_SPIFLASH_defconfig
+++ b/configs/T1040D4RDB_SPIFLASH_defconfig
@@ -49,3 +49,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040D4RDB_defconfig b/configs/T1040D4RDB_defconfig
index a16c683..a2fbe04 100644
--- a/configs/T1040D4RDB_defconfig
+++ b/configs/T1040D4RDB_defconfig
@@ -38,3 +38,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040QDS_DDR4_defconfig b/configs/T1040QDS_DDR4_defconfig
index c7e6f20..17ebec3 100644
--- a/configs/T1040QDS_DDR4_defconfig
+++ b/configs/T1040QDS_DDR4_defconfig
@@ -44,3 +44,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040QDS_SECURE_BOOT_defconfig b/configs/T1040QDS_SECURE_BOOT_defconfig
index 8cb1a55..c926aab 100644
--- a/configs/T1040QDS_SECURE_BOOT_defconfig
+++ b/configs/T1040QDS_SECURE_BOOT_defconfig
@@ -49,3 +49,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040QDS_defconfig b/configs/T1040QDS_defconfig
index 273ffed..f35a6eb 100644
--- a/configs/T1040QDS_defconfig
+++ b/configs/T1040QDS_defconfig
@@ -45,3 +45,4 @@  CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040RDB_SDCARD_defconfig b/configs/T1040RDB_SDCARD_defconfig
index f53eb22..a8797aa 100644
--- a/configs/T1040RDB_SDCARD_defconfig
+++ b/configs/T1040RDB_SDCARD_defconfig
@@ -49,3 +49,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040RDB_SECURE_BOOT_defconfig b/configs/T1040RDB_SECURE_BOOT_defconfig
index 673b898..921c5bb 100644
--- a/configs/T1040RDB_SECURE_BOOT_defconfig
+++ b/configs/T1040RDB_SECURE_BOOT_defconfig
@@ -43,3 +43,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040RDB_SPIFLASH_defconfig b/configs/T1040RDB_SPIFLASH_defconfig
index 483f328..24164f2 100644
--- a/configs/T1040RDB_SPIFLASH_defconfig
+++ b/configs/T1040RDB_SPIFLASH_defconfig
@@ -50,3 +50,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1040RDB_defconfig b/configs/T1040RDB_defconfig
index 3cf163c..a34b3ee 100644
--- a/configs/T1040RDB_defconfig
+++ b/configs/T1040RDB_defconfig
@@ -39,3 +39,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1042D4RDB_SDCARD_defconfig b/configs/T1042D4RDB_SDCARD_defconfig
index 0f5b5d7..9ad6b48 100644
--- a/configs/T1042D4RDB_SDCARD_defconfig
+++ b/configs/T1042D4RDB_SDCARD_defconfig
@@ -51,3 +51,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_CFB_CONSOLE_ANSI=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1042D4RDB_SECURE_BOOT_defconfig b/configs/T1042D4RDB_SECURE_BOOT_defconfig
index 20a15a3..2887808 100644
--- a/configs/T1042D4RDB_SECURE_BOOT_defconfig
+++ b/configs/T1042D4RDB_SECURE_BOOT_defconfig
@@ -45,3 +45,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1042D4RDB_SPIFLASH_defconfig b/configs/T1042D4RDB_SPIFLASH_defconfig
index 5aecf06..b6d4ba5 100644
--- a/configs/T1042D4RDB_SPIFLASH_defconfig
+++ b/configs/T1042D4RDB_SPIFLASH_defconfig
@@ -52,3 +52,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_CFB_CONSOLE_ANSI=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1042D4RDB_defconfig b/configs/T1042D4RDB_defconfig
index f57aa71..4147958 100644
--- a/configs/T1042D4RDB_defconfig
+++ b/configs/T1042D4RDB_defconfig
@@ -41,3 +41,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_CFB_CONSOLE_ANSI=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1042RDB_PI_SDCARD_defconfig b/configs/T1042RDB_PI_SDCARD_defconfig
index 953bcf2..514ff2e 100644
--- a/configs/T1042RDB_PI_SDCARD_defconfig
+++ b/configs/T1042RDB_PI_SDCARD_defconfig
@@ -53,3 +53,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_CFB_CONSOLE_ANSI=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1042RDB_PI_SPIFLASH_defconfig b/configs/T1042RDB_PI_SPIFLASH_defconfig
index 541b69b..626f70c 100644
--- a/configs/T1042RDB_PI_SPIFLASH_defconfig
+++ b/configs/T1042RDB_PI_SPIFLASH_defconfig
@@ -54,3 +54,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_CFB_CONSOLE_ANSI=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1042RDB_PI_defconfig b/configs/T1042RDB_PI_defconfig
index a3e036b..f2374d9 100644
--- a/configs/T1042RDB_PI_defconfig
+++ b/configs/T1042RDB_PI_defconfig
@@ -43,3 +43,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_CFB_CONSOLE_ANSI=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1042RDB_SECURE_BOOT_defconfig b/configs/T1042RDB_SECURE_BOOT_defconfig
index b207fe0..cb63864 100644
--- a/configs/T1042RDB_SECURE_BOOT_defconfig
+++ b/configs/T1042RDB_SECURE_BOOT_defconfig
@@ -42,3 +42,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T1042RDB_defconfig b/configs/T1042RDB_defconfig
index 44ce197..567cb9c 100644
--- a/configs/T1042RDB_defconfig
+++ b/configs/T1042RDB_defconfig
@@ -38,3 +38,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2080QDS_SDCARD_defconfig b/configs/T2080QDS_SDCARD_defconfig
index d35dfd8..09b4093 100644
--- a/configs/T2080QDS_SDCARD_defconfig
+++ b/configs/T2080QDS_SDCARD_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2080QDS_SECURE_BOOT_defconfig b/configs/T2080QDS_SECURE_BOOT_defconfig
index 402132b..3b0ba6b 100644
--- a/configs/T2080QDS_SECURE_BOOT_defconfig
+++ b/configs/T2080QDS_SECURE_BOOT_defconfig
@@ -41,3 +41,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2080QDS_SPIFLASH_defconfig b/configs/T2080QDS_SPIFLASH_defconfig
index 0b20543..a306b10 100644
--- a/configs/T2080QDS_SPIFLASH_defconfig
+++ b/configs/T2080QDS_SPIFLASH_defconfig
@@ -48,3 +48,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2080QDS_SRIO_PCIE_BOOT_defconfig b/configs/T2080QDS_SRIO_PCIE_BOOT_defconfig
index 2479450..39c4f7d 100644
--- a/configs/T2080QDS_SRIO_PCIE_BOOT_defconfig
+++ b/configs/T2080QDS_SRIO_PCIE_BOOT_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2080QDS_defconfig b/configs/T2080QDS_defconfig
index 6151f86..90fa707 100644
--- a/configs/T2080QDS_defconfig
+++ b/configs/T2080QDS_defconfig
@@ -37,3 +37,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2080RDB_SDCARD_defconfig b/configs/T2080RDB_SDCARD_defconfig
index e07818a..c7676fe 100644
--- a/configs/T2080RDB_SDCARD_defconfig
+++ b/configs/T2080RDB_SDCARD_defconfig
@@ -46,3 +46,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2080RDB_SECURE_BOOT_defconfig b/configs/T2080RDB_SECURE_BOOT_defconfig
index c5d754c..696ce74 100644
--- a/configs/T2080RDB_SECURE_BOOT_defconfig
+++ b/configs/T2080RDB_SECURE_BOOT_defconfig
@@ -40,3 +40,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2080RDB_SPIFLASH_defconfig b/configs/T2080RDB_SPIFLASH_defconfig
index 1443956..a81b618 100644
--- a/configs/T2080RDB_SPIFLASH_defconfig
+++ b/configs/T2080RDB_SPIFLASH_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2080RDB_SRIO_PCIE_BOOT_defconfig b/configs/T2080RDB_SRIO_PCIE_BOOT_defconfig
index 073f447..06e48c0 100644
--- a/configs/T2080RDB_SRIO_PCIE_BOOT_defconfig
+++ b/configs/T2080RDB_SRIO_PCIE_BOOT_defconfig
@@ -33,3 +33,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2080RDB_defconfig b/configs/T2080RDB_defconfig
index 0a3a698..4af2c6a 100644
--- a/configs/T2080RDB_defconfig
+++ b/configs/T2080RDB_defconfig
@@ -36,3 +36,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2081QDS_SDCARD_defconfig b/configs/T2081QDS_SDCARD_defconfig
index 75267c1..579915c 100644
--- a/configs/T2081QDS_SDCARD_defconfig
+++ b/configs/T2081QDS_SDCARD_defconfig
@@ -47,3 +47,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2081QDS_SPIFLASH_defconfig b/configs/T2081QDS_SPIFLASH_defconfig
index f3f40ca..ac4f930 100644
--- a/configs/T2081QDS_SPIFLASH_defconfig
+++ b/configs/T2081QDS_SPIFLASH_defconfig
@@ -48,3 +48,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2081QDS_SRIO_PCIE_BOOT_defconfig b/configs/T2081QDS_SRIO_PCIE_BOOT_defconfig
index 8b1f6e4..69d5ec0 100644
--- a/configs/T2081QDS_SRIO_PCIE_BOOT_defconfig
+++ b/configs/T2081QDS_SRIO_PCIE_BOOT_defconfig
@@ -34,3 +34,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T2081QDS_defconfig b/configs/T2081QDS_defconfig
index 86e99dd..f4f17ad 100644
--- a/configs/T2081QDS_defconfig
+++ b/configs/T2081QDS_defconfig
@@ -37,3 +37,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T4160QDS_SDCARD_defconfig b/configs/T4160QDS_SDCARD_defconfig
index 5422278..7c55561 100644
--- a/configs/T4160QDS_SDCARD_defconfig
+++ b/configs/T4160QDS_SDCARD_defconfig
@@ -42,3 +42,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T4160QDS_SECURE_BOOT_defconfig b/configs/T4160QDS_SECURE_BOOT_defconfig
index 8462ff5..f22592a 100644
--- a/configs/T4160QDS_SECURE_BOOT_defconfig
+++ b/configs/T4160QDS_SECURE_BOOT_defconfig
@@ -36,3 +36,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T4160QDS_defconfig b/configs/T4160QDS_defconfig
index c069cf5..9523493 100644
--- a/configs/T4160QDS_defconfig
+++ b/configs/T4160QDS_defconfig
@@ -32,3 +32,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T4160RDB_defconfig b/configs/T4160RDB_defconfig
index cb5359a..f45a60e 100644
--- a/configs/T4160RDB_defconfig
+++ b/configs/T4160RDB_defconfig
@@ -32,3 +32,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T4240QDS_SDCARD_defconfig b/configs/T4240QDS_SDCARD_defconfig
index 95ca2a8..b38bc2e 100644
--- a/configs/T4240QDS_SDCARD_defconfig
+++ b/configs/T4240QDS_SDCARD_defconfig
@@ -42,3 +42,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T4240QDS_SECURE_BOOT_defconfig b/configs/T4240QDS_SECURE_BOOT_defconfig
index ff27ff5..678b388 100644
--- a/configs/T4240QDS_SECURE_BOOT_defconfig
+++ b/configs/T4240QDS_SECURE_BOOT_defconfig
@@ -36,3 +36,4 @@  CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T4240QDS_SRIO_PCIE_BOOT_defconfig b/configs/T4240QDS_SRIO_PCIE_BOOT_defconfig
index 29c5489..5914b3b 100644
--- a/configs/T4240QDS_SRIO_PCIE_BOOT_defconfig
+++ b/configs/T4240QDS_SRIO_PCIE_BOOT_defconfig
@@ -32,3 +32,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T4240QDS_defconfig b/configs/T4240QDS_defconfig
index 4dc8ccd..093437f 100644
--- a/configs/T4240QDS_defconfig
+++ b/configs/T4240QDS_defconfig
@@ -32,3 +32,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T4240RDB_SDCARD_defconfig b/configs/T4240RDB_SDCARD_defconfig
index 4ac6275..3cd8a7c 100644
--- a/configs/T4240RDB_SDCARD_defconfig
+++ b/configs/T4240RDB_SDCARD_defconfig
@@ -42,3 +42,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/T4240RDB_defconfig b/configs/T4240RDB_defconfig
index efd6f78..34e46d6 100644
--- a/configs/T4240RDB_defconfig
+++ b/configs/T4240RDB_defconfig
@@ -32,3 +32,4 @@  CONFIG_FSL_ESPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/apx4devkit_defconfig b/configs/apx4devkit_defconfig
index 47a4ee9..8918922 100644
--- a/configs/apx4devkit_defconfig
+++ b/configs/apx4devkit_defconfig
@@ -31,3 +31,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/aristainetos2_defconfig b/configs/aristainetos2_defconfig
index 288dab0..7bdff75 100644
--- a/configs/aristainetos2_defconfig
+++ b/configs/aristainetos2_defconfig
@@ -44,3 +44,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/aristainetos2b_defconfig b/configs/aristainetos2b_defconfig
index 115ae07..e040cf9 100644
--- a/configs/aristainetos2b_defconfig
+++ b/configs/aristainetos2b_defconfig
@@ -44,3 +44,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/aristainetos_defconfig b/configs/aristainetos_defconfig
index cad8b4a..b581982 100644
--- a/configs/aristainetos_defconfig
+++ b/configs/aristainetos_defconfig
@@ -42,3 +42,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9260ek_dataflash_cs0_defconfig b/configs/at91sam9260ek_dataflash_cs0_defconfig
index 9aa3ae9..76dcdf1 100644
--- a/configs/at91sam9260ek_dataflash_cs0_defconfig
+++ b/configs/at91sam9260ek_dataflash_cs0_defconfig
@@ -52,3 +52,4 @@  CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9260ek_dataflash_cs1_defconfig b/configs/at91sam9260ek_dataflash_cs1_defconfig
index 908f208..0d54c27 100644
--- a/configs/at91sam9260ek_dataflash_cs1_defconfig
+++ b/configs/at91sam9260ek_dataflash_cs1_defconfig
@@ -52,3 +52,4 @@  CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9260ek_nandflash_defconfig b/configs/at91sam9260ek_nandflash_defconfig
index de8a0b0..882bd5e 100644
--- a/configs/at91sam9260ek_nandflash_defconfig
+++ b/configs/at91sam9260ek_nandflash_defconfig
@@ -52,3 +52,4 @@  CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9261ek_dataflash_cs0_defconfig b/configs/at91sam9261ek_dataflash_cs0_defconfig
index bac48f9..70d1e3a 100644
--- a/configs/at91sam9261ek_dataflash_cs0_defconfig
+++ b/configs/at91sam9261ek_dataflash_cs0_defconfig
@@ -52,3 +52,4 @@  CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9261ek_dataflash_cs3_defconfig b/configs/at91sam9261ek_dataflash_cs3_defconfig
index 066de06..49271c6 100644
--- a/configs/at91sam9261ek_dataflash_cs3_defconfig
+++ b/configs/at91sam9261ek_dataflash_cs3_defconfig
@@ -52,3 +52,4 @@  CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9261ek_nandflash_defconfig b/configs/at91sam9261ek_nandflash_defconfig
index b32db05..82bbd54 100644
--- a/configs/at91sam9261ek_nandflash_defconfig
+++ b/configs/at91sam9261ek_nandflash_defconfig
@@ -52,3 +52,4 @@  CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9263ek_dataflash_cs0_defconfig b/configs/at91sam9263ek_dataflash_cs0_defconfig
index bc2f242..f5041f1 100644
--- a/configs/at91sam9263ek_dataflash_cs0_defconfig
+++ b/configs/at91sam9263ek_dataflash_cs0_defconfig
@@ -59,3 +59,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9263ek_dataflash_defconfig b/configs/at91sam9263ek_dataflash_defconfig
index bc2f242..f5041f1 100644
--- a/configs/at91sam9263ek_dataflash_defconfig
+++ b/configs/at91sam9263ek_dataflash_defconfig
@@ -59,3 +59,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9263ek_nandflash_defconfig b/configs/at91sam9263ek_nandflash_defconfig
index 2bc927d..b3b203c 100644
--- a/configs/at91sam9263ek_nandflash_defconfig
+++ b/configs/at91sam9263ek_nandflash_defconfig
@@ -59,3 +59,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9263ek_norflash_boot_defconfig b/configs/at91sam9263ek_norflash_boot_defconfig
index 03d6571..28741e6 100644
--- a/configs/at91sam9263ek_norflash_boot_defconfig
+++ b/configs/at91sam9263ek_norflash_boot_defconfig
@@ -58,3 +58,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9263ek_norflash_defconfig b/configs/at91sam9263ek_norflash_defconfig
index b14d516..3ba3222 100644
--- a/configs/at91sam9263ek_norflash_defconfig
+++ b/configs/at91sam9263ek_norflash_defconfig
@@ -58,3 +58,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9g10ek_dataflash_cs0_defconfig b/configs/at91sam9g10ek_dataflash_cs0_defconfig
index b81ce46..fd90f18 100644
--- a/configs/at91sam9g10ek_dataflash_cs0_defconfig
+++ b/configs/at91sam9g10ek_dataflash_cs0_defconfig
@@ -50,3 +50,4 @@  CONFIG_ATMEL_SPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9g10ek_dataflash_cs3_defconfig b/configs/at91sam9g10ek_dataflash_cs3_defconfig
index e599d3d..ffa69f8 100644
--- a/configs/at91sam9g10ek_dataflash_cs3_defconfig
+++ b/configs/at91sam9g10ek_dataflash_cs3_defconfig
@@ -50,3 +50,4 @@  CONFIG_ATMEL_SPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9g10ek_nandflash_defconfig b/configs/at91sam9g10ek_nandflash_defconfig
index 66deba4..43de3fd 100644
--- a/configs/at91sam9g10ek_nandflash_defconfig
+++ b/configs/at91sam9g10ek_nandflash_defconfig
@@ -50,3 +50,4 @@  CONFIG_ATMEL_SPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9g20ek_2mmc_defconfig b/configs/at91sam9g20ek_2mmc_defconfig
index 0b873c8..d969b95 100644
--- a/configs/at91sam9g20ek_2mmc_defconfig
+++ b/configs/at91sam9g20ek_2mmc_defconfig
@@ -55,3 +55,4 @@  CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9g20ek_2mmc_nandflash_defconfig b/configs/at91sam9g20ek_2mmc_nandflash_defconfig
index cb4a123..5d98c86 100644
--- a/configs/at91sam9g20ek_2mmc_nandflash_defconfig
+++ b/configs/at91sam9g20ek_2mmc_nandflash_defconfig
@@ -55,3 +55,4 @@  CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9g20ek_dataflash_cs0_defconfig b/configs/at91sam9g20ek_dataflash_cs0_defconfig
index 6af3e31..c34cb2e 100644
--- a/configs/at91sam9g20ek_dataflash_cs0_defconfig
+++ b/configs/at91sam9g20ek_dataflash_cs0_defconfig
@@ -52,3 +52,4 @@  CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9g20ek_dataflash_cs1_defconfig b/configs/at91sam9g20ek_dataflash_cs1_defconfig
index fddf1e2..1e4da95 100644
--- a/configs/at91sam9g20ek_dataflash_cs1_defconfig
+++ b/configs/at91sam9g20ek_dataflash_cs1_defconfig
@@ -52,3 +52,4 @@  CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9g20ek_nandflash_defconfig b/configs/at91sam9g20ek_nandflash_defconfig
index 3b5d84e..b938b74 100644
--- a/configs/at91sam9g20ek_nandflash_defconfig
+++ b/configs/at91sam9g20ek_nandflash_defconfig
@@ -52,3 +52,4 @@  CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9m10g45ek_mmc_defconfig b/configs/at91sam9m10g45ek_mmc_defconfig
index 3b74d0d..974827e 100644
--- a/configs/at91sam9m10g45ek_mmc_defconfig
+++ b/configs/at91sam9m10g45ek_mmc_defconfig
@@ -53,3 +53,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9m10g45ek_nandflash_defconfig b/configs/at91sam9m10g45ek_nandflash_defconfig
index 45ed49a..f1848be 100644
--- a/configs/at91sam9m10g45ek_nandflash_defconfig
+++ b/configs/at91sam9m10g45ek_nandflash_defconfig
@@ -53,3 +53,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9n12ek_mmc_defconfig b/configs/at91sam9n12ek_mmc_defconfig
index 1b6a876..c374595 100644
--- a/configs/at91sam9n12ek_mmc_defconfig
+++ b/configs/at91sam9n12ek_mmc_defconfig
@@ -55,3 +55,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9n12ek_nandflash_defconfig b/configs/at91sam9n12ek_nandflash_defconfig
index 0d56a9a..4b392fb 100644
--- a/configs/at91sam9n12ek_nandflash_defconfig
+++ b/configs/at91sam9n12ek_nandflash_defconfig
@@ -55,3 +55,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9n12ek_spiflash_defconfig b/configs/at91sam9n12ek_spiflash_defconfig
index dcada1d..68ee4f2 100644
--- a/configs/at91sam9n12ek_spiflash_defconfig
+++ b/configs/at91sam9n12ek_spiflash_defconfig
@@ -55,3 +55,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9rlek_dataflash_defconfig b/configs/at91sam9rlek_dataflash_defconfig
index d230670..d15d1df 100644
--- a/configs/at91sam9rlek_dataflash_defconfig
+++ b/configs/at91sam9rlek_dataflash_defconfig
@@ -53,3 +53,4 @@  CONFIG_ATMEL_SPI=y
 CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9rlek_mmc_defconfig b/configs/at91sam9rlek_mmc_defconfig
index 55c7d03..9382459 100644
--- a/configs/at91sam9rlek_mmc_defconfig
+++ b/configs/at91sam9rlek_mmc_defconfig
@@ -53,3 +53,4 @@  CONFIG_ATMEL_SPI=y
 CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9rlek_nandflash_defconfig b/configs/at91sam9rlek_nandflash_defconfig
index 135f320..c2abd30 100644
--- a/configs/at91sam9rlek_nandflash_defconfig
+++ b/configs/at91sam9rlek_nandflash_defconfig
@@ -53,3 +53,4 @@  CONFIG_ATMEL_SPI=y
 CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9x5ek_dataflash_defconfig b/configs/at91sam9x5ek_dataflash_defconfig
index 514fa9b..985df33 100644
--- a/configs/at91sam9x5ek_dataflash_defconfig
+++ b/configs/at91sam9x5ek_dataflash_defconfig
@@ -60,3 +60,4 @@  CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9x5ek_mmc_defconfig b/configs/at91sam9x5ek_mmc_defconfig
index 8c32beb..0388c73 100644
--- a/configs/at91sam9x5ek_mmc_defconfig
+++ b/configs/at91sam9x5ek_mmc_defconfig
@@ -60,3 +60,4 @@  CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9x5ek_nandflash_defconfig b/configs/at91sam9x5ek_nandflash_defconfig
index fd7e7c1..5a265b8 100644
--- a/configs/at91sam9x5ek_nandflash_defconfig
+++ b/configs/at91sam9x5ek_nandflash_defconfig
@@ -60,3 +60,4 @@  CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9x5ek_spiflash_defconfig b/configs/at91sam9x5ek_spiflash_defconfig
index 457e15d..7535889 100644
--- a/configs/at91sam9x5ek_spiflash_defconfig
+++ b/configs/at91sam9x5ek_spiflash_defconfig
@@ -60,3 +60,4 @@  CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9xeek_dataflash_cs0_defconfig b/configs/at91sam9xeek_dataflash_cs0_defconfig
index 2ebb4d4..4c90d3c 100644
--- a/configs/at91sam9xeek_dataflash_cs0_defconfig
+++ b/configs/at91sam9xeek_dataflash_cs0_defconfig
@@ -52,3 +52,4 @@  CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9xeek_dataflash_cs1_defconfig b/configs/at91sam9xeek_dataflash_cs1_defconfig
index 667d5cc..304e65e 100644
--- a/configs/at91sam9xeek_dataflash_cs1_defconfig
+++ b/configs/at91sam9xeek_dataflash_cs1_defconfig
@@ -52,3 +52,4 @@  CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/at91sam9xeek_nandflash_defconfig b/configs/at91sam9xeek_nandflash_defconfig
index 8239827..004966e 100644
--- a/configs/at91sam9xeek_nandflash_defconfig
+++ b/configs/at91sam9xeek_nandflash_defconfig
@@ -52,3 +52,4 @@  CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/axm_defconfig b/configs/axm_defconfig
index b013ba2..1c9ec02 100644
--- a/configs/axm_defconfig
+++ b/configs/axm_defconfig
@@ -40,3 +40,4 @@  CONFIG_SPI_FLASH=y
 CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_PHYLIB=y
 CONFIG_USE_TINY_PRINTF=y
+CONFIG_NAND=y
diff --git a/configs/bg0900_defconfig b/configs/bg0900_defconfig
index 72616ae..f3cc745 100644
--- a/configs/bg0900_defconfig
+++ b/configs/bg0900_defconfig
@@ -30,3 +30,4 @@  CONFIG_SPI_FLASH=y
 CONFIG_SPI_FLASH_BAR=y
 CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/cm_fx6_defconfig b/configs/cm_fx6_defconfig
index 6b1c0a8..12f653f 100644
--- a/configs/cm_fx6_defconfig
+++ b/configs/cm_fx6_defconfig
@@ -76,3 +76,4 @@  CONFIG_USB_KEYBOARD=y
 CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y
 CONFIG_VIDEO=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/colibri_imx7_defconfig b/configs/colibri_imx7_defconfig
index efc4ccb..d06cee8 100644
--- a/configs/colibri_imx7_defconfig
+++ b/configs/colibri_imx7_defconfig
@@ -64,3 +64,4 @@  CONFIG_USB_GADGET_DOWNLOAD=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/colibri_t20_defconfig b/configs/colibri_t20_defconfig
index 81a6a4b..0f7d16e 100644
--- a/configs/colibri_t20_defconfig
+++ b/configs/colibri_t20_defconfig
@@ -59,3 +59,4 @@  CONFIG_DM_VIDEO=y
 CONFIG_VIDEO_TEGRA20=y
 CONFIG_CONSOLE_SCROLL_LINES=10
 CONFIG_OF_LIBFDT_OVERLAY=y
+CONFIG_NAND=y
diff --git a/configs/corvus_defconfig b/configs/corvus_defconfig
index 1034f50..14accaa 100644
--- a/configs/corvus_defconfig
+++ b/configs/corvus_defconfig
@@ -53,3 +53,4 @@  CONFIG_USB_GADGET_PRODUCT_NUM=0x02d2
 CONFIG_USB_GADGET_ATMEL_USBA=y
 CONFIG_USB_GADGET_DOWNLOAD=y
 # CONFIG_EFI_LOADER is not set
+CONFIG_NAND=y
diff --git a/configs/dns325_defconfig b/configs/dns325_defconfig
index f5556e3..5d2e494 100644
--- a/configs/dns325_defconfig
+++ b/configs/dns325_defconfig
@@ -30,3 +30,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/dockstar_defconfig b/configs/dockstar_defconfig
index 9658e5c..3066752 100644
--- a/configs/dockstar_defconfig
+++ b/configs/dockstar_defconfig
@@ -25,3 +25,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/ea20_defconfig b/configs/ea20_defconfig
index abbb00a..9e7196a 100644
--- a/configs/ea20_defconfig
+++ b/configs/ea20_defconfig
@@ -35,3 +35,4 @@  CONFIG_SYS_NS16550=y
 CONFIG_DAVINCI_SPI=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
+CONFIG_NAND=y
diff --git a/configs/etamin_defconfig b/configs/etamin_defconfig
index 608faf6..01fd684 100644
--- a/configs/etamin_defconfig
+++ b/configs/etamin_defconfig
@@ -54,6 +54,7 @@  CONFIG_ENV_IS_IN_NAND=y
 CONFIG_DFU_NAND=y
 CONFIG_MMC_OMAP_HS=y
 CONFIG_NAND=y
+CONFIG_SYS_MAX_NAND_DEVICE=3
 CONFIG_SPI_FLASH=y
 CONFIG_SPI_FLASH_WINBOND=y
 CONFIG_MTD_UBI_FASTMAP=y
diff --git a/configs/ethernut5_defconfig b/configs/ethernut5_defconfig
index f816a16..251c0a3 100644
--- a/configs/ethernut5_defconfig
+++ b/configs/ethernut5_defconfig
@@ -60,3 +60,4 @@  CONFIG_DM_SPI=y
 CONFIG_ATMEL_SPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/goflexhome_defconfig b/configs/goflexhome_defconfig
index bdfd62a..20b13ed 100644
--- a/configs/goflexhome_defconfig
+++ b/configs/goflexhome_defconfig
@@ -31,3 +31,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/gurnard_defconfig b/configs/gurnard_defconfig
index c5afd4b..9c1eafb 100644
--- a/configs/gurnard_defconfig
+++ b/configs/gurnard_defconfig
@@ -31,3 +31,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_DM_VIDEO=y
 CONFIG_CMD_DHRYSTONE=y
 # CONFIG_EFI_LOADER is not set
+CONFIG_NAND=y
diff --git a/configs/guruplug_defconfig b/configs/guruplug_defconfig
index 66a668a..a73aa70 100644
--- a/configs/guruplug_defconfig
+++ b/configs/guruplug_defconfig
@@ -32,3 +32,4 @@  CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_LZMA=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/gwventana_nand_defconfig b/configs/gwventana_nand_defconfig
index be6cf0c..da32c14 100644
--- a/configs/gwventana_nand_defconfig
+++ b/configs/gwventana_nand_defconfig
@@ -81,3 +81,4 @@  CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
 CONFIG_OF_LIBFDT=y
 CONFIG_FDT_FIXUP_PARTITIONS=y
+CONFIG_NAND=y
diff --git a/configs/harmony_defconfig b/configs/harmony_defconfig
index 1a4df1e..4751d9e 100644
--- a/configs/harmony_defconfig
+++ b/configs/harmony_defconfig
@@ -44,3 +44,4 @@  CONFIG_USB_ETHER_SMSC95XX=y
 CONFIG_DM_VIDEO=y
 CONFIG_VIDEO_TEGRA20=y
 CONFIG_CONSOLE_SCROLL_LINES=10
+CONFIG_NAND=y
diff --git a/configs/ib62x0_defconfig b/configs/ib62x0_defconfig
index f6bfa06..4bb43ff 100644
--- a/configs/ib62x0_defconfig
+++ b/configs/ib62x0_defconfig
@@ -30,3 +30,4 @@  CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_LZMA=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/iconnect_defconfig b/configs/iconnect_defconfig
index fe7fcb1..5485735 100644
--- a/configs/iconnect_defconfig
+++ b/configs/iconnect_defconfig
@@ -25,3 +25,4 @@  CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_LZMA=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/ids8313_defconfig b/configs/ids8313_defconfig
index 839dfba..a23ad27 100644
--- a/configs/ids8313_defconfig
+++ b/configs/ids8313_defconfig
@@ -35,3 +35,4 @@  CONFIG_PHYLIB=y
 # CONFIG_PCI is not set
 CONFIG_SYS_NS16550=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/ipam390_defconfig b/configs/ipam390_defconfig
index 8fdf7605..fea28aa 100644
--- a/configs/ipam390_defconfig
+++ b/configs/ipam390_defconfig
@@ -34,3 +34,4 @@  CONFIG_CMD_UBI=y
 CONFIG_ENV_IS_IN_NAND=y
 # CONFIG_MMC is not set
 CONFIG_SYS_NS16550=y
+CONFIG_NAND=y
diff --git a/configs/k2e_evm_defconfig b/configs/k2e_evm_defconfig
index e6dc298..488263c 100644
--- a/configs/k2e_evm_defconfig
+++ b/configs/k2e_evm_defconfig
@@ -49,3 +49,4 @@  CONFIG_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/k2e_hs_evm_defconfig b/configs/k2e_hs_evm_defconfig
index 6c5e167..f0b7c70 100644
--- a/configs/k2e_hs_evm_defconfig
+++ b/configs/k2e_hs_evm_defconfig
@@ -38,3 +38,4 @@  CONFIG_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/k2g_evm_defconfig b/configs/k2g_evm_defconfig
index 6a1f8dc..105ffb9 100644
--- a/configs/k2g_evm_defconfig
+++ b/configs/k2g_evm_defconfig
@@ -52,3 +52,4 @@  CONFIG_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/k2g_hs_evm_defconfig b/configs/k2g_hs_evm_defconfig
index b4985b5..4497c4b 100644
--- a/configs/k2g_hs_evm_defconfig
+++ b/configs/k2g_hs_evm_defconfig
@@ -40,3 +40,4 @@  CONFIG_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/k2hk_evm_defconfig b/configs/k2hk_evm_defconfig
index 1e3905f..2b48e83 100644
--- a/configs/k2hk_evm_defconfig
+++ b/configs/k2hk_evm_defconfig
@@ -49,3 +49,4 @@  CONFIG_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/k2hk_hs_evm_defconfig b/configs/k2hk_hs_evm_defconfig
index b4b08dd..fe2b67e 100644
--- a/configs/k2hk_hs_evm_defconfig
+++ b/configs/k2hk_hs_evm_defconfig
@@ -38,3 +38,4 @@  CONFIG_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/k2l_evm_defconfig b/configs/k2l_evm_defconfig
index 074bed0..2112173 100644
--- a/configs/k2l_evm_defconfig
+++ b/configs/k2l_evm_defconfig
@@ -49,3 +49,4 @@  CONFIG_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/km_kirkwood_128m16_defconfig b/configs/km_kirkwood_128m16_defconfig
index aeb55c1..2b42f02 100644
--- a/configs/km_kirkwood_128m16_defconfig
+++ b/configs/km_kirkwood_128m16_defconfig
@@ -31,3 +31,4 @@  CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/km_kirkwood_defconfig b/configs/km_kirkwood_defconfig
index 9eed131..f008713 100644
--- a/configs/km_kirkwood_defconfig
+++ b/configs/km_kirkwood_defconfig
@@ -31,3 +31,4 @@  CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/km_kirkwood_pci_defconfig b/configs/km_kirkwood_pci_defconfig
index b24c685..2632fab 100644
--- a/configs/km_kirkwood_pci_defconfig
+++ b/configs/km_kirkwood_pci_defconfig
@@ -31,3 +31,4 @@  CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/kmcoge4_defconfig b/configs/kmcoge4_defconfig
index 5c31abe..3716ca0 100644
--- a/configs/kmcoge4_defconfig
+++ b/configs/kmcoge4_defconfig
@@ -42,3 +42,4 @@  CONFIG_SYS_NS16550=y
 CONFIG_FSL_ESPI=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/kmcoge5ne_defconfig b/configs/kmcoge5ne_defconfig
index d4c8e87..53057e7 100644
--- a/configs/kmcoge5ne_defconfig
+++ b/configs/kmcoge5ne_defconfig
@@ -29,3 +29,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/kmcoge5un_defconfig b/configs/kmcoge5un_defconfig
index 6eb4781..db5a231 100644
--- a/configs/kmcoge5un_defconfig
+++ b/configs/kmcoge5un_defconfig
@@ -31,3 +31,4 @@  CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/kmlion1_defconfig b/configs/kmlion1_defconfig
index c7edcaa..ef9d675 100644
--- a/configs/kmlion1_defconfig
+++ b/configs/kmlion1_defconfig
@@ -42,3 +42,4 @@  CONFIG_SYS_NS16550=y
 CONFIG_FSL_ESPI=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/kmnusa_defconfig b/configs/kmnusa_defconfig
index 22b8b4d..2ca0812 100644
--- a/configs/kmnusa_defconfig
+++ b/configs/kmnusa_defconfig
@@ -31,3 +31,4 @@  CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/kmsugp1_defconfig b/configs/kmsugp1_defconfig
index a105b8a..49649da 100644
--- a/configs/kmsugp1_defconfig
+++ b/configs/kmsugp1_defconfig
@@ -31,3 +31,4 @@  CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/kmsuv31_defconfig b/configs/kmsuv31_defconfig
index 59d1066..c0783ea 100644
--- a/configs/kmsuv31_defconfig
+++ b/configs/kmsuv31_defconfig
@@ -31,3 +31,4 @@  CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/kmtegr1_defconfig b/configs/kmtegr1_defconfig
index d90852b..4cb5fff 100644
--- a/configs/kmtegr1_defconfig
+++ b/configs/kmtegr1_defconfig
@@ -30,3 +30,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/ls1021aqds_ddr4_nor_defconfig b/configs/ls1021aqds_ddr4_nor_defconfig
index ddc99ce..56d4798 100644
--- a/configs/ls1021aqds_ddr4_nor_defconfig
+++ b/configs/ls1021aqds_ddr4_nor_defconfig
@@ -50,3 +50,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO_FSL_DCU_FB=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
+CONFIG_NAND=y
diff --git a/configs/ls1021aqds_ddr4_nor_lpuart_defconfig b/configs/ls1021aqds_ddr4_nor_lpuart_defconfig
index 474cd2a..85157ad 100644
--- a/configs/ls1021aqds_ddr4_nor_lpuart_defconfig
+++ b/configs/ls1021aqds_ddr4_nor_lpuart_defconfig
@@ -51,3 +51,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO_FSL_DCU_FB=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
+CONFIG_NAND=y
diff --git a/configs/ls1021aqds_nand_defconfig b/configs/ls1021aqds_nand_defconfig
index 994b38e..3f50e96 100644
--- a/configs/ls1021aqds_nand_defconfig
+++ b/configs/ls1021aqds_nand_defconfig
@@ -65,3 +65,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO_FSL_DCU_FB=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
+CONFIG_NAND=y
diff --git a/configs/ls1021aqds_nor_SECURE_BOOT_defconfig b/configs/ls1021aqds_nor_SECURE_BOOT_defconfig
index e63f0bf..8bc1043 100644
--- a/configs/ls1021aqds_nor_SECURE_BOOT_defconfig
+++ b/configs/ls1021aqds_nor_SECURE_BOOT_defconfig
@@ -52,3 +52,4 @@  CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
 CONFIG_RSA=y
 CONFIG_SPL_RSA=y
+CONFIG_NAND=y
diff --git a/configs/ls1021aqds_nor_defconfig b/configs/ls1021aqds_nor_defconfig
index 6068f92..7a9b495 100644
--- a/configs/ls1021aqds_nor_defconfig
+++ b/configs/ls1021aqds_nor_defconfig
@@ -51,3 +51,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO_FSL_DCU_FB=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
+CONFIG_NAND=y
diff --git a/configs/ls1021aqds_nor_lpuart_defconfig b/configs/ls1021aqds_nor_lpuart_defconfig
index 3da4026..09c0d68 100644
--- a/configs/ls1021aqds_nor_lpuart_defconfig
+++ b/configs/ls1021aqds_nor_lpuart_defconfig
@@ -52,3 +52,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO_FSL_DCU_FB=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
+CONFIG_NAND=y
diff --git a/configs/ls1021aqds_sdcard_ifc_defconfig b/configs/ls1021aqds_sdcard_ifc_defconfig
index 1651a0f..1a3cb77 100644
--- a/configs/ls1021aqds_sdcard_ifc_defconfig
+++ b/configs/ls1021aqds_sdcard_ifc_defconfig
@@ -63,3 +63,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO_FSL_DCU_FB=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
+CONFIG_NAND=y
diff --git a/configs/ls1043aqds_defconfig b/configs/ls1043aqds_defconfig
index cb4b355..9cccfc4 100644
--- a/configs/ls1043aqds_defconfig
+++ b/configs/ls1043aqds_defconfig
@@ -47,3 +47,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1043aqds_lpuart_defconfig b/configs/ls1043aqds_lpuart_defconfig
index 7e608d7..6b70b45 100644
--- a/configs/ls1043aqds_lpuart_defconfig
+++ b/configs/ls1043aqds_lpuart_defconfig
@@ -49,3 +49,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1043aqds_nand_defconfig b/configs/ls1043aqds_nand_defconfig
index cf43781..25486ee 100644
--- a/configs/ls1043aqds_nand_defconfig
+++ b/configs/ls1043aqds_nand_defconfig
@@ -62,3 +62,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1043aqds_nor_ddr3_defconfig b/configs/ls1043aqds_nor_ddr3_defconfig
index 9093984..e20d705 100644
--- a/configs/ls1043aqds_nor_ddr3_defconfig
+++ b/configs/ls1043aqds_nor_ddr3_defconfig
@@ -48,3 +48,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1043aqds_sdcard_ifc_defconfig b/configs/ls1043aqds_sdcard_ifc_defconfig
index 5ff15ba..341b72d 100644
--- a/configs/ls1043aqds_sdcard_ifc_defconfig
+++ b/configs/ls1043aqds_sdcard_ifc_defconfig
@@ -62,3 +62,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1043ardb_SECURE_BOOT_defconfig b/configs/ls1043ardb_SECURE_BOOT_defconfig
index e5e3e35..b832384 100644
--- a/configs/ls1043ardb_SECURE_BOOT_defconfig
+++ b/configs/ls1043ardb_SECURE_BOOT_defconfig
@@ -40,3 +40,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_RSA=y
 CONFIG_SPL_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
+CONFIG_NAND=y
diff --git a/configs/ls1043ardb_defconfig b/configs/ls1043ardb_defconfig
index 9452416..498f88b 100644
--- a/configs/ls1043ardb_defconfig
+++ b/configs/ls1043ardb_defconfig
@@ -38,3 +38,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1043ardb_nand_SECURE_BOOT_defconfig b/configs/ls1043ardb_nand_SECURE_BOOT_defconfig
index 6f20f26..7762ac1 100644
--- a/configs/ls1043ardb_nand_SECURE_BOOT_defconfig
+++ b/configs/ls1043ardb_nand_SECURE_BOOT_defconfig
@@ -62,3 +62,4 @@  CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_RSA=y
 CONFIG_SPL_RSA=y
+CONFIG_NAND=y
diff --git a/configs/ls1043ardb_nand_defconfig b/configs/ls1043ardb_nand_defconfig
index 4949cd2..5904ca5 100644
--- a/configs/ls1043ardb_nand_defconfig
+++ b/configs/ls1043ardb_nand_defconfig
@@ -60,3 +60,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1043ardb_sdcard_SECURE_BOOT_defconfig b/configs/ls1043ardb_sdcard_SECURE_BOOT_defconfig
index d565712..6f12cda 100644
--- a/configs/ls1043ardb_sdcard_SECURE_BOOT_defconfig
+++ b/configs/ls1043ardb_sdcard_SECURE_BOOT_defconfig
@@ -56,3 +56,4 @@  CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_RSA=y
 CONFIG_SPL_RSA=y
+CONFIG_NAND=y
diff --git a/configs/ls1043ardb_sdcard_defconfig b/configs/ls1043ardb_sdcard_defconfig
index 16d544d..5314590 100644
--- a/configs/ls1043ardb_sdcard_defconfig
+++ b/configs/ls1043ardb_sdcard_defconfig
@@ -54,3 +54,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1046aqds_SECURE_BOOT_defconfig b/configs/ls1046aqds_SECURE_BOOT_defconfig
index 6d83123..0f2020c 100644
--- a/configs/ls1046aqds_SECURE_BOOT_defconfig
+++ b/configs/ls1046aqds_SECURE_BOOT_defconfig
@@ -48,3 +48,4 @@  CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_RSA=y
+CONFIG_NAND=y
diff --git a/configs/ls1046aqds_defconfig b/configs/ls1046aqds_defconfig
index d901eb0..44c8383 100644
--- a/configs/ls1046aqds_defconfig
+++ b/configs/ls1046aqds_defconfig
@@ -48,3 +48,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1046aqds_lpuart_defconfig b/configs/ls1046aqds_lpuart_defconfig
index a9a073f..f04d54f 100644
--- a/configs/ls1046aqds_lpuart_defconfig
+++ b/configs/ls1046aqds_lpuart_defconfig
@@ -43,3 +43,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1046aqds_nand_defconfig b/configs/ls1046aqds_nand_defconfig
index 891d238..c252519 100644
--- a/configs/ls1046aqds_nand_defconfig
+++ b/configs/ls1046aqds_nand_defconfig
@@ -54,3 +54,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1046aqds_sdcard_ifc_defconfig b/configs/ls1046aqds_sdcard_ifc_defconfig
index e74e9b3..d7b1000 100644
--- a/configs/ls1046aqds_sdcard_ifc_defconfig
+++ b/configs/ls1046aqds_sdcard_ifc_defconfig
@@ -55,3 +55,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1046ardb_emmc_defconfig b/configs/ls1046ardb_emmc_defconfig
index d1742e4..2529081 100644
--- a/configs/ls1046ardb_emmc_defconfig
+++ b/configs/ls1046ardb_emmc_defconfig
@@ -50,3 +50,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1046ardb_qspi_SECURE_BOOT_defconfig b/configs/ls1046ardb_qspi_SECURE_BOOT_defconfig
index c7ae1dc..6bc9c9e 100644
--- a/configs/ls1046ardb_qspi_SECURE_BOOT_defconfig
+++ b/configs/ls1046ardb_qspi_SECURE_BOOT_defconfig
@@ -40,3 +40,4 @@  CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_RSA=y
+CONFIG_NAND=y
diff --git a/configs/ls1046ardb_qspi_defconfig b/configs/ls1046ardb_qspi_defconfig
index 23ac374..9802e3e 100644
--- a/configs/ls1046ardb_qspi_defconfig
+++ b/configs/ls1046ardb_qspi_defconfig
@@ -40,3 +40,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1046ardb_sdcard_SECURE_BOOT_defconfig b/configs/ls1046ardb_sdcard_SECURE_BOOT_defconfig
index 76e4517..21557e0 100644
--- a/configs/ls1046ardb_sdcard_SECURE_BOOT_defconfig
+++ b/configs/ls1046ardb_sdcard_SECURE_BOOT_defconfig
@@ -48,3 +48,4 @@  CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_RSA=y
 CONFIG_SPL_RSA=y
+CONFIG_NAND=y
diff --git a/configs/ls1046ardb_sdcard_defconfig b/configs/ls1046ardb_sdcard_defconfig
index 3a9e102..1b39908 100644
--- a/configs/ls1046ardb_sdcard_defconfig
+++ b/configs/ls1046ardb_sdcard_defconfig
@@ -45,3 +45,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/ls1088aqds_qspi_SECURE_BOOT_defconfig b/configs/ls1088aqds_qspi_SECURE_BOOT_defconfig
index e464951..582dec6f 100644
--- a/configs/ls1088aqds_qspi_SECURE_BOOT_defconfig
+++ b/configs/ls1088aqds_qspi_SECURE_BOOT_defconfig
@@ -43,3 +43,4 @@  CONFIG_USB_GADGET=y
 CONFIG_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/ls1088aqds_qspi_defconfig b/configs/ls1088aqds_qspi_defconfig
index 1e368d7..b696ddd 100644
--- a/configs/ls1088aqds_qspi_defconfig
+++ b/configs/ls1088aqds_qspi_defconfig
@@ -41,3 +41,4 @@  CONFIG_USB_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_USB_GADGET=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/ls1088aqds_sdcard_qspi_defconfig b/configs/ls1088aqds_sdcard_qspi_defconfig
index 659bc4f..00cc324 100644
--- a/configs/ls1088aqds_sdcard_qspi_defconfig
+++ b/configs/ls1088aqds_sdcard_qspi_defconfig
@@ -50,3 +50,4 @@  CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_USB_GADGET=y
+CONFIG_NAND=y
diff --git a/configs/ls1088ardb_qspi_SECURE_BOOT_defconfig b/configs/ls1088ardb_qspi_SECURE_BOOT_defconfig
index 19c76b6..de04d643 100644
--- a/configs/ls1088ardb_qspi_SECURE_BOOT_defconfig
+++ b/configs/ls1088ardb_qspi_SECURE_BOOT_defconfig
@@ -42,3 +42,4 @@  CONFIG_USB_GADGET=y
 CONFIG_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/ls1088ardb_qspi_defconfig b/configs/ls1088ardb_qspi_defconfig
index 8a08846..389d773 100644
--- a/configs/ls1088ardb_qspi_defconfig
+++ b/configs/ls1088ardb_qspi_defconfig
@@ -40,3 +40,4 @@  CONFIG_USB_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_USB_GADGET=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/ls1088ardb_sdcard_qspi_SECURE_BOOT_defconfig b/configs/ls1088ardb_sdcard_qspi_SECURE_BOOT_defconfig
index a7466f1..15ee4a7 100644
--- a/configs/ls1088ardb_sdcard_qspi_SECURE_BOOT_defconfig
+++ b/configs/ls1088ardb_sdcard_qspi_SECURE_BOOT_defconfig
@@ -42,3 +42,4 @@  CONFIG_DM_SPI=y
 CONFIG_FSL_DSPI=y
 CONFIG_RSA=y
 CONFIG_SPL_RSA=y
+CONFIG_NAND=y
diff --git a/configs/ls1088ardb_sdcard_qspi_defconfig b/configs/ls1088ardb_sdcard_qspi_defconfig
index 2e3c287..a860fed 100644
--- a/configs/ls1088ardb_sdcard_qspi_defconfig
+++ b/configs/ls1088ardb_sdcard_qspi_defconfig
@@ -49,3 +49,4 @@  CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_USB_GADGET=y
+CONFIG_NAND=y
diff --git a/configs/ls2080a_simu_defconfig b/configs/ls2080a_simu_defconfig
index cdc80c2..53763f0 100644
--- a/configs/ls2080a_simu_defconfig
+++ b/configs/ls2080a_simu_defconfig
@@ -34,3 +34,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_SYS_NS16550=y
 CONFIG_OF_LIBFDT=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/ls2080aqds_SECURE_BOOT_defconfig b/configs/ls2080aqds_SECURE_BOOT_defconfig
index 8d35e0b..5ee2b32 100644
--- a/configs/ls2080aqds_SECURE_BOOT_defconfig
+++ b/configs/ls2080aqds_SECURE_BOOT_defconfig
@@ -49,3 +49,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/ls2080aqds_defconfig b/configs/ls2080aqds_defconfig
index f8afa36..baf7009 100644
--- a/configs/ls2080aqds_defconfig
+++ b/configs/ls2080aqds_defconfig
@@ -48,3 +48,4 @@  CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/ls2080aqds_qspi_defconfig b/configs/ls2080aqds_qspi_defconfig
index 3fb47c5..6110595 100644
--- a/configs/ls2080aqds_qspi_defconfig
+++ b/configs/ls2080aqds_qspi_defconfig
@@ -48,3 +48,4 @@  CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/ls2080aqds_sdcard_defconfig b/configs/ls2080aqds_sdcard_defconfig
index 2ae7014..4f1e680 100644
--- a/configs/ls2080aqds_sdcard_defconfig
+++ b/configs/ls2080aqds_sdcard_defconfig
@@ -55,3 +55,4 @@  CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/ls2080ardb_SECURE_BOOT_defconfig b/configs/ls2080ardb_SECURE_BOOT_defconfig
index 84769be..a8d2b87 100644
--- a/configs/ls2080ardb_SECURE_BOOT_defconfig
+++ b/configs/ls2080ardb_SECURE_BOOT_defconfig
@@ -48,3 +48,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_RSA=y
 CONFIG_RSA_SOFTWARE_EXP=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/ls2080ardb_defconfig b/configs/ls2080ardb_defconfig
index 36d2313..9ebd2c8 100644
--- a/configs/ls2080ardb_defconfig
+++ b/configs/ls2080ardb_defconfig
@@ -47,3 +47,4 @@  CONFIG_USB_XHCI_HCD=y
 CONFIG_USB_XHCI_DWC3=y
 CONFIG_USB_STORAGE=y
 CONFIG_EFI_LOADER_BOUNCE_BUFFER=y
+CONFIG_NAND=y
diff --git a/configs/m28evk_defconfig b/configs/m28evk_defconfig
index 3bc6b18..1a1a3cf 100644
--- a/configs/m28evk_defconfig
+++ b/configs/m28evk_defconfig
@@ -49,3 +49,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_FAT_WRITE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/medcom-wide_defconfig b/configs/medcom-wide_defconfig
index e4fe851..65bfa18 100644
--- a/configs/medcom-wide_defconfig
+++ b/configs/medcom-wide_defconfig
@@ -37,3 +37,4 @@  CONFIG_USB_HOST_ETHER=y
 CONFIG_USB_ETHER_SMSC95XX=y
 CONFIG_DM_VIDEO=y
 CONFIG_VIDEO_TEGRA20=y
+CONFIG_NAND=y
diff --git a/configs/meesc_defconfig b/configs/meesc_defconfig
index 306b225..c7661b3 100644
--- a/configs/meesc_defconfig
+++ b/configs/meesc_defconfig
@@ -35,3 +35,4 @@  CONFIG_DM_SERIAL=y
 CONFIG_ATMEL_USART=y
 CONFIG_DM_SPI=y
 CONFIG_ATMEL_SPI=y
+CONFIG_NAND=y
diff --git a/configs/mgcoge3un_defconfig b/configs/mgcoge3un_defconfig
index 27f3995..19e8e0d 100644
--- a/configs/mgcoge3un_defconfig
+++ b/configs/mgcoge3un_defconfig
@@ -31,3 +31,4 @@  CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/mvebu_db_armada8k_defconfig b/configs/mvebu_db_armada8k_defconfig
index ab949c1..20c558c 100644
--- a/configs/mvebu_db_armada8k_defconfig
+++ b/configs/mvebu_db_armada8k_defconfig
@@ -67,3 +67,4 @@  CONFIG_USB_ETHER_MCS7830=y
 CONFIG_USB_ETHER_RTL8152=y
 CONFIG_USB_ETHER_SMSC95XX=y
 CONFIG_SMBIOS_MANUFACTURER=""
+CONFIG_NAND=y
diff --git a/configs/mvebu_mcbin-88f8040_defconfig b/configs/mvebu_mcbin-88f8040_defconfig
index 29f134d..a488e91 100644
--- a/configs/mvebu_mcbin-88f8040_defconfig
+++ b/configs/mvebu_mcbin-88f8040_defconfig
@@ -71,3 +71,4 @@  CONFIG_USB_ETHER_MCS7830=y
 CONFIG_USB_ETHER_RTL8152=y
 CONFIG_USB_ETHER_SMSC95XX=y
 CONFIG_SMBIOS_MANUFACTURER=""
+CONFIG_NAND=y
diff --git a/configs/mx28evk_auart_console_defconfig b/configs/mx28evk_auart_console_defconfig
index c497756..dfb76f2 100644
--- a/configs/mx28evk_auart_console_defconfig
+++ b/configs/mx28evk_auart_console_defconfig
@@ -46,3 +46,4 @@  CONFIG_USB_ETHER_ASIX=y
 CONFIG_USB_ETHER_SMSC95XX=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/mx28evk_defconfig b/configs/mx28evk_defconfig
index 40c9df2..0a4c12e 100644
--- a/configs/mx28evk_defconfig
+++ b/configs/mx28evk_defconfig
@@ -46,3 +46,4 @@  CONFIG_USB_ETHER_ASIX=y
 CONFIG_USB_ETHER_SMSC95XX=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/mx28evk_nand_defconfig b/configs/mx28evk_nand_defconfig
index ea97f40..35451c4 100644
--- a/configs/mx28evk_nand_defconfig
+++ b/configs/mx28evk_nand_defconfig
@@ -45,3 +45,4 @@  CONFIG_USB_ETHER_ASIX=y
 CONFIG_USB_ETHER_SMSC95XX=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/mx28evk_spi_defconfig b/configs/mx28evk_spi_defconfig
index 34e9927..7067dc2 100644
--- a/configs/mx28evk_spi_defconfig
+++ b/configs/mx28evk_spi_defconfig
@@ -45,3 +45,4 @@  CONFIG_USB_ETHER_ASIX=y
 CONFIG_USB_ETHER_SMSC95XX=y
 CONFIG_VIDEO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/mx6sabreauto_defconfig b/configs/mx6sabreauto_defconfig
index 215700b..36eb7ee 100644
--- a/configs/mx6sabreauto_defconfig
+++ b/configs/mx6sabreauto_defconfig
@@ -56,3 +56,4 @@  CONFIG_USB_ETHER_ASIX=y
 CONFIG_VIDEO=y
 # CONFIG_VIDEO_SW_CURSOR is not set
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/mx6sxsabreauto_defconfig b/configs/mx6sxsabreauto_defconfig
index a2c4830..c694b71 100644
--- a/configs/mx6sxsabreauto_defconfig
+++ b/configs/mx6sxsabreauto_defconfig
@@ -49,3 +49,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_USB_HOST_ETHER=y
 CONFIG_USB_ETHER_ASIX=y
+CONFIG_NAND=y
diff --git a/configs/nas220_defconfig b/configs/nas220_defconfig
index 8a71ed8..f1942b7 100644
--- a/configs/nas220_defconfig
+++ b/configs/nas220_defconfig
@@ -31,3 +31,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/nsa310s_defconfig b/configs/nsa310s_defconfig
index 5e111cb..855c23e 100644
--- a/configs/nsa310s_defconfig
+++ b/configs/nsa310s_defconfig
@@ -29,3 +29,4 @@  CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_LZMA=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/openrd_base_defconfig b/configs/openrd_base_defconfig
index f91e0f9..9332b1f 100644
--- a/configs/openrd_base_defconfig
+++ b/configs/openrd_base_defconfig
@@ -31,3 +31,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/openrd_client_defconfig b/configs/openrd_client_defconfig
index e65c437..aaf3086 100644
--- a/configs/openrd_client_defconfig
+++ b/configs/openrd_client_defconfig
@@ -31,3 +31,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/openrd_ultimate_defconfig b/configs/openrd_ultimate_defconfig
index dfd809d..eda6a5e 100644
--- a/configs/openrd_ultimate_defconfig
+++ b/configs/openrd_ultimate_defconfig
@@ -31,3 +31,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/pcm058_defconfig b/configs/pcm058_defconfig
index 99713c2..b081bea 100644
--- a/configs/pcm058_defconfig
+++ b/configs/pcm058_defconfig
@@ -56,3 +56,4 @@  CONFIG_PHY_MICREL_KSZ90X1=y
 CONFIG_NETDEVICES=y
 CONFIG_DM_THERMAL=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/pfla02_defconfig b/configs/pfla02_defconfig
index 029c9de..e6248fd 100644
--- a/configs/pfla02_defconfig
+++ b/configs/pfla02_defconfig
@@ -54,3 +54,4 @@  CONFIG_NETDEVICES=y
 CONFIG_FEC_MXC=y
 CONFIG_DM_THERMAL=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/platinum_picon_defconfig b/configs/platinum_picon_defconfig
index 54d88b2..fa7a067 100644
--- a/configs/platinum_picon_defconfig
+++ b/configs/platinum_picon_defconfig
@@ -45,3 +45,4 @@  CONFIG_PHYLIB=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/platinum_titanium_defconfig b/configs/platinum_titanium_defconfig
index c5f6b7a..e393c47 100644
--- a/configs/platinum_titanium_defconfig
+++ b/configs/platinum_titanium_defconfig
@@ -48,3 +48,4 @@  CONFIG_NETDEVICES=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/plutux_defconfig b/configs/plutux_defconfig
index a832e52..21cbceb 100644
--- a/configs/plutux_defconfig
+++ b/configs/plutux_defconfig
@@ -30,3 +30,4 @@  CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_USB_HOST_ETHER=y
 CONFIG_USB_ETHER_SMSC95XX=y
+CONFIG_NAND=y
diff --git a/configs/pm9261_defconfig b/configs/pm9261_defconfig
index 692af14..778708d 100644
--- a/configs/pm9261_defconfig
+++ b/configs/pm9261_defconfig
@@ -47,3 +47,4 @@  CONFIG_ATMEL_SPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/pm9263_defconfig b/configs/pm9263_defconfig
index d9cfcb1..a9bae26 100644
--- a/configs/pm9263_defconfig
+++ b/configs/pm9263_defconfig
@@ -45,3 +45,4 @@  CONFIG_ATMEL_SPI=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_LCD=y
+CONFIG_NAND=y
diff --git a/configs/pm9g45_defconfig b/configs/pm9g45_defconfig
index 4e5181b..6cbc82b 100644
--- a/configs/pm9g45_defconfig
+++ b/configs/pm9g45_defconfig
@@ -23,3 +23,4 @@  CONFIG_ENV_IS_IN_NAND=y
 # CONFIG_MMC is not set
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/pogo_e02_defconfig b/configs/pogo_e02_defconfig
index 82f68d9..3fba856 100644
--- a/configs/pogo_e02_defconfig
+++ b/configs/pogo_e02_defconfig
@@ -24,3 +24,4 @@  CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/portl2_defconfig b/configs/portl2_defconfig
index 7db4110..5b333db 100644
--- a/configs/portl2_defconfig
+++ b/configs/portl2_defconfig
@@ -31,3 +31,4 @@  CONFIG_SPI_FLASH_STMICRO=y
 CONFIG_SYS_NS16550=y
 CONFIG_BCH=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/sama5d2_ptc_ek_mmc_defconfig b/configs/sama5d2_ptc_ek_mmc_defconfig
index 03dc69b..60ab0ea 100644
--- a/configs/sama5d2_ptc_ek_mmc_defconfig
+++ b/configs/sama5d2_ptc_ek_mmc_defconfig
@@ -58,3 +58,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/sama5d2_ptc_ek_nandflash_defconfig b/configs/sama5d2_ptc_ek_nandflash_defconfig
index 8340f81..2967cb4 100644
--- a/configs/sama5d2_ptc_ek_nandflash_defconfig
+++ b/configs/sama5d2_ptc_ek_nandflash_defconfig
@@ -58,3 +58,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/sama5d36ek_cmp_mmc_defconfig b/configs/sama5d36ek_cmp_mmc_defconfig
index 685caa3..c2bd80e 100644
--- a/configs/sama5d36ek_cmp_mmc_defconfig
+++ b/configs/sama5d36ek_cmp_mmc_defconfig
@@ -55,3 +55,4 @@  CONFIG_TIMER=y
 CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/sama5d36ek_cmp_nandflash_defconfig b/configs/sama5d36ek_cmp_nandflash_defconfig
index 0f42c98..c7a6505 100644
--- a/configs/sama5d36ek_cmp_nandflash_defconfig
+++ b/configs/sama5d36ek_cmp_nandflash_defconfig
@@ -56,3 +56,4 @@  CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
 CONFIG_FAT_WRITE=y
+CONFIG_NAND=y
diff --git a/configs/sama5d36ek_cmp_spiflash_defconfig b/configs/sama5d36ek_cmp_spiflash_defconfig
index 52ad137..dbc90f8 100644
--- a/configs/sama5d36ek_cmp_spiflash_defconfig
+++ b/configs/sama5d36ek_cmp_spiflash_defconfig
@@ -56,3 +56,4 @@  CONFIG_ATMEL_PIT_TIMER=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
 CONFIG_FAT_WRITE=y
+CONFIG_NAND=y
diff --git a/configs/sama5d3_xplained_mmc_defconfig b/configs/sama5d3_xplained_mmc_defconfig
index 8da4f4e..f1f1ab1 100644
--- a/configs/sama5d3_xplained_mmc_defconfig
+++ b/configs/sama5d3_xplained_mmc_defconfig
@@ -72,3 +72,4 @@  CONFIG_USB=y
 CONFIG_DM_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/sama5d3_xplained_nandflash_defconfig b/configs/sama5d3_xplained_nandflash_defconfig
index 98152af..5a6d635 100644
--- a/configs/sama5d3_xplained_nandflash_defconfig
+++ b/configs/sama5d3_xplained_nandflash_defconfig
@@ -70,3 +70,4 @@  CONFIG_DM_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_FAT_WRITE=y
+CONFIG_NAND=y
diff --git a/configs/sama5d3xek_mmc_defconfig b/configs/sama5d3xek_mmc_defconfig
index cf57936..e404083 100644
--- a/configs/sama5d3xek_mmc_defconfig
+++ b/configs/sama5d3xek_mmc_defconfig
@@ -84,3 +84,4 @@  CONFIG_USB_GADGET=y
 CONFIG_USB_GADGET_ATMEL_USBA=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/sama5d3xek_nandflash_defconfig b/configs/sama5d3xek_nandflash_defconfig
index c34ff17..cbb8e72 100644
--- a/configs/sama5d3xek_nandflash_defconfig
+++ b/configs/sama5d3xek_nandflash_defconfig
@@ -80,3 +80,4 @@  CONFIG_USB_GADGET_ATMEL_USBA=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
 CONFIG_FAT_WRITE=y
+CONFIG_NAND=y
diff --git a/configs/sama5d3xek_spiflash_defconfig b/configs/sama5d3xek_spiflash_defconfig
index e48813d..ff05772 100644
--- a/configs/sama5d3xek_spiflash_defconfig
+++ b/configs/sama5d3xek_spiflash_defconfig
@@ -79,3 +79,4 @@  CONFIG_USB_GADGET_ATMEL_USBA=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
 CONFIG_FAT_WRITE=y
+CONFIG_NAND=y
diff --git a/configs/sama5d4_xplained_mmc_defconfig b/configs/sama5d4_xplained_mmc_defconfig
index b7faf70..10e66b6 100644
--- a/configs/sama5d4_xplained_mmc_defconfig
+++ b/configs/sama5d4_xplained_mmc_defconfig
@@ -79,3 +79,4 @@  CONFIG_USB_GADGET=y
 CONFIG_USB_GADGET_ATMEL_USBA=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/sama5d4_xplained_nandflash_defconfig b/configs/sama5d4_xplained_nandflash_defconfig
index 7255d47..ef8a866 100644
--- a/configs/sama5d4_xplained_nandflash_defconfig
+++ b/configs/sama5d4_xplained_nandflash_defconfig
@@ -76,3 +76,4 @@  CONFIG_USB_GADGET=y
 CONFIG_USB_GADGET_ATMEL_USBA=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/sama5d4_xplained_spiflash_defconfig b/configs/sama5d4_xplained_spiflash_defconfig
index c93705b..ac6fc7c 100644
--- a/configs/sama5d4_xplained_spiflash_defconfig
+++ b/configs/sama5d4_xplained_spiflash_defconfig
@@ -78,3 +78,4 @@  CONFIG_USB_GADGET=y
 CONFIG_USB_GADGET_ATMEL_USBA=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/sama5d4ek_mmc_defconfig b/configs/sama5d4ek_mmc_defconfig
index 97c59bd..b83d637 100644
--- a/configs/sama5d4ek_mmc_defconfig
+++ b/configs/sama5d4ek_mmc_defconfig
@@ -79,3 +79,4 @@  CONFIG_USB_GADGET=y
 CONFIG_USB_GADGET_ATMEL_USBA=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/sama5d4ek_nandflash_defconfig b/configs/sama5d4ek_nandflash_defconfig
index e491608..fcae5f4 100644
--- a/configs/sama5d4ek_nandflash_defconfig
+++ b/configs/sama5d4ek_nandflash_defconfig
@@ -76,3 +76,4 @@  CONFIG_USB_GADGET=y
 CONFIG_USB_GADGET_ATMEL_USBA=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/sama5d4ek_spiflash_defconfig b/configs/sama5d4ek_spiflash_defconfig
index 8d7da40..cf8a207 100644
--- a/configs/sama5d4ek_spiflash_defconfig
+++ b/configs/sama5d4ek_spiflash_defconfig
@@ -75,3 +75,4 @@  CONFIG_USB_GADGET=y
 CONFIG_USB_GADGET_ATMEL_USBA=y
 CONFIG_DM_VIDEO=y
 CONFIG_ATMEL_HLCD=y
+CONFIG_NAND=y
diff --git a/configs/seaboard_defconfig b/configs/seaboard_defconfig
index c8cc3b6..5525cd5 100644
--- a/configs/seaboard_defconfig
+++ b/configs/seaboard_defconfig
@@ -41,3 +41,4 @@  CONFIG_DM_VIDEO=y
 CONFIG_VIDEO_TEGRA20=y
 CONFIG_CONSOLE_SCROLL_LINES=10
 CONFIG_AES=y
+CONFIG_NAND=y
diff --git a/configs/sheevaplug_defconfig b/configs/sheevaplug_defconfig
index 21704ec..2e5cae8 100644
--- a/configs/sheevaplug_defconfig
+++ b/configs/sheevaplug_defconfig
@@ -32,3 +32,4 @@  CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_STORAGE=y
 CONFIG_LZMA=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/smartweb_defconfig b/configs/smartweb_defconfig
index 12f0f93..5934455 100644
--- a/configs/smartweb_defconfig
+++ b/configs/smartweb_defconfig
@@ -55,3 +55,4 @@  CONFIG_USB_HOST_ETHER=y
 CONFIG_USB_ETHER_ASIX=y
 CONFIG_USB_ETHER_MCS7830=y
 # CONFIG_EFI_LOADER is not set
+CONFIG_NAND=y
diff --git a/configs/snapper9260_defconfig b/configs/snapper9260_defconfig
index 8f9ff1f..6684514 100644
--- a/configs/snapper9260_defconfig
+++ b/configs/snapper9260_defconfig
@@ -29,3 +29,4 @@  CONFIG_CMD_PCA953X=y
 # CONFIG_MMC is not set
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/snapper9g20_defconfig b/configs/snapper9g20_defconfig
index 6bb8628..95df3cc 100644
--- a/configs/snapper9g20_defconfig
+++ b/configs/snapper9g20_defconfig
@@ -28,3 +28,4 @@  CONFIG_CMD_PCA953X=y
 # CONFIG_MMC is not set
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
+CONFIG_NAND=y
diff --git a/configs/socrates_defconfig b/configs/socrates_defconfig
index abb1ac2..b6e7646 100644
--- a/configs/socrates_defconfig
+++ b/configs/socrates_defconfig
@@ -38,3 +38,4 @@  CONFIG_USB_STORAGE=y
 CONFIG_VIDEO=y
 CONFIG_CONSOLE_EXTRA_INFO=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/spear300_defconfig b/configs/spear300_defconfig
index 22a4685..d2e7724 100644
--- a/configs/spear300_defconfig
+++ b/configs/spear300_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear300_usbtty_defconfig b/configs/spear300_usbtty_defconfig
index adbf408..8b43f2e 100644
--- a/configs/spear300_usbtty_defconfig
+++ b/configs/spear300_usbtty_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear310_defconfig b/configs/spear310_defconfig
index 9517ac0..438baa4 100644
--- a/configs/spear310_defconfig
+++ b/configs/spear310_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear310_pnor_defconfig b/configs/spear310_pnor_defconfig
index 5c1b142..036cbca 100644
--- a/configs/spear310_pnor_defconfig
+++ b/configs/spear310_pnor_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear310_usbtty_defconfig b/configs/spear310_usbtty_defconfig
index 7b438ec..1645782 100644
--- a/configs/spear310_usbtty_defconfig
+++ b/configs/spear310_usbtty_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear310_usbtty_pnor_defconfig b/configs/spear310_usbtty_pnor_defconfig
index 611517d..f13c9f7 100644
--- a/configs/spear310_usbtty_pnor_defconfig
+++ b/configs/spear310_usbtty_pnor_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear320_defconfig b/configs/spear320_defconfig
index 66fb6b7..ff91ecb 100644
--- a/configs/spear320_defconfig
+++ b/configs/spear320_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear320_pnor_defconfig b/configs/spear320_pnor_defconfig
index a08cd7e..e884bbf 100644
--- a/configs/spear320_pnor_defconfig
+++ b/configs/spear320_pnor_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear320_usbtty_defconfig b/configs/spear320_usbtty_defconfig
index 34b3622..ff58563 100644
--- a/configs/spear320_usbtty_defconfig
+++ b/configs/spear320_usbtty_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear320_usbtty_pnor_defconfig b/configs/spear320_usbtty_pnor_defconfig
index 7f09cfb..27c5af0 100644
--- a/configs/spear320_usbtty_pnor_defconfig
+++ b/configs/spear320_usbtty_pnor_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear600_defconfig b/configs/spear600_defconfig
index dc58179..cce1ca9 100644
--- a/configs/spear600_defconfig
+++ b/configs/spear600_defconfig
@@ -24,3 +24,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/spear600_usbtty_defconfig b/configs/spear600_usbtty_defconfig
index 80e93e3..af144e3 100644
--- a/configs/spear600_usbtty_defconfig
+++ b/configs/spear600_usbtty_defconfig
@@ -21,3 +21,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_NETDEVICES=y
 CONFIG_PHY_GIGE=y
 CONFIG_ETH_DESIGNWARE=y
+CONFIG_NAND=y
diff --git a/configs/taurus_defconfig b/configs/taurus_defconfig
index 9e9f6fb..6209170 100644
--- a/configs/taurus_defconfig
+++ b/configs/taurus_defconfig
@@ -57,3 +57,4 @@  CONFIG_USB_GADGET_VENDOR_NUM=0x0908
 CONFIG_USB_GADGET_PRODUCT_NUM=0x02d2
 CONFIG_USB_GADGET_DOWNLOAD=y
 CONFIG_USE_TINY_PRINTF=y
+CONFIG_NAND=y
diff --git a/configs/tec_defconfig b/configs/tec_defconfig
index 2f0e14f..64d560d 100644
--- a/configs/tec_defconfig
+++ b/configs/tec_defconfig
@@ -37,3 +37,4 @@  CONFIG_USB_HOST_ETHER=y
 CONFIG_USB_ETHER_SMSC95XX=y
 CONFIG_DM_VIDEO=y
 CONFIG_VIDEO_TEGRA20=y
+CONFIG_NAND=y
diff --git a/configs/titanium_defconfig b/configs/titanium_defconfig
index c47702e..3094656 100644
--- a/configs/titanium_defconfig
+++ b/configs/titanium_defconfig
@@ -36,3 +36,4 @@  CONFIG_NETDEVICES=y
 CONFIG_USB=y
 CONFIG_USB_STORAGE=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/usb_a9263_dataflash_defconfig b/configs/usb_a9263_dataflash_defconfig
index e4ed415..dd13e4d 100644
--- a/configs/usb_a9263_dataflash_defconfig
+++ b/configs/usb_a9263_dataflash_defconfig
@@ -40,3 +40,4 @@  CONFIG_DM_SERIAL=y
 CONFIG_ATMEL_USART=y
 CONFIG_DM_SPI=y
 CONFIG_ATMEL_SPI=y
+CONFIG_NAND=y
diff --git a/configs/ve8313_defconfig b/configs/ve8313_defconfig
index b93af89..8ad632c 100644
--- a/configs/ve8313_defconfig
+++ b/configs/ve8313_defconfig
@@ -18,3 +18,4 @@  CONFIG_MTD_NOR_FLASH=y
 CONFIG_PHYLIB=y
 CONFIG_SYS_NS16550=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/wb45n_defconfig b/configs/wb45n_defconfig
index 6cf41df..647dfa6 100644
--- a/configs/wb45n_defconfig
+++ b/configs/wb45n_defconfig
@@ -25,3 +25,4 @@  CONFIG_CMD_PING=y
 CONFIG_ENV_IS_IN_NAND=y
 CONFIG_LZMA=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/wb50n_defconfig b/configs/wb50n_defconfig
index 1f3e41e..e37a797 100644
--- a/configs/wb50n_defconfig
+++ b/configs/wb50n_defconfig
@@ -28,3 +28,4 @@  CONFIG_PHY_MICREL_KSZ90X1=y
 CONFIG_NETDEVICES=y
 CONFIG_LZMA=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/work_92105_defconfig b/configs/work_92105_defconfig
index 1fccaac..9fab5f1 100644
--- a/configs/work_92105_defconfig
+++ b/configs/work_92105_defconfig
@@ -36,3 +36,4 @@  CONFIG_DM_GPIO=y
 CONFIG_PHYLIB=y
 CONFIG_DM_SERIAL=y
 CONFIG_SYS_NS16550=y
+CONFIG_NAND=y
diff --git a/configs/x600_defconfig b/configs/x600_defconfig
index 4658f97..2147963 100644
--- a/configs/x600_defconfig
+++ b/configs/x600_defconfig
@@ -51,3 +51,4 @@  CONFIG_BCH=y
 CONFIG_USE_TINY_PRINTF=y
 CONFIG_OF_LIBFDT=y
 # CONFIG_EFI_LOADER is not set
+CONFIG_NAND=y
diff --git a/configs/xpedite517x_defconfig b/configs/xpedite517x_defconfig
index 3773518..92aa6fc 100644
--- a/configs/xpedite517x_defconfig
+++ b/configs/xpedite517x_defconfig
@@ -25,6 +25,8 @@  CONFIG_CMD_PCA953X=y
 CONFIG_DS4510=y
 # CONFIG_MMC is not set
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
+CONFIG_SYS_MAX_NAND_DEVICE=2
 CONFIG_PHYLIB=y
 CONFIG_SYS_NS16550=y
 CONFIG_PANIC_HANG=y
diff --git a/configs/xpedite520x_defconfig b/configs/xpedite520x_defconfig
index 7fffaa8..3d39c38 100644
--- a/configs/xpedite520x_defconfig
+++ b/configs/xpedite520x_defconfig
@@ -30,3 +30,4 @@  CONFIG_PHYLIB=y
 CONFIG_SYS_NS16550=y
 CONFIG_PANIC_HANG=y
 CONFIG_OF_LIBFDT=y
+CONFIG_NAND=y
diff --git a/configs/xpedite537x_defconfig b/configs/xpedite537x_defconfig
index 223bc4c..ca0989e 100644
--- a/configs/xpedite537x_defconfig
+++ b/configs/xpedite537x_defconfig
@@ -28,6 +28,8 @@  CONFIG_CMD_PCA953X=y
 CONFIG_DS4510=y
 # CONFIG_MMC is not set
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
+CONFIG_SYS_MAX_NAND_DEVICE=2
 CONFIG_PHYLIB=y
 CONFIG_SYS_NS16550=y
 CONFIG_PANIC_HANG=y
diff --git a/configs/xpedite550x_defconfig b/configs/xpedite550x_defconfig
index f3b9280..5e4c827 100644
--- a/configs/xpedite550x_defconfig
+++ b/configs/xpedite550x_defconfig
@@ -26,6 +26,8 @@  CONFIG_ENV_IS_IN_FLASH=y
 CONFIG_CMD_PCA953X=y
 # CONFIG_MMC is not set
 CONFIG_MTD_NOR_FLASH=y
+CONFIG_NAND=y
+CONFIG_SYS_MAX_NAND_DEVICE=2
 CONFIG_PHYLIB=y
 CONFIG_SYS_NS16550=y
 CONFIG_USB=y
diff --git a/drivers/mtd/nand/Kconfig b/drivers/mtd/nand/Kconfig
index 78a39ab..e991440 100644
--- a/drivers/mtd/nand/Kconfig
+++ b/drivers/mtd/nand/Kconfig
@@ -181,6 +181,12 @@  config SYS_NAND_BUSWIDTH_16BIT
 	    not available while configuring controller. So a static CONFIG_NAND_xx
 	    is needed to know the device's bus-width in advance.
 
+config SYS_MAX_NAND_DEVICE
+	int "Maximum number of NAND devices"
+	default 1
+	help
+	  Set this if there are more than 1 NAND devices
+
 if SPL
 
 config SYS_NAND_U_BOOT_LOCATIONS
diff --git a/include/configs/B4860QDS.h b/include/configs/B4860QDS.h
index 25e6c1f..403628f 100644
--- a/include/configs/B4860QDS.h
+++ b/include/configs/B4860QDS.h
@@ -354,7 +354,6 @@  unsigned long get_board_ddr_clk(void);
 #define CONFIG_SYS_NAND_DDR_LAW		11
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 
diff --git a/include/configs/BSC9131RDB.h b/include/configs/BSC9131RDB.h
index c3a7e1d..9d3b57a 100644
--- a/include/configs/BSC9131RDB.h
+++ b/include/configs/BSC9131RDB.h
@@ -180,7 +180,6 @@  extern unsigned long get_sdram_size(void);
 #define CONFIG_SYS_NAND_FTIM3		FTIM3_NAND_TWW(0x04)
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 
 #define CONFIG_SYS_NAND_DDR_LAW		11
diff --git a/include/configs/BSC9132QDS.h b/include/configs/BSC9132QDS.h
index fcacd16..d90e4e6 100644
--- a/include/configs/BSC9132QDS.h
+++ b/include/configs/BSC9132QDS.h
@@ -290,7 +290,6 @@  combinations. this should be removed later
 
 /* NAND */
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 
diff --git a/include/configs/C29XPCIE.h b/include/configs/C29XPCIE.h
index f9d8cc6..1d823be 100644
--- a/include/configs/C29XPCIE.h
+++ b/include/configs/C29XPCIE.h
@@ -195,7 +195,6 @@ 
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
 
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(1024 * 1024)
 
 /* 8Bit NAND Flash - K9F1G08U0B */
diff --git a/include/configs/M5329EVB.h b/include/configs/M5329EVB.h
index 0a69395..3a3eda4 100644
--- a/include/configs/M5329EVB.h
+++ b/include/configs/M5329EVB.h
@@ -156,7 +156,6 @@ 
 #endif
 
 #ifdef CONFIG_NANDFLASH_SIZE
-#	define CONFIG_SYS_MAX_NAND_DEVICE	1
 #	define CONFIG_SYS_NAND_BASE		CONFIG_SYS_CS2_BASE
 #	define CONFIG_SYS_NAND_SIZE		1
 #	define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
diff --git a/include/configs/M5373EVB.h b/include/configs/M5373EVB.h
index ecf2abc..bd0161c 100644
--- a/include/configs/M5373EVB.h
+++ b/include/configs/M5373EVB.h
@@ -156,7 +156,6 @@ 
 #endif
 
 #ifdef CONFIG_NANDFLASH_SIZE
-#	define CONFIG_SYS_MAX_NAND_DEVICE	1
 #	define CONFIG_SYS_NAND_BASE		CONFIG_SYS_CS2_BASE
 #	define CONFIG_SYS_NAND_SIZE		1
 #	define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
diff --git a/include/configs/M54418TWR.h b/include/configs/M54418TWR.h
index 3e2b6e1..8ec9057 100644
--- a/include/configs/M54418TWR.h
+++ b/include/configs/M54418TWR.h
@@ -44,7 +44,6 @@ 
 #define CONFIG_JFFS2_NAND
 #define CONFIG_NAND_FSL_NFC
 #define CONFIG_SYS_NAND_BASE		0xFC0FC000
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define NAND_MAX_CHIPS			CONFIG_SYS_MAX_NAND_DEVICE
 #define CONFIG_SYS_NAND_SELECT_DEVICE
 #endif
diff --git a/include/configs/MCR3000.h b/include/configs/MCR3000.h
index 9d2c486..929acbc 100644
--- a/include/configs/MCR3000.h
+++ b/include/configs/MCR3000.h
@@ -133,7 +133,6 @@ 
 #endif
 
 /* NAND configuration part */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_MAX_CHIPS	1
 #define CONFIG_SYS_NAND_BASE		0x0C000000
 
diff --git a/include/configs/MPC8313ERDB.h b/include/configs/MPC8313ERDB.h
index 0f60892..99a2022 100644
--- a/include/configs/MPC8313ERDB.h
+++ b/include/configs/MPC8313ERDB.h
@@ -260,7 +260,6 @@ 
 #define CONFIG_MTD_DEVICE
 #define CONFIG_MTD_PARTITION
 
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_NAND_FSL_ELBC 1
 #define CONFIG_SYS_NAND_BLOCK_SIZE 16384
 #define CONFIG_SYS_NAND_WINDOW_SIZE (32 * 1024)
diff --git a/include/configs/MPC8315ERDB.h b/include/configs/MPC8315ERDB.h
index bd1a7b2..beb82cb 100644
--- a/include/configs/MPC8315ERDB.h
+++ b/include/configs/MPC8315ERDB.h
@@ -236,7 +236,6 @@ 
 #define CONFIG_MTD_DEVICE
 #define CONFIG_MTD_PARTITION
 
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_NAND_FSL_ELBC		1
 #define CONFIG_SYS_NAND_BLOCK_SIZE	16384
 #define CONFIG_SYS_NAND_WINDOW_SIZE    (32 * 1024)     /* 0x00008000 */
diff --git a/include/configs/MPC837XEMDS.h b/include/configs/MPC837XEMDS.h
index 3cc1a47..12cfab4 100644
--- a/include/configs/MPC837XEMDS.h
+++ b/include/configs/MPC837XEMDS.h
@@ -278,7 +278,6 @@ 
 /*
  * NAND Flash on the Local Bus
  */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_NAND_FSL_ELBC	1
 
 #define CONFIG_SYS_NAND_BASE	0xE0600000
diff --git a/include/configs/MPC8536DS.h b/include/configs/MPC8536DS.h
index eef1602..053ad4a 100644
--- a/include/configs/MPC8536DS.h
+++ b/include/configs/MPC8536DS.h
@@ -284,7 +284,6 @@ 
 				CONFIG_SYS_NAND_BASE + 0x40000, \
 				CONFIG_SYS_NAND_BASE + 0x80000, \
 				CONFIG_SYS_NAND_BASE + 0xC0000}
-#define CONFIG_SYS_MAX_NAND_DEVICE	4
 #define CONFIG_NAND_FSL_ELBC	1
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 
diff --git a/include/configs/MPC8569MDS.h b/include/configs/MPC8569MDS.h
index 861c8dd..02ad468 100644
--- a/include/configs/MPC8569MDS.h
+++ b/include/configs/MPC8569MDS.h
@@ -180,7 +180,6 @@  extern unsigned long get_clock_freq(void);
 
 #define CONFIG_SYS_NAND_BASE_PHYS	CONFIG_SYS_NAND_BASE
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE, }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_NAND_FSL_ELBC		1
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 #define CONFIG_SYS_NAND_BR_PRELIM	(CONFIG_SYS_NAND_BASE_PHYS \
diff --git a/include/configs/MPC8572DS.h b/include/configs/MPC8572DS.h
index 91a5591..c63118d 100644
--- a/include/configs/MPC8572DS.h
+++ b/include/configs/MPC8572DS.h
@@ -283,7 +283,6 @@ 
 				CONFIG_SYS_NAND_BASE + 0x40000, \
 				CONFIG_SYS_NAND_BASE + 0x80000,\
 				CONFIG_SYS_NAND_BASE + 0xC0000}
-#define CONFIG_SYS_MAX_NAND_DEVICE    4
 #define CONFIG_NAND_FSL_ELBC	1
 #define CONFIG_SYS_NAND_BLOCK_SIZE    (128 * 1024)
 #define CONFIG_SYS_NAND_MAX_OOBFREE	5
diff --git a/include/configs/P1010RDB.h b/include/configs/P1010RDB.h
index 6a444ae..6cb3d57 100644
--- a/include/configs/P1010RDB.h
+++ b/include/configs/P1010RDB.h
@@ -380,7 +380,6 @@  extern unsigned long get_sdram_size(void);
 #endif
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #if defined(CONFIG_TARGET_P1010RDB_PA)
 /* NAND Flash Timing Params */
diff --git a/include/configs/P1022DS.h b/include/configs/P1022DS.h
index 30e20bc..259f877 100644
--- a/include/configs/P1022DS.h
+++ b/include/configs/P1022DS.h
@@ -244,7 +244,6 @@ 
 #endif
 
 #define CONFIG_SYS_NAND_BASE_LIST	{CONFIG_SYS_NAND_BASE}
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(256 * 1024)
 #define CONFIG_ELBC_NAND_SPL_STATIC_PGSIZE
 
diff --git a/include/configs/P1023RDB.h b/include/configs/P1023RDB.h
index 1863bec..9564c82 100644
--- a/include/configs/P1023RDB.h
+++ b/include/configs/P1023RDB.h
@@ -122,7 +122,6 @@  extern unsigned long get_clock_freq(void);
 #define CONFIG_SYS_NAND_BASE_PHYS	CONFIG_SYS_NAND_BASE
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_NAND_FSL_ELBC
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 
diff --git a/include/configs/P2041RDB.h b/include/configs/P2041RDB.h
index 6b9f366..6aa37d4 100644
--- a/include/configs/P2041RDB.h
+++ b/include/configs/P2041RDB.h
@@ -225,7 +225,6 @@  unsigned long get_board_sys_clk(unsigned long dummy);
 #endif
 
 #define CONFIG_SYS_NAND_BASE_LIST     {CONFIG_SYS_NAND_BASE}
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BLOCK_SIZE    (128 * 1024)
 
 /* NAND flash config */
diff --git a/include/configs/T102xQDS.h b/include/configs/T102xQDS.h
index 2354dc8..a5e7cc0 100644
--- a/include/configs/T102xQDS.h
+++ b/include/configs/T102xQDS.h
@@ -363,7 +363,6 @@  unsigned long get_board_ddr_clk(void);
 
 #define CONFIG_SYS_NAND_DDR_LAW		11
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 
diff --git a/include/configs/T102xRDB.h b/include/configs/T102xRDB.h
index 733e44f..9ef4417 100644
--- a/include/configs/T102xRDB.h
+++ b/include/configs/T102xRDB.h
@@ -390,7 +390,6 @@  unsigned long get_board_ddr_clk(void);
 
 #define CONFIG_SYS_NAND_DDR_LAW		11
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #if defined(CONFIG_NAND)
 #define CONFIG_SYS_CSPR0_EXT		CONFIG_SYS_NAND_CSPR_EXT
diff --git a/include/configs/T1040QDS.h b/include/configs/T1040QDS.h
index e96d3a0..e573046 100644
--- a/include/configs/T1040QDS.h
+++ b/include/configs/T1040QDS.h
@@ -281,7 +281,6 @@  unsigned long get_board_ddr_clk(void);
 
 #define CONFIG_SYS_NAND_DDR_LAW		11
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 
diff --git a/include/configs/T104xRDB.h b/include/configs/T104xRDB.h
index 1231c1a..184dfc6 100644
--- a/include/configs/T104xRDB.h
+++ b/include/configs/T104xRDB.h
@@ -395,7 +395,6 @@  $(SRCTREE)/board/freescale/t104xrdb/t1042d4_sd_rcw.cfg
 
 #define CONFIG_SYS_NAND_DDR_LAW		11
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(512 * 1024)
 
diff --git a/include/configs/T208xQDS.h b/include/configs/T208xQDS.h
index 6fbac5f..375647f 100644
--- a/include/configs/T208xQDS.h
+++ b/include/configs/T208xQDS.h
@@ -336,7 +336,6 @@  unsigned long get_board_ddr_clk(void);
 
 #define CONFIG_SYS_NAND_DDR_LAW		11
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 
 #if defined(CONFIG_NAND)
diff --git a/include/configs/T208xRDB.h b/include/configs/T208xRDB.h
index 85bda94..66e3bb0 100644
--- a/include/configs/T208xRDB.h
+++ b/include/configs/T208xRDB.h
@@ -300,7 +300,6 @@  unsigned long get_board_ddr_clk(void);
 
 #define CONFIG_SYS_NAND_DDR_LAW		11
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(512 * 1024)
 
 #if defined(CONFIG_NAND)
diff --git a/include/configs/T4240QDS.h b/include/configs/T4240QDS.h
index 73e91bc..05dc4ba 100644
--- a/include/configs/T4240QDS.h
+++ b/include/configs/T4240QDS.h
@@ -257,7 +257,6 @@  unsigned long get_board_ddr_clk(void);
 #define CONFIG_SYS_NAND_DDR_LAW		11
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 #define CONFIG_SYS_NAND_MAX_OOBFREE	2
diff --git a/include/configs/T4240RDB.h b/include/configs/T4240RDB.h
index b63c38c..15c799e 100644
--- a/include/configs/T4240RDB.h
+++ b/include/configs/T4240RDB.h
@@ -432,7 +432,6 @@  unsigned long get_board_ddr_clk(void);
 
 #define CONFIG_SYS_NAND_DDR_LAW		11
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(512 * 1024)
 
diff --git a/include/configs/am3517_crane.h b/include/configs/am3517_crane.h
index 16212ef..8f5315c 100644
--- a/include/configs/am3517_crane.h
+++ b/include/configs/am3517_crane.h
@@ -109,7 +109,6 @@ 
 							/* to access */
 							/* nand at CS0 */
 
-#define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of */
 							/* NAND devices */
 
 #define CONFIG_JFFS2_NAND
diff --git a/include/configs/apf27.h b/include/configs/apf27.h
index 24afc84..ac1cc20 100644
--- a/include/configs/apf27.h
+++ b/include/configs/apf27.h
@@ -184,7 +184,6 @@ 
 
 #define CONFIG_MXC_NAND_REGS_BASE	0xD8000000
 #define CONFIG_SYS_NAND_BASE		CONFIG_MXC_NAND_REGS_BASE
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #define CONFIG_MXC_NAND_HWECC
 #define CONFIG_SYS_NAND_LARGEPAGE
diff --git a/include/configs/aristainetos-common.h b/include/configs/aristainetos-common.h
index 397afbb..e3981b0 100644
--- a/include/configs/aristainetos-common.h
+++ b/include/configs/aristainetos-common.h
@@ -177,7 +177,6 @@ 
 
 /* NAND stuff */
 #define CONFIG_NAND_MXS
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/at91sam9260ek.h b/include/configs/at91sam9260ek.h
index ea7478b..85a10f4 100644
--- a/include/configs/at91sam9260ek.h
+++ b/include/configs/at91sam9260ek.h
@@ -96,7 +96,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		ATMEL_BASE_CS3
 #define CONFIG_SYS_NAND_DBW_8
 #define CONFIG_SYS_NAND_MASK_ALE	(1 << 21)
diff --git a/include/configs/at91sam9261ek.h b/include/configs/at91sam9261ek.h
index 39e4b38..37486b4 100644
--- a/include/configs/at91sam9261ek.h
+++ b/include/configs/at91sam9261ek.h
@@ -65,7 +65,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_BASE			0x40000000
 #define CONFIG_SYS_NAND_DBW_8
 /* our ALE is AD22 */
diff --git a/include/configs/at91sam9263ek.h b/include/configs/at91sam9263ek.h
index 9431777..6f00aef 100644
--- a/include/configs/at91sam9263ek.h
+++ b/include/configs/at91sam9263ek.h
@@ -203,7 +203,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_BASE			ATMEL_BASE_CS3
 #define CONFIG_SYS_NAND_DBW_8			1
 /* our ALE is AD21 */
diff --git a/include/configs/at91sam9m10g45ek.h b/include/configs/at91sam9m10g45ek.h
index 2957da9..9dee6e4 100644
--- a/include/configs/at91sam9m10g45ek.h
+++ b/include/configs/at91sam9m10g45ek.h
@@ -59,7 +59,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_BASE			ATMEL_BASE_CS3
 #define CONFIG_SYS_NAND_DBW_8
 /* our ALE is AD21 */
diff --git a/include/configs/at91sam9n12ek.h b/include/configs/at91sam9n12ek.h
index 87728df..8acb917 100644
--- a/include/configs/at91sam9n12ek.h
+++ b/include/configs/at91sam9n12ek.h
@@ -59,7 +59,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_MASK_ALE	(1 << 21)
 #define CONFIG_SYS_NAND_MASK_CLE	(1 << 22)
diff --git a/include/configs/at91sam9rlek.h b/include/configs/at91sam9rlek.h
index c08fb2e..90fb335 100644
--- a/include/configs/at91sam9rlek.h
+++ b/include/configs/at91sam9rlek.h
@@ -56,7 +56,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_BASE			ATMEL_BASE_CS3
 #define CONFIG_SYS_NAND_DBW_8			1
 /* our ALE is AD21 */
diff --git a/include/configs/at91sam9x5ek.h b/include/configs/at91sam9x5ek.h
index 9450784..1f16a17 100644
--- a/include/configs/at91sam9x5ek.h
+++ b/include/configs/at91sam9x5ek.h
@@ -52,7 +52,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_DBW_8		1
 /* our ALE is AD21 */
diff --git a/include/configs/axs10x.h b/include/configs/axs10x.h
index a9c4d1a..ce0b38c 100644
--- a/include/configs/axs10x.h
+++ b/include/configs/axs10x.h
@@ -41,7 +41,6 @@ 
  * NAND Flash configuration
  */
 #define CONFIG_SYS_NAND_BASE		(ARC_FPGA_PERIPHERAL_BASE + 0x16000)
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 /*
  * UART configuration
diff --git a/include/configs/brppt1.h b/include/configs/brppt1.h
index a8022b8..0894821 100644
--- a/include/configs/brppt1.h
+++ b/include/configs/brppt1.h
@@ -181,7 +181,6 @@  MMCARGS
  * GPMC  block.  We support 1 device and the physical address to
  * access CS0 at is 0x8000000.
  */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x8000000
 /* don't change OMAP_ELM, ECCSCHEME. ROM code only supports this */
 #define CONFIG_NAND_OMAP_ECCSCHEME	OMAP_ECC_BCH8_CODE_HW
diff --git a/include/configs/cm_fx6.h b/include/configs/cm_fx6.h
index da870b9..c53f239 100644
--- a/include/configs/cm_fx6.h
+++ b/include/configs/cm_fx6.h
@@ -181,7 +181,6 @@ 
 #ifndef CONFIG_SPL_BUILD
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_MAX_CHIPS	1
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_NAND_MXS
 #define CONFIG_SYS_NAND_ONFI_DETECTION
 /* APBH DMA is required for NAND support */
diff --git a/include/configs/cm_t35.h b/include/configs/cm_t35.h
index 3c64cb5..ef480d4 100644
--- a/include/configs/cm_t35.h
+++ b/include/configs/cm_t35.h
@@ -100,7 +100,6 @@ 
 #define CONFIG_SYS_NAND_BASE		NAND_BASE	/* physical address */
 							/* to access nand at */
 							/* CS0 */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of NAND */
 							/* devices */
 
 /* Environment information */
diff --git a/include/configs/cm_t3517.h b/include/configs/cm_t3517.h
index fe8b39a..48dd6a6 100644
--- a/include/configs/cm_t3517.h
+++ b/include/configs/cm_t3517.h
@@ -104,7 +104,6 @@ 
 #define CONFIG_SYS_NAND_BASE		NAND_BASE	/* physical address */
 							/* to access nand at */
 							/* CS0 */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of NAND */
 							/* devices */
 
 /* Environment information */
diff --git a/include/configs/colibri_imx7.h b/include/configs/colibri_imx7.h
index 04036c8..cb0501a 100644
--- a/include/configs/colibri_imx7.h
+++ b/include/configs/colibri_imx7.h
@@ -161,7 +161,6 @@ 
 #define CONFIG_NAND_MXS
 
 /* NAND stuff */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/colibri_t20.h b/include/configs/colibri_t20.h
index e7f9405..88b9077 100644
--- a/include/configs/colibri_t20.h
+++ b/include/configs/colibri_t20.h
@@ -40,7 +40,6 @@ 
 
 /* NAND support */
 #define CONFIG_TEGRA_NAND
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 /* Dynamic MTD partition support */
 #define CONFIG_MTD_PARTITIONS
diff --git a/include/configs/colibri_vf.h b/include/configs/colibri_vf.h
index c7a34c2..74ae437 100644
--- a/include/configs/colibri_vf.h
+++ b/include/configs/colibri_vf.h
@@ -44,7 +44,6 @@ 
 
 /* NAND support */
 #define CONFIG_SYS_NAND_ONFI_DETECTION
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		NFC_BASE_ADDR
 
 /* Dynamic MTD partition support */
diff --git a/include/configs/corenet_ds.h b/include/configs/corenet_ds.h
index 0e9dae6..e312fd5 100644
--- a/include/configs/corenet_ds.h
+++ b/include/configs/corenet_ds.h
@@ -234,7 +234,6 @@ 
 #endif
 
 #define CONFIG_SYS_NAND_BASE_LIST     {CONFIG_SYS_NAND_BASE}
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BLOCK_SIZE    (128 * 1024)
 
 /* NAND flash config */
diff --git a/include/configs/corvus.h b/include/configs/corvus.h
index cc671f2..3883667 100644
--- a/include/configs/corvus.h
+++ b/include/configs/corvus.h
@@ -71,7 +71,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_BASE			ATMEL_BASE_CS3
 #define CONFIG_SYS_NAND_DBW_8
 /* our ALE is AD21 */
diff --git a/include/configs/da850evm.h b/include/configs/da850evm.h
index 2a6916b..3e7dc82 100644
--- a/include/configs/da850evm.h
+++ b/include/configs/da850evm.h
@@ -182,7 +182,6 @@ 
 #define CONFIG_SYS_NAND_MASK_CLE		0x10
 #define CONFIG_SYS_NAND_MASK_ALE		0x8
 #undef CONFIG_SYS_NAND_HW_ECC
-#define CONFIG_SYS_MAX_NAND_DEVICE	1 /* Max number of NAND devices */
 #define CONFIG_SYS_NAND_HW_ECC_OOBFIRST
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_SIZE	(2 << 10)
diff --git a/include/configs/devkit3250.h b/include/configs/devkit3250.h
index 526a81a..2617b31 100644
--- a/include/configs/devkit3250.h
+++ b/include/configs/devkit3250.h
@@ -90,7 +90,6 @@ 
  */
 #define CONFIG_NAND_LPC32XX_SLC
 #define CONFIG_SYS_NAND_BASE		SLC_NAND_BASE
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
 
 /*
diff --git a/include/configs/ea20.h b/include/configs/ea20.h
index efc72b3..427fad6 100644
--- a/include/configs/ea20.h
+++ b/include/configs/ea20.h
@@ -135,7 +135,6 @@ 
 #undef CONFIG_SYS_NAND_HW_ECC
 #define CONFIG_SYS_NAND_4BIT_HW_ECC_OOBFIRST
 #define	CONFIG_SYS_NAND_USE_FLASH_BBT
-#define CONFIG_SYS_MAX_NAND_DEVICE	1 /* Max number of NAND devices */
 #endif
 
 /* SPI Flash */
diff --git a/include/configs/etamin.h b/include/configs/etamin.h
index ef9f330..5be6c66 100644
--- a/include/configs/etamin.h
+++ b/include/configs/etamin.h
@@ -62,8 +62,6 @@ 
 
 #define CONFIG_SYS_NAND_MAX_CHIPS       1
 
-#undef CONFIG_SYS_MAX_NAND_DEVICE
-#define CONFIG_SYS_MAX_NAND_DEVICE      3
 #define CONFIG_SYS_NAND_BASE2           (0x18000000)    /* physical address */
 #define CONFIG_SYS_NAND_BASE_LIST       {CONFIG_SYS_NAND_BASE, \
 					CONFIG_SYS_NAND_BASE2}
diff --git a/include/configs/ethernut5.h b/include/configs/ethernut5.h
index 322e623..2fe4eca 100644
--- a/include/configs/ethernut5.h
+++ b/include/configs/ethernut5.h
@@ -65,7 +65,6 @@ 
 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_DBW_8
 #define CONFIG_NAND_ATMEL
diff --git a/include/configs/flea3.h b/include/configs/flea3.h
index e4d5f91..5052f60 100644
--- a/include/configs/flea3.h
+++ b/include/configs/flea3.h
@@ -155,7 +155,6 @@ 
  * NAND FLASH driver setup
  */
 #define CONFIG_MXC_NAND_REGS_BASE	(NFC_BASE_ADDR)
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		(NFC_BASE_ADDR)
 #define CONFIG_MXC_NAND_HWECC
 #define CONFIG_SYS_NAND_LARGEPAGE
diff --git a/include/configs/gw_ventana.h b/include/configs/gw_ventana.h
index 068962d..290690a 100644
--- a/include/configs/gw_ventana.h
+++ b/include/configs/gw_ventana.h
@@ -68,7 +68,6 @@ 
 /* Enable NAND support */
 #ifdef CONFIG_CMD_NAND
   #define CONFIG_NAND_MXS
-  #define CONFIG_SYS_MAX_NAND_DEVICE	1
   #define CONFIG_SYS_NAND_BASE		0x40000000
   #define CONFIG_SYS_NAND_5_ADDR_CYCLE
   #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/harmony.h b/include/configs/harmony.h
index 9a0b1af..726a37f 100644
--- a/include/configs/harmony.h
+++ b/include/configs/harmony.h
@@ -28,7 +28,6 @@ 
 
 /* NAND support */
 #define CONFIG_TEGRA_NAND
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 /* Environment in NAND (which is 512M), aligned to start of last sector */
 #define CONFIG_ENV_OFFSET	(SZ_512M - SZ_128K) /* 128K sector size */
diff --git a/include/configs/ids8313.h b/include/configs/ids8313.h
index 12eb07d..48fbd6c 100644
--- a/include/configs/ids8313.h
+++ b/include/configs/ids8313.h
@@ -202,7 +202,6 @@ 
  * NAND FLASH setup
  */
 #define CONFIG_SYS_NAND_BASE		0xE1000000
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_MAX_CHIPS	1
 #define CONFIG_NAND_FSL_ELBC
 #define CONFIG_SYS_NAND_PAGE_SIZE	(2048)
diff --git a/include/configs/imx27lite-common.h b/include/configs/imx27lite-common.h
index 9596f0b..f8f7302 100644
--- a/include/configs/imx27lite-common.h
+++ b/include/configs/imx27lite-common.h
@@ -126,7 +126,6 @@ 
  * NAND
  */
 #define CONFIG_MXC_NAND_REGS_BASE	0xd8000000
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0xd8000000
 #define CONFIG_JFFS2_NAND
 #define CONFIG_MXC_NAND_HWECC
diff --git a/include/configs/imx6-engicam.h b/include/configs/imx6-engicam.h
index 0c45e06..c483227 100644
--- a/include/configs/imx6-engicam.h
+++ b/include/configs/imx6-engicam.h
@@ -151,7 +151,6 @@ 
 
 /* NAND */
 #ifdef CONFIG_NAND_MXS
-# define CONFIG_SYS_MAX_NAND_DEVICE	1
 # define CONFIG_SYS_NAND_BASE		0x40000000
 # define CONFIG_SYS_NAND_5_ADDR_CYCLE
 # define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/imx6_logic.h b/include/configs/imx6_logic.h
index f0ff5b2..0d8774d 100644
--- a/include/configs/imx6_logic.h
+++ b/include/configs/imx6_logic.h
@@ -144,7 +144,6 @@ 
 #define CONFIG_ENV_SECT_SIZE          CONFIG_ENV_SIZE
 
 /* NAND stuff */
-#define CONFIG_SYS_MAX_NAND_DEVICE     1
 #define CONFIG_SYS_NAND_BASE           0x40000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/ipam390.h b/include/configs/ipam390.h
index 618bf72..29c1d31 100644
--- a/include/configs/ipam390.h
+++ b/include/configs/ipam390.h
@@ -146,7 +146,6 @@ 
 #define CONFIG_SYS_NAND_MASK_CLE		0x10
 #define CONFIG_SYS_NAND_MASK_ALE		0x8
 #undef CONFIG_SYS_NAND_HW_ECC
-#define CONFIG_SYS_MAX_NAND_DEVICE	1 /* Max number of NAND devices */
 #define CONFIG_SYS_NAND_HW_ECC_OOBFIRST
 #define CONFIG_NAND_6BYTES_OOB_FREE_10BYTES_ECC
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
diff --git a/include/configs/km/km83xx-common.h b/include/configs/km/km83xx-common.h
index f0ec5cf..799fd62 100644
--- a/include/configs/km/km83xx-common.h
+++ b/include/configs/km/km83xx-common.h
@@ -202,7 +202,6 @@ 
 
 #if defined(CONFIG_CMD_NAND)
 #define CONFIG_NAND_KMETER1
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		CONFIG_SYS_KMBEC_FPGA_BASE
 #endif
 
diff --git a/include/configs/km/km_arm.h b/include/configs/km/km_arm.h
index ed58d1e..9552b85 100644
--- a/include/configs/km/km_arm.h
+++ b/include/configs/km/km_arm.h
@@ -114,7 +114,6 @@ 
 /*
  * NAND Flash configuration
  */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #define BOOTFLASH_START		0x0
 
diff --git a/include/configs/km/kmp204x-common.h b/include/configs/km/kmp204x-common.h
index a0c932a..aaf4e6c 100644
--- a/include/configs/km/kmp204x-common.h
+++ b/include/configs/km/kmp204x-common.h
@@ -151,7 +151,6 @@  unsigned long get_board_sys_clk(unsigned long dummy);
 #define CONFIG_SYS_NAND_BASE_PHYS	0xfffa00000ull
 
 #define CONFIG_SYS_NAND_BASE_LIST     {CONFIG_SYS_NAND_BASE}
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BLOCK_SIZE    (128 * 1024)
 
 /* NAND flash config */
diff --git a/include/configs/km8360.h b/include/configs/km8360.h
index a2a26f9..d22f34c 100644
--- a/include/configs/km8360.h
+++ b/include/configs/km8360.h
@@ -23,7 +23,6 @@ 
 #define CONFIG_KM_DEF_NETDEV	"netdev=eth1\0"
 #define CONFIG_NAND_ECC_BCH
 #define CONFIG_NAND_KMETER1
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define NAND_MAX_CHIPS				1
 #define CONFIG_SYS_NAND_BASE CONFIG_SYS_KMBEC_FPGA_BASE /* PRIO_BASE_ADDRESS */
 
diff --git a/include/configs/ls1021aqds.h b/include/configs/ls1021aqds.h
index d088e83..9763f74 100644
--- a/include/configs/ls1021aqds.h
+++ b/include/configs/ls1021aqds.h
@@ -217,7 +217,6 @@  unsigned long get_board_ddr_clk(void);
 #define CONFIG_SYS_NAND_FTIM3           0x0
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 #endif
diff --git a/include/configs/ls1043aqds.h b/include/configs/ls1043aqds.h
index a7f78f4..5d79492 100644
--- a/include/configs/ls1043aqds.h
+++ b/include/configs/ls1043aqds.h
@@ -194,7 +194,6 @@  unsigned long get_board_ddr_clk(void);
 #define CONFIG_SYS_NAND_FTIM3           0x0
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_MTD_NAND_VERIFY_WRITE
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
diff --git a/include/configs/ls1043ardb.h b/include/configs/ls1043ardb.h
index 34f8228..8569b5d 100644
--- a/include/configs/ls1043ardb.h
+++ b/include/configs/ls1043ardb.h
@@ -132,7 +132,6 @@ 
 #define CONFIG_SYS_NAND_FTIM3		0x0
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_MTD_NAND_VERIFY_WRITE
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
diff --git a/include/configs/ls1046aqds.h b/include/configs/ls1046aqds.h
index 456f61a..3583baa 100644
--- a/include/configs/ls1046aqds.h
+++ b/include/configs/ls1046aqds.h
@@ -228,7 +228,6 @@  unsigned long get_board_ddr_clk(void);
 #define CONFIG_SYS_NAND_FTIM3           0x0
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_MTD_NAND_VERIFY_WRITE
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(256 * 1024)
diff --git a/include/configs/ls1046ardb.h b/include/configs/ls1046ardb.h
index 2755f1c..be05fbc 100644
--- a/include/configs/ls1046ardb.h
+++ b/include/configs/ls1046ardb.h
@@ -93,7 +93,6 @@ 
 #define CONFIG_SYS_NAND_FTIM3		0x0
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_MTD_NAND_VERIFY_WRITE
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
diff --git a/include/configs/ls1088aqds.h b/include/configs/ls1088aqds.h
index 8fbf890..07bd90a 100644
--- a/include/configs/ls1088aqds.h
+++ b/include/configs/ls1088aqds.h
@@ -154,7 +154,6 @@  unsigned long get_board_ddr_clk(void);
 #define CONFIG_SYS_NAND_FTIM3		0x0
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_MTD_NAND_VERIFY_WRITE
 #define CONFIG_CMD_NAND
 
diff --git a/include/configs/ls1088ardb.h b/include/configs/ls1088ardb.h
index d0066e3..80517b1 100644
--- a/include/configs/ls1088ardb.h
+++ b/include/configs/ls1088ardb.h
@@ -140,7 +140,6 @@ 
 #define CONFIG_SYS_NAND_FTIM3		0x0
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_MTD_NAND_VERIFY_WRITE
 #define CONFIG_CMD_NAND
 
diff --git a/include/configs/ls2080a_simu.h b/include/configs/ls2080a_simu.h
index dad1090..bf5360e 100644
--- a/include/configs/ls2080a_simu.h
+++ b/include/configs/ls2080a_simu.h
@@ -108,7 +108,6 @@ 
 #define CONFIG_SYS_NAND_FTIM3		0x0
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_MTD_NAND_VERIFY_WRITE
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
diff --git a/include/configs/ls2080aqds.h b/include/configs/ls2080aqds.h
index 815d8ad..15446e4 100644
--- a/include/configs/ls2080aqds.h
+++ b/include/configs/ls2080aqds.h
@@ -149,7 +149,6 @@  unsigned long get_board_ddr_clk(void);
 #define CONFIG_SYS_NAND_FTIM3		0x0
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_MTD_NAND_VERIFY_WRITE
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
diff --git a/include/configs/ls2080ardb.h b/include/configs/ls2080ardb.h
index 6f3301c..d223b6b 100644
--- a/include/configs/ls2080ardb.h
+++ b/include/configs/ls2080ardb.h
@@ -158,7 +158,6 @@  unsigned long get_board_sys_clk(void);
 #define CONFIG_SYS_NAND_FTIM3		0x0
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_MTD_NAND_VERIFY_WRITE
 
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(512 * 1024)
diff --git a/include/configs/m53evk.h b/include/configs/m53evk.h
index 50379c7..0155487 100644
--- a/include/configs/m53evk.h
+++ b/include/configs/m53evk.h
@@ -73,7 +73,6 @@ 
  */
 #define CONFIG_ENV_SIZE			(16 * 1024)
 #ifdef CONFIG_CMD_NAND
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		NFC_BASE_ADDR_AXI
 #define CONFIG_MXC_NAND_REGS_BASE	NFC_BASE_ADDR_AXI
 #define CONFIG_MXC_NAND_IP_REGS_BASE	NFC_BASE_ADDR
diff --git a/include/configs/mcx.h b/include/configs/mcx.h
index f0ab990..835d474 100644
--- a/include/configs/mcx.h
+++ b/include/configs/mcx.h
@@ -95,7 +95,6 @@ 
 							/* to access */
 							/* nand at CS0 */
 
-#define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of */
 							/* NAND devices */
 #define CONFIG_JFFS2_NAND
 /* nand device jffs2 lives on */
diff --git a/include/configs/medcom-wide.h b/include/configs/medcom-wide.h
index 2efdc52..b399f1c 100644
--- a/include/configs/medcom-wide.h
+++ b/include/configs/medcom-wide.h
@@ -21,7 +21,6 @@ 
 
 /* NAND support */
 #define CONFIG_TEGRA_NAND
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 /* Environment in NAND, aligned to start of last sector */
 #define CONFIG_ENV_OFFSET		(SZ_512M - SZ_128K) /* 128K sectors */
diff --git a/include/configs/meesc.h b/include/configs/meesc.h
index 1540221..5e11c1a 100644
--- a/include/configs/meesc.h
+++ b/include/configs/meesc.h
@@ -83,7 +83,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 # define CONFIG_NAND_ATMEL
-# define CONFIG_SYS_MAX_NAND_DEVICE		1
 # define CONFIG_SYS_NAND_BASE			ATMEL_BASE_CS3 /* 0x40000000 */
 # define CONFIG_SYS_NAND_DBW_8
 # define CONFIG_SYS_NAND_MASK_ALE		(1 << 21)
diff --git a/include/configs/mv-common.h b/include/configs/mv-common.h
index 1721fef..1551171 100644
--- a/include/configs/mv-common.h
+++ b/include/configs/mv-common.h
@@ -105,9 +105,6 @@ 
 /*
  * Common NAND configuration
  */
-#ifdef CONFIG_CMD_NAND
-#define CONFIG_SYS_MAX_NAND_DEVICE     1
-#endif
 
 /*
  * Common SPI Flash configuration
diff --git a/include/configs/mvebu_armada-8k.h b/include/configs/mvebu_armada-8k.h
index 86e0d43..171ad8f 100644
--- a/include/configs/mvebu_armada-8k.h
+++ b/include/configs/mvebu_armada-8k.h
@@ -77,7 +77,6 @@ 
 #define CONFIG_ENV_SIZE			(64 << 10) /* 64KiB */
 #define CONFIG_ENV_SECT_SIZE		(64 << 10) /* 64KiB sectors */
 
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_MAX_CHIPS	1
 #define CONFIG_SYS_NAND_ONFI_DETECTION
 #define CONFIG_SYS_NAND_USE_FLASH_BBT
diff --git a/include/configs/mx31pdk.h b/include/configs/mx31pdk.h
index 3259e82..1df0d6f 100644
--- a/include/configs/mx31pdk.h
+++ b/include/configs/mx31pdk.h
@@ -119,7 +119,6 @@ 
  * NAND driver
  */
 #define CONFIG_MXC_NAND_REGS_BASE      NFC_BASE_ADDR
-#define CONFIG_SYS_MAX_NAND_DEVICE     1
 #define CONFIG_SYS_NAND_BASE           NFC_BASE_ADDR
 #define CONFIG_MXC_NAND_HWECC
 #define CONFIG_SYS_NAND_LARGEPAGE
diff --git a/include/configs/mx35pdk.h b/include/configs/mx35pdk.h
index 6a334cb..9fd9f12 100644
--- a/include/configs/mx35pdk.h
+++ b/include/configs/mx35pdk.h
@@ -175,7 +175,6 @@ 
  * NAND FLASH driver setup
  */
 #define CONFIG_MXC_NAND_REGS_BASE	(NFC_BASE_ADDR)
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		(NFC_BASE_ADDR)
 #define CONFIG_MXC_NAND_HWECC
 #define CONFIG_SYS_NAND_LARGEPAGE
diff --git a/include/configs/mx53ard.h b/include/configs/mx53ard.h
index 985109e..688b71f 100644
--- a/include/configs/mx53ard.h
+++ b/include/configs/mx53ard.h
@@ -25,7 +25,6 @@ 
 
 #define CONFIG_MXC_GPIO
 
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		NFC_BASE_ADDR_AXI
 #define CONFIG_MXC_NAND_REGS_BASE	NFC_BASE_ADDR_AXI
 #define CONFIG_MXC_NAND_IP_REGS_BASE	NFC_BASE_ADDR
diff --git a/include/configs/mx6sabreauto.h b/include/configs/mx6sabreauto.h
index 64d54b6..ca7103c 100644
--- a/include/configs/mx6sabreauto.h
+++ b/include/configs/mx6sabreauto.h
@@ -67,7 +67,6 @@ 
 
 /* NAND stuff */
 #define CONFIG_NAND_MXS
-#define CONFIG_SYS_MAX_NAND_DEVICE     1
 #define CONFIG_SYS_NAND_BASE           0x40000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/mx6sxsabreauto.h b/include/configs/mx6sxsabreauto.h
index 9e46c39..9ffcf19 100644
--- a/include/configs/mx6sxsabreauto.h
+++ b/include/configs/mx6sxsabreauto.h
@@ -120,7 +120,6 @@ 
 
 /* NAND stuff */
 #define CONFIG_NAND_MXS
-#define CONFIG_SYS_MAX_NAND_DEVICE     1
 #define CONFIG_SYS_NAND_BASE           0x40000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/mx7dsabresd.h b/include/configs/mx7dsabresd.h
index 593bf38..7db5aaa 100644
--- a/include/configs/mx7dsabresd.h
+++ b/include/configs/mx7dsabresd.h
@@ -191,7 +191,6 @@ 
  */
 #ifdef CONFIG_NAND_MXS
 /* NAND stuff */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/mxs.h b/include/configs/mxs.h
index 804b9e1..3fb49d4 100644
--- a/include/configs/mxs.h
+++ b/include/configs/mxs.h
@@ -138,7 +138,6 @@ 
 /* NAND */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_MXS
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x60000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #endif
diff --git a/include/configs/omap3_beagle.h b/include/configs/omap3_beagle.h
index d3dfe60..1ec8ccb 100644
--- a/include/configs/omap3_beagle.h
+++ b/include/configs/omap3_beagle.h
@@ -34,7 +34,6 @@ 
 /* NAND */
 #if defined(CONFIG_NAND)
 #define CONFIG_SYS_FLASH_BASE		NAND_BASE
-#define CONFIG_SYS_MAX_NAND_DEVICE      1
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT      64
 #define CONFIG_SYS_NAND_PAGE_SIZE       2048
diff --git a/include/configs/omap3_cairo.h b/include/configs/omap3_cairo.h
index f9a7e0c..3404ff5 100644
--- a/include/configs/omap3_cairo.h
+++ b/include/configs/omap3_cairo.h
@@ -57,7 +57,6 @@ 
 /*
  * Board NAND Info.
  */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of NAND */
 							/* devices */
 #define CONFIG_EXTRA_ENV_SETTINGS \
 	"machid=ffffffff\0" \
diff --git a/include/configs/omap3_evm.h b/include/configs/omap3_evm.h
index ba67e33..0bd8f0c 100644
--- a/include/configs/omap3_evm.h
+++ b/include/configs/omap3_evm.h
@@ -47,7 +47,6 @@ 
 /* NAND */
 #if defined(CONFIG_NAND)
 #define CONFIG_SYS_FLASH_BASE		NAND_BASE
-#define CONFIG_SYS_MAX_NAND_DEVICE      1
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT      64
 #define CONFIG_SYS_NAND_PAGE_SIZE       2048
diff --git a/include/configs/omap3_logic.h b/include/configs/omap3_logic.h
index 70745a8..6f44a4b 100644
--- a/include/configs/omap3_logic.h
+++ b/include/configs/omap3_logic.h
@@ -56,7 +56,6 @@ 
 #ifdef CONFIG_NAND
 #define CONFIG_SYS_NAND_ADDR		NAND_BASE /* physical address */
 						  /* to access nand */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1	  /* Max number of */
 						  /* NAND devices */
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	64
diff --git a/include/configs/omapl138_lcdk.h b/include/configs/omapl138_lcdk.h
index 2cb9911..5a56d8e 100644
--- a/include/configs/omapl138_lcdk.h
+++ b/include/configs/omapl138_lcdk.h
@@ -163,7 +163,6 @@ 
 #define CONFIG_SYS_NAND_MASK_CLE	0x10
 #define CONFIG_SYS_NAND_MASK_ALE	0x8
 #undef CONFIG_SYS_NAND_HW_ECC
-#define CONFIG_SYS_MAX_NAND_DEVICE	1 /* Max number of NAND devices */
 #define CONFIG_SYS_NAND_HW_ECC_OOBFIRST
 #define CONFIG_NAND_6BYTES_OOB_FREE_10BYTES_ECC
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
diff --git a/include/configs/p1_p2_rdb_pc.h b/include/configs/p1_p2_rdb_pc.h
index 4522569..4aa5a79 100644
--- a/include/configs/p1_p2_rdb_pc.h
+++ b/include/configs/p1_p2_rdb_pc.h
@@ -403,7 +403,6 @@ 
 #endif
 
 #define CONFIG_SYS_NAND_BASE_LIST	{ CONFIG_SYS_NAND_BASE }
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #if defined(CONFIG_TARGET_P1020RDB_PD)
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128 * 1024)
 #else
diff --git a/include/configs/pcm052.h b/include/configs/pcm052.h
index 6021420..adb081e 100644
--- a/include/configs/pcm052.h
+++ b/include/configs/pcm052.h
@@ -26,7 +26,6 @@ 
 #define CONFIG_SYS_NAND_ONFI_DETECTION
 
 #ifdef CONFIG_CMD_NAND
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		NFC_BASE_ADDR
 
 #define CONFIG_JFFS2_NAND
diff --git a/include/configs/pcm058.h b/include/configs/pcm058.h
index 3067fc6..f0a3b23 100644
--- a/include/configs/pcm058.h
+++ b/include/configs/pcm058.h
@@ -59,7 +59,6 @@ 
 #ifndef CONFIG_SPL_BUILD
 /* Enable NAND support */
 #define CONFIG_NAND_MXS
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/pfla02.h b/include/configs/pfla02.h
index ae03310..8e947f1 100644
--- a/include/configs/pfla02.h
+++ b/include/configs/pfla02.h
@@ -58,7 +58,6 @@ 
 /* Enable NAND support */
 #define CONFIG_CMD_NAND_TRIMFFS
 #define CONFIG_NAND_MXS
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/platinum.h b/include/configs/platinum.h
index 453c37d..3e1135c 100644
--- a/include/configs/platinum.h
+++ b/include/configs/platinum.h
@@ -70,7 +70,6 @@ 
 #ifndef CONFIG_SYS_NAND_MAX_CHIPS
 #define CONFIG_SYS_NAND_MAX_CHIPS		2
 #endif
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_BASE			0x40000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/plutux.h b/include/configs/plutux.h
index eef2062..cd418b2 100644
--- a/include/configs/plutux.h
+++ b/include/configs/plutux.h
@@ -21,7 +21,6 @@ 
 
 /* NAND support */
 #define CONFIG_TEGRA_NAND
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 /* Environment in NAND, aligned to start of last sector */
 #define CONFIG_ENV_OFFSET		(SZ_512M - SZ_128K) /* 128K sectors */
diff --git a/include/configs/pm9261.h b/include/configs/pm9261.h
index dec23a7..4d111ce 100644
--- a/include/configs/pm9261.h
+++ b/include/configs/pm9261.h
@@ -166,7 +166,6 @@ 
 
 /* NAND flash */
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_BASE			0x40000000
 #define CONFIG_SYS_NAND_DBW_8			1
 /* our ALE is AD22 */
diff --git a/include/configs/pm9263.h b/include/configs/pm9263.h
index 8aab3e1..8c0b5a9 100644
--- a/include/configs/pm9263.h
+++ b/include/configs/pm9263.h
@@ -189,7 +189,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_DBW_8		1
 /* our ALE is AD21 */
diff --git a/include/configs/pm9g45.h b/include/configs/pm9g45.h
index e11c67f..9521f1c 100644
--- a/include/configs/pm9g45.h
+++ b/include/configs/pm9g45.h
@@ -78,7 +78,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_DBW_8		1
 /* our ALE is AD21 */
diff --git a/include/configs/s32v234evb.h b/include/configs/s32v234evb.h
index fd1527c..e0a3c6a 100644
--- a/include/configs/s32v234evb.h
+++ b/include/configs/s32v234evb.h
@@ -103,7 +103,6 @@ 
 #define MTD_NAND_FSL_NFC_SWECC 1
 #define CONFIG_NAND_FSL_NFC
 #define CONFIG_SYS_NAND_BASE		0x400E0000
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define NAND_MAX_CHIPS			CONFIG_SYS_MAX_NAND_DEVICE
 #define CONFIG_SYS_NAND_SELECT_DEVICE
 #define CONFIG_SYS_64BIT_VSPRINTF	/* needed for nand_util.c */
diff --git a/include/configs/sama5d2_ptc_ek.h b/include/configs/sama5d2_ptc_ek.h
index d99eaee..378f8c7 100644
--- a/include/configs/sama5d2_ptc_ek.h
+++ b/include/configs/sama5d2_ptc_ek.h
@@ -31,7 +31,6 @@ 
 /* NAND Flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		ATMEL_BASE_CS3
 /* our ALE is AD21 */
 #define CONFIG_SYS_NAND_MASK_ALE	BIT(21)
diff --git a/include/configs/sama5d3_xplained.h b/include/configs/sama5d3_xplained.h
index a6697cd..03af82b 100644
--- a/include/configs/sama5d3_xplained.h
+++ b/include/configs/sama5d3_xplained.h
@@ -38,7 +38,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x60000000
 /* our ALE is AD21 */
 #define CONFIG_SYS_NAND_MASK_ALE	(1 << 21)
diff --git a/include/configs/sama5d3xek.h b/include/configs/sama5d3xek.h
index 9ec1e76..912115f 100644
--- a/include/configs/sama5d3xek.h
+++ b/include/configs/sama5d3xek.h
@@ -62,7 +62,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x60000000
 /* our ALE is AD21 */
 #define CONFIG_SYS_NAND_MASK_ALE	(1 << 21)
diff --git a/include/configs/sama5d4_xplained.h b/include/configs/sama5d4_xplained.h
index 6aa4bcc..25a02ec 100644
--- a/include/configs/sama5d4_xplained.h
+++ b/include/configs/sama5d4_xplained.h
@@ -35,7 +35,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x80000000
 /* our ALE is AD21 */
 #define CONFIG_SYS_NAND_MASK_ALE	(1 << 21)
diff --git a/include/configs/sama5d4ek.h b/include/configs/sama5d4ek.h
index a46e350..192255d 100644
--- a/include/configs/sama5d4ek.h
+++ b/include/configs/sama5d4ek.h
@@ -33,7 +33,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x80000000
 /* our ALE is AD21 */
 #define CONFIG_SYS_NAND_MASK_ALE	(1 << 21)
diff --git a/include/configs/seaboard.h b/include/configs/seaboard.h
index c0b8090..dc09e97 100644
--- a/include/configs/seaboard.h
+++ b/include/configs/seaboard.h
@@ -48,7 +48,6 @@ 
 #define CONFIG_TEGRA_NAND
 
 /* Max number of NAND devices */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 #include "tegra-common-post.h"
 
diff --git a/include/configs/siemens-am33x-common.h b/include/configs/siemens-am33x-common.h
index 85b6412..61fc400 100644
--- a/include/configs/siemens-am33x-common.h
+++ b/include/configs/siemens-am33x-common.h
@@ -490,7 +490,6 @@ 
 #define CONFIG_SYS_NAND_BASE		(0x08000000)	/* physical address */
 							/* to access nand at */
 							/* CS0 */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of NAND
 							   devices */
 #if !defined(CONFIG_SPI_BOOT)
 #define CONFIG_ENV_OFFSET		0x260000 /* environment starts here */
diff --git a/include/configs/smartweb.h b/include/configs/smartweb.h
index 49c838b..bda2761 100644
--- a/include/configs/smartweb.h
+++ b/include/configs/smartweb.h
@@ -83,7 +83,6 @@ 
 
 /* NAND flash settings */
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		ATMEL_BASE_CS3
 #define CONFIG_SYS_NAND_DBW_8
 #define CONFIG_SYS_NAND_MASK_ALE	(1 << 21)
diff --git a/include/configs/snapper9260.h b/include/configs/snapper9260.h
index b4ac12e..206abe1 100644
--- a/include/configs/snapper9260.h
+++ b/include/configs/snapper9260.h
@@ -42,7 +42,6 @@ 
 
 /* NAND Flash */
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		ATMEL_BASE_CS3
 #define CONFIG_SYS_NAND_DBW_8
 #define CONFIG_SYS_NAND_MASK_ALE	(1 << 21) /* AD21 */
diff --git a/include/configs/snapper9g45.h b/include/configs/snapper9g45.h
index f0e1a1d..1e618f2 100644
--- a/include/configs/snapper9g45.h
+++ b/include/configs/snapper9g45.h
@@ -42,7 +42,6 @@ 
 #define CONFIG_NAND_ATMEL
 #define CONFIG_ATMEL_NAND_HWECC
 #define CONFIG_SYS_NAND_ECC_BASE	ATMEL_BASE_ECC
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		ATMEL_BASE_CS3
 #define CONFIG_SYS_NAND_DBW_8
 #define CONFIG_SYS_NAND_MASK_ALE	(1 << 21) /* AD21 */
diff --git a/include/configs/socfpga_common.h b/include/configs/socfpga_common.h
index 66e7c4f..d0f21dd 100644
--- a/include/configs/socfpga_common.h
+++ b/include/configs/socfpga_common.h
@@ -140,7 +140,6 @@ 
  * NAND Support
  */
 #ifdef CONFIG_NAND_DENALI
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_ONFI_DETECTION
 #define CONFIG_SYS_NAND_REGS_BASE	SOCFPGA_NANDREGS_ADDRESS
 #define CONFIG_SYS_NAND_DATA_BASE	SOCFPGA_NANDDATA_ADDRESS
diff --git a/include/configs/socrates.h b/include/configs/socrates.h
index 0d88ab5..4f9b5b1 100644
--- a/include/configs/socrates.h
+++ b/include/configs/socrates.h
@@ -151,7 +151,6 @@ 
 #define CONFIG_SYS_OR3_PRELIM		0xfff00000	/* 1 MB 	*/
 
 #define CONFIG_SYS_NAND_BASE		(CONFIG_SYS_FPGA_BASE + 0x70)
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 /* LIME GDC */
 #define CONFIG_SYS_LIME_BASE		0xc8000000
diff --git a/include/configs/spear-common.h b/include/configs/spear-common.h
index 349232e..5c34ea4 100644
--- a/include/configs/spear-common.h
+++ b/include/configs/spear-common.h
@@ -89,7 +89,6 @@ 
 #define CONFIG_MTD_DEVICE
 #define CONFIG_MTD_PARTITIONS
 #define CONFIG_NAND_FSMC
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_ONFI_DETECTION
 
 /*
diff --git a/include/configs/sunxi-common.h b/include/configs/sunxi-common.h
index 582aba2..bab5f6e 100644
--- a/include/configs/sunxi-common.h
+++ b/include/configs/sunxi-common.h
@@ -131,7 +131,6 @@ 
 #ifdef CONFIG_NAND_SUNXI
 #define CONFIG_SYS_NAND_MAX_ECCPOS 1664
 #define CONFIG_SYS_NAND_ONFI_DETECTION
-#define CONFIG_SYS_MAX_NAND_DEVICE 8
 
 #define CONFIG_MTD_DEVICE
 #define CONFIG_MTD_PARTITIONS
diff --git a/include/configs/suvd3.h b/include/configs/suvd3.h
index a1d1984..5e583db 100644
--- a/include/configs/suvd3.h
+++ b/include/configs/suvd3.h
@@ -49,7 +49,6 @@ 
 
 #define CONFIG_NAND_ECC_BCH
 #define CONFIG_NAND_KMETER1
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define NAND_MAX_CHIPS				1
 
 /* include common defines/options for all 8309 Keymile boards */
diff --git a/include/configs/tam3517-common.h b/include/configs/tam3517-common.h
index 7f05cb0..94d3e54 100644
--- a/include/configs/tam3517-common.h
+++ b/include/configs/tam3517-common.h
@@ -80,7 +80,6 @@ 
 							/* to access */
 							/* nand at CS0 */
 
-#define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of */
 							/* NAND devices */
 
 #define CONFIG_AUTO_COMPLETE
diff --git a/include/configs/tao3530.h b/include/configs/tao3530.h
index 0e9fe68..243ba65 100644
--- a/include/configs/tao3530.h
+++ b/include/configs/tao3530.h
@@ -81,7 +81,6 @@ 
 							/* to access nand at */
 							/* CS0 */
 
-#define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of NAND */
 							/* devices */
 /* Environment information */
 
diff --git a/include/configs/taurus.h b/include/configs/taurus.h
index ce06f7b..a5bf562 100644
--- a/include/configs/taurus.h
+++ b/include/configs/taurus.h
@@ -76,7 +76,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		ATMEL_BASE_CS3
 #define CONFIG_SYS_NAND_DBW_8
 #define CONFIG_SYS_NAND_MASK_ALE	(1 << 21)
diff --git a/include/configs/tec.h b/include/configs/tec.h
index 0febe46..fda7b39 100644
--- a/include/configs/tec.h
+++ b/include/configs/tec.h
@@ -21,7 +21,6 @@ 
 
 /* NAND support */
 #define CONFIG_TEGRA_NAND
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 /* Environment in NAND, aligned to start of last sector */
 #define CONFIG_ENV_OFFSET		(SZ_512M - SZ_128K) /* 128K sectors */
diff --git a/include/configs/ti816x_evm.h b/include/configs/ti816x_evm.h
index b0f84ed..1329fc4 100644
--- a/include/configs/ti816x_evm.h
+++ b/include/configs/ti816x_evm.h
@@ -63,7 +63,6 @@ 
  * access CS0 at is 0x8000000.
  */
 #define CONFIG_SYS_NAND_BASE		0x8000000
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 
 /* NAND: SPL related configs */
 
diff --git a/include/configs/ti_armv7_keystone2.h b/include/configs/ti_armv7_keystone2.h
index bbed17a..4727ae8 100644
--- a/include/configs/ti_armv7_keystone2.h
+++ b/include/configs/ti_armv7_keystone2.h
@@ -179,7 +179,6 @@ 
 
 #define CONFIG_SYS_NAND_LARGEPAGE
 #define CONFIG_SYS_NAND_BASE_LIST		{ 0x30000000, }
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_MAX_CHIPS		1
 #define CONFIG_SYS_NAND_NO_SUBPAGE_WRITE
 #define CONFIG_MTD_PARTITIONS
diff --git a/include/configs/ti_armv7_omap.h b/include/configs/ti_armv7_omap.h
index da5fc81..2cff868 100644
--- a/include/configs/ti_armv7_omap.h
+++ b/include/configs/ti_armv7_omap.h
@@ -24,7 +24,6 @@ 
 #ifndef CONFIG_SYS_NAND_BASE
 #define CONFIG_SYS_NAND_BASE		0x8000000
 #endif
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #endif
 
 /* Now for the remaining common defines */
diff --git a/include/configs/titanium.h b/include/configs/titanium.h
index cc655f2..d09790b 100644
--- a/include/configs/titanium.h
+++ b/include/configs/titanium.h
@@ -143,7 +143,6 @@ 
 
 /* NAND stuff */
 #define CONFIG_NAND_MXS
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		0x40000000
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_ONFI_DETECTION
diff --git a/include/configs/tricorder.h b/include/configs/tricorder.h
index f892a57..6f119df 100644
--- a/include/configs/tricorder.h
+++ b/include/configs/tricorder.h
@@ -77,7 +77,6 @@ 
 #define CONFIG_SYS_NAND_BASE		NAND_BASE	/* physical address */
 							/* to access nand at */
 							/* CS0 */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of NAND */
 							/* devices */
 #define CONFIG_SYS_NAND_MAX_OOBFREE	2
 #define CONFIG_SYS_NAND_MAX_ECCPOS	56
diff --git a/include/configs/uniphier.h b/include/configs/uniphier.h
index 5ab06f6..b7d89e6 100644
--- a/include/configs/uniphier.h
+++ b/include/configs/uniphier.h
@@ -69,7 +69,6 @@ 
 #define CONFIG_SYS_TIMER_RATE			1000000
 #endif
 
-#define CONFIG_SYS_MAX_NAND_DEVICE			1
 #define CONFIG_SYS_NAND_ONFI_DETECTION
 #define CONFIG_SYS_NAND_REGS_BASE			0x68100000
 #define CONFIG_SYS_NAND_DATA_BASE			0x68000000
diff --git a/include/configs/usb_a9263.h b/include/configs/usb_a9263.h
index cd28c4d..2006bb2 100644
--- a/include/configs/usb_a9263.h
+++ b/include/configs/usb_a9263.h
@@ -55,7 +55,6 @@ 
 /* NAND flash */
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_BASE			ATMEL_BASE_CS3
 /* our ALE is AD21 */
 #define CONFIG_SYS_NAND_MASK_ALE		(1 << 21)
diff --git a/include/configs/ve8313.h b/include/configs/ve8313.h
index 94a59f3..9974d98 100644
--- a/include/configs/ve8313.h
+++ b/include/configs/ve8313.h
@@ -178,7 +178,6 @@ 
  * NAND settings
  */
 #define CONFIG_SYS_NAND_BASE		0x61000000
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_NAND_FSL_ELBC 1
 #define CONFIG_SYS_NAND_BLOCK_SIZE 16384
 
diff --git a/include/configs/vf610twr.h b/include/configs/vf610twr.h
index 63784e1..c5a0094 100644
--- a/include/configs/vf610twr.h
+++ b/include/configs/vf610twr.h
@@ -34,7 +34,6 @@ 
 #define CONFIG_SYS_NAND_ONFI_DETECTION
 
 #ifdef CONFIG_CMD_NAND
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		NFC_BASE_ADDR
 
 /* Dynamic MTD partition support */
diff --git a/include/configs/wb45n.h b/include/configs/wb45n.h
index 8989d55..8f1907e 100644
--- a/include/configs/wb45n.h
+++ b/include/configs/wb45n.h
@@ -47,7 +47,6 @@ 
 
 /* NAND flash */
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE  1
 #define CONFIG_SYS_NAND_BASE        0x40000000
 /* our ALE is AD21 */
 #define CONFIG_SYS_NAND_MASK_ALE    (1 << 21)
diff --git a/include/configs/wb50n.h b/include/configs/wb50n.h
index 4ab81c8..15e972b 100644
--- a/include/configs/wb50n.h
+++ b/include/configs/wb50n.h
@@ -62,7 +62,6 @@ 
 
 /* NAND flash */
 #define CONFIG_NAND_ATMEL
-#define CONFIG_SYS_MAX_NAND_DEVICE  1
 #define CONFIG_SYS_NAND_BASE        ATMEL_BASE_CS3
 /* our ALE is AD21 */
 #define CONFIG_SYS_NAND_MASK_ALE    (1 << 21)
diff --git a/include/configs/woodburn_common.h b/include/configs/woodburn_common.h
index 7ab60fd..39d9278 100644
--- a/include/configs/woodburn_common.h
+++ b/include/configs/woodburn_common.h
@@ -165,7 +165,6 @@ 
  */
 #define CONFIG_NAND_MXC_V1_1
 #define CONFIG_MXC_NAND_REGS_BASE	(NFC_BASE_ADDR)
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_BASE		(NFC_BASE_ADDR)
 #define CONFIG_MXC_NAND_HWECC
 #define CONFIG_SYS_NAND_LARGEPAGE
diff --git a/include/configs/work_92105.h b/include/configs/work_92105.h
index 7faab4e..52c6d2c 100644
--- a/include/configs/work_92105.h
+++ b/include/configs/work_92105.h
@@ -110,7 +110,6 @@ 
 
 /* driver configuration */
 #define CONFIG_SYS_NAND_SELF_INIT
-#define CONFIG_SYS_MAX_NAND_DEVICE 1
 #define CONFIG_SYS_MAX_NAND_CHIPS 1
 #define CONFIG_SYS_NAND_BASE MLC_NAND_BASE
 #define CONFIG_NAND_LPC32XX_MLC
diff --git a/include/configs/x600.h b/include/configs/x600.h
index 4aa5a2a..401db04 100644
--- a/include/configs/x600.h
+++ b/include/configs/x600.h
@@ -58,7 +58,6 @@ 
 /* NAND FLASH config options */
 #define CONFIG_NAND_FSMC
 #define CONFIG_SYS_NAND_SELF_INIT
-#define CONFIG_SYS_MAX_NAND_DEVICE		1
 #define CONFIG_SYS_NAND_BASE			CONFIG_FSMC_NAND_BASE
 #define CONFIG_MTD_ECC_SOFT
 #define CONFIG_SYS_FSMC_NAND_8BIT
diff --git a/include/configs/xilinx_zynqmp.h b/include/configs/xilinx_zynqmp.h
index 9997fd0..d8967da 100644
--- a/include/configs/xilinx_zynqmp.h
+++ b/include/configs/xilinx_zynqmp.h
@@ -75,7 +75,6 @@ 
 #endif
 
 #ifdef CONFIG_NAND_ARASAN
-# define CONFIG_SYS_MAX_NAND_DEVICE	1
 # define CONFIG_SYS_NAND_SELF_INIT
 # define CONFIG_SYS_NAND_ONFI_DETECTION
 # define CONFIG_MTD_DEVICE
diff --git a/include/configs/xpedite517x.h b/include/configs/xpedite517x.h
index f95d47a..a705808 100644
--- a/include/configs/xpedite517x.h
+++ b/include/configs/xpedite517x.h
@@ -111,7 +111,6 @@  extern unsigned long get_board_sys_clk(unsigned long dummy);
 #define CONFIG_SYS_NAND_BASE		0xef800000
 #define CONFIG_SYS_NAND_BASE2		0xef840000	/* Unused at this time */
 #define CONFIG_SYS_NAND_BASE_LIST 	{CONFIG_SYS_NAND_BASE, CONFIG_SYS_NAND_BASE2}
-#define CONFIG_SYS_MAX_NAND_DEVICE	2
 #define CONFIG_NAND_ACTL
 #define CONFIG_SYS_NAND_ACTL_ALE 	(1 << 14)	/* C_LA14 */
 #define CONFIG_SYS_NAND_ACTL_CLE 	(1 << 15)	/* C_LA15 */
diff --git a/include/configs/xpedite520x.h b/include/configs/xpedite520x.h
index c0df5ef..e156605 100644
--- a/include/configs/xpedite520x.h
+++ b/include/configs/xpedite520x.h
@@ -89,7 +89,6 @@ 
  */
 #define CONFIG_SYS_NAND_BASE		0xef800000
 #define CONFIG_SYS_NAND_BASE2		0xef840000 /* Unused at this time */
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_NAND_ACTL
 #define CONFIG_SYS_NAND_ACTL_CLE	(1 << 3)	/* ADDR3 is CLE */
 #define CONFIG_SYS_NAND_ACTL_ALE	(1 << 4)	/* ADDR4 is ALE */
diff --git a/include/configs/xpedite537x.h b/include/configs/xpedite537x.h
index b262237..e72fe4b 100644
--- a/include/configs/xpedite537x.h
+++ b/include/configs/xpedite537x.h
@@ -108,7 +108,6 @@  extern unsigned long get_board_ddr_clk(unsigned long dummy);
 #define CONFIG_SYS_NAND_BASE2		0xef840000 /* Unused at this time */
 #define CONFIG_SYS_NAND_BASE_LIST	{CONFIG_SYS_NAND_BASE, \
 					 CONFIG_SYS_NAND_BASE2}
-#define CONFIG_SYS_MAX_NAND_DEVICE	2
 #define CONFIG_NAND_FSL_ELBC
 
 /*
diff --git a/include/configs/xpedite550x.h b/include/configs/xpedite550x.h
index b5e8231..2833f2a 100644
--- a/include/configs/xpedite550x.h
+++ b/include/configs/xpedite550x.h
@@ -109,7 +109,6 @@  extern unsigned long get_board_ddr_clk(unsigned long dummy);
 #define CONFIG_SYS_NAND_BASE2		0xef840000 /* Unused at this time */
 #define CONFIG_SYS_NAND_BASE_LIST	{CONFIG_SYS_NAND_BASE, \
 					 CONFIG_SYS_NAND_BASE2}
-#define CONFIG_SYS_MAX_NAND_DEVICE	2
 #define CONFIG_NAND_FSL_ELBC
 
 /*
diff --git a/include/configs/zynq-common.h b/include/configs/zynq-common.h
index 28cee15..927e359 100644
--- a/include/configs/zynq-common.h
+++ b/include/configs/zynq-common.h
@@ -74,7 +74,6 @@ 
 #endif
 
 #ifdef CONFIG_NAND_ZYNQ
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
 #define CONFIG_SYS_NAND_ONFI_DETECTION
 #define CONFIG_MTD_DEVICE
 #endif
diff --git a/scripts/config_whitelist.txt b/scripts/config_whitelist.txt
index 6be4a76..e4a959b 100644
--- a/scripts/config_whitelist.txt
+++ b/scripts/config_whitelist.txt
@@ -3585,7 +3585,6 @@  CONFIG_SYS_MAX_FLASH_SECT
 CONFIG_SYS_MAX_I2C_BUS
 CONFIG_SYS_MAX_MTD_BANKS
 CONFIG_SYS_MAX_NAND_CHIPS
-CONFIG_SYS_MAX_NAND_DEVICE
 CONFIG_SYS_MAX_PCI_EPS
 CONFIG_SYS_MB862xx_CCF
 CONFIG_SYS_MB862xx_MMR