This converts the following to Kconfig: CONFIG_SYS_FLASH_CFI_WIDTH Signed-off-by: Tom Rini <tr...@konsulko.com> --- configs/M5208EVBE_defconfig | 1 + configs/M5235EVB_Flash32_defconfig | 1 + configs/M5235EVB_defconfig | 1 + configs/M5249EVB_defconfig | 1 + configs/M5272C3_defconfig | 1 + configs/M5282EVB_defconfig | 1 + configs/M53017EVB_defconfig | 1 + configs/M5329AFEE_defconfig | 1 + configs/M5329BFEE_defconfig | 1 + configs/M5373EVB_defconfig | 1 + configs/ae350_rv32_defconfig | 1 + configs/ae350_rv32_spl_defconfig | 1 + configs/ae350_rv32_spl_xip_defconfig | 1 + configs/ae350_rv32_xip_defconfig | 1 + configs/ae350_rv64_defconfig | 1 + configs/ae350_rv64_spl_defconfig | 1 + configs/ae350_rv64_spl_xip_defconfig | 1 + configs/ae350_rv64_xip_defconfig | 1 + configs/blanche_defconfig | 1 + configs/eb_cpu5282_defconfig | 1 + configs/eb_cpu5282_internal_defconfig | 1 + configs/kzm9g_defconfig | 1 + configs/mccmon6_nor_defconfig | 1 + configs/mccmon6_sd_defconfig | 1 + configs/omap35_logic_somlv_defconfig | 1 + configs/omap3_logic_somlv_defconfig | 1 + configs/r8a77990_ebisu_defconfig | 1 + configs/r8a77995_draak_defconfig | 1 + configs/rcar3_salvator-x_defconfig | 1 + configs/rcar3_ulcb_defconfig | 1 + configs/total_compute_defconfig | 1 + configs/vexpress_aemv8a_juno_defconfig | 1 + configs/vexpress_aemv8a_semi_defconfig | 1 + configs/xtfpga_defconfig | 1 + drivers/mtd/Kconfig | 29 ++++++++++++++++++++++++++ drivers/mtd/cfi_flash.c | 7 ------- include/configs/M5208EVBE.h | 1 - include/configs/M5235EVB.h | 5 ----- include/configs/M5249EVB.h | 1 - include/configs/M5253DEMO.h | 1 - include/configs/M5272C3.h | 1 - include/configs/M5282EVB.h | 1 - include/configs/M53017EVB.h | 1 - include/configs/M5329EVB.h | 1 - include/configs/M5373EVB.h | 1 - include/configs/am335x_evm.h | 1 - include/configs/armadillo-800eva.h | 1 - include/configs/ax25-ae350.h | 1 - include/configs/blanche.h | 1 - include/configs/dra7xx_evm.h | 1 - include/configs/draak.h | 1 - include/configs/eb_cpu5282.h | 1 - include/configs/ebisu.h | 1 - include/configs/ids8313.h | 1 - include/configs/kzm9g.h | 1 - include/configs/mccmon6.h | 1 - include/configs/mx6sabreauto.h | 1 - include/configs/octeon_ebb7304.h | 1 - include/configs/omap3_logic.h | 1 - include/configs/salvator-x.h | 1 - include/configs/total_compute.h | 2 -- include/configs/ulcb.h | 1 - include/configs/vexpress_aemv8.h | 2 -- include/configs/xtfpga.h | 1 - scripts/config_whitelist.txt | 1 - 65 files changed, 63 insertions(+), 42 deletions(-)
diff --git a/configs/M5208EVBE_defconfig b/configs/M5208EVBE_defconfig index 757792f9b0f4..4ab888f59ed5 100644 --- a/configs/M5208EVBE_defconfig +++ b/configs/M5208EVBE_defconfig @@ -34,6 +34,7 @@ CONFIG_SYS_I2C_SLAVE=0x7F CONFIG_SYS_I2C_SPEED=80000 CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_DM_ETH=y diff --git a/configs/M5235EVB_Flash32_defconfig b/configs/M5235EVB_Flash32_defconfig index 1ed127ca3c27..2a7996278418 100644 --- a/configs/M5235EVB_Flash32_defconfig +++ b/configs/M5235EVB_Flash32_defconfig @@ -41,6 +41,7 @@ CONFIG_SYS_I2C_SLAVE=0x7F CONFIG_SYS_I2C_SPEED=80000 CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_32BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_DM_ETH=y diff --git a/configs/M5235EVB_defconfig b/configs/M5235EVB_defconfig index fed386c164ad..5eeed2d2f313 100644 --- a/configs/M5235EVB_defconfig +++ b/configs/M5235EVB_defconfig @@ -41,6 +41,7 @@ CONFIG_SYS_I2C_SLAVE=0x7F CONFIG_SYS_I2C_SPEED=80000 CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_DM_ETH=y diff --git a/configs/M5249EVB_defconfig b/configs/M5249EVB_defconfig index 171df12564ff..f99375b535ed 100644 --- a/configs/M5249EVB_defconfig +++ b/configs/M5249EVB_defconfig @@ -25,6 +25,7 @@ CONFIG_SYS_RELOC_GD_ENV_ADDR=y # CONFIG_NET is not set CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_MCFUART=y diff --git a/configs/M5272C3_defconfig b/configs/M5272C3_defconfig index 376fb4253060..e3f736bf6308 100644 --- a/configs/M5272C3_defconfig +++ b/configs/M5272C3_defconfig @@ -54,6 +54,7 @@ CONFIG_SYS_BR7_PRELIM=0x701 CONFIG_SYS_OR7_PRELIM=0xFFC0007C CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_DM_ETH=y diff --git a/configs/M5282EVB_defconfig b/configs/M5282EVB_defconfig index 8f38710b0742..42940e1000a4 100644 --- a/configs/M5282EVB_defconfig +++ b/configs/M5282EVB_defconfig @@ -30,6 +30,7 @@ CONFIG_SYS_FAULT_ECHO_LINK_DOWN=y CONFIG_SYS_RX_ETH_BUFFER=8 CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_DM_ETH=y diff --git a/configs/M53017EVB_defconfig b/configs/M53017EVB_defconfig index 246bc8a3bed7..901a15d5061a 100644 --- a/configs/M53017EVB_defconfig +++ b/configs/M53017EVB_defconfig @@ -36,6 +36,7 @@ CONFIG_SYS_I2C_SLAVE=0x7F CONFIG_SYS_I2C_SPEED=80000 CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y diff --git a/configs/M5329AFEE_defconfig b/configs/M5329AFEE_defconfig index 3536b4432de4..0bce9d8f4229 100644 --- a/configs/M5329AFEE_defconfig +++ b/configs/M5329AFEE_defconfig @@ -36,6 +36,7 @@ CONFIG_SYS_I2C_SPEED=80000 CONFIG_MTD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_DM_ETH=y diff --git a/configs/M5329BFEE_defconfig b/configs/M5329BFEE_defconfig index a020775c87d0..efc7733b44c2 100644 --- a/configs/M5329BFEE_defconfig +++ b/configs/M5329BFEE_defconfig @@ -37,6 +37,7 @@ CONFIG_SYS_I2C_SPEED=80000 CONFIG_MTD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_MTD_RAW_NAND=y diff --git a/configs/M5373EVB_defconfig b/configs/M5373EVB_defconfig index b008b91fdd54..920a86fa9aa7 100644 --- a/configs/M5373EVB_defconfig +++ b/configs/M5373EVB_defconfig @@ -37,6 +37,7 @@ CONFIG_SYS_I2C_SPEED=80000 CONFIG_MTD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_MTD_RAW_NAND=y diff --git a/configs/ae350_rv32_defconfig b/configs/ae350_rv32_defconfig index 9c1fe5689644..340ec49c461e 100644 --- a/configs/ae350_rv32_defconfig +++ b/configs/ae350_rv32_defconfig @@ -29,6 +29,7 @@ CONFIG_FTSDC010=y CONFIG_FTSDC010_SDIO=y CONFIG_DM_MTD=y CONFIG_MTD_NOR_FLASH=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_CFI_FLASH=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_CFI=y diff --git a/configs/ae350_rv32_spl_defconfig b/configs/ae350_rv32_spl_defconfig index c79297169905..7a7fd416b04b 100644 --- a/configs/ae350_rv32_spl_defconfig +++ b/configs/ae350_rv32_spl_defconfig @@ -32,6 +32,7 @@ CONFIG_FTSDC010=y CONFIG_FTSDC010_SDIO=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_CFI=y CONFIG_SPI_FLASH_MACRONIX=y diff --git a/configs/ae350_rv32_spl_xip_defconfig b/configs/ae350_rv32_spl_xip_defconfig index e1400767d57d..9ba010a168c7 100644 --- a/configs/ae350_rv32_spl_xip_defconfig +++ b/configs/ae350_rv32_spl_xip_defconfig @@ -34,6 +34,7 @@ CONFIG_FTSDC010=y CONFIG_FTSDC010_SDIO=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_CFI=y CONFIG_SPI_FLASH_MACRONIX=y diff --git a/configs/ae350_rv32_xip_defconfig b/configs/ae350_rv32_xip_defconfig index 62fb51baad4c..16ff634d15a9 100644 --- a/configs/ae350_rv32_xip_defconfig +++ b/configs/ae350_rv32_xip_defconfig @@ -30,6 +30,7 @@ CONFIG_FTSDC010=y CONFIG_FTSDC010_SDIO=y CONFIG_DM_MTD=y CONFIG_MTD_NOR_FLASH=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_CFI_FLASH=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_CFI=y diff --git a/configs/ae350_rv64_defconfig b/configs/ae350_rv64_defconfig index 681c40fd770e..ba525c98c2ae 100644 --- a/configs/ae350_rv64_defconfig +++ b/configs/ae350_rv64_defconfig @@ -30,6 +30,7 @@ CONFIG_FTSDC010=y CONFIG_FTSDC010_SDIO=y CONFIG_DM_MTD=y CONFIG_MTD_NOR_FLASH=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_CFI_FLASH=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_CFI=y diff --git a/configs/ae350_rv64_spl_defconfig b/configs/ae350_rv64_spl_defconfig index 210bf22a0485..9e9f85a18699 100644 --- a/configs/ae350_rv64_spl_defconfig +++ b/configs/ae350_rv64_spl_defconfig @@ -33,6 +33,7 @@ CONFIG_FTSDC010=y CONFIG_FTSDC010_SDIO=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_CFI=y CONFIG_SPI_FLASH_MACRONIX=y diff --git a/configs/ae350_rv64_spl_xip_defconfig b/configs/ae350_rv64_spl_xip_defconfig index c6a6c79e394e..c1a6d89ae7ca 100644 --- a/configs/ae350_rv64_spl_xip_defconfig +++ b/configs/ae350_rv64_spl_xip_defconfig @@ -35,6 +35,7 @@ CONFIG_FTSDC010=y CONFIG_FTSDC010_SDIO=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_CFI=y CONFIG_SPI_FLASH_MACRONIX=y diff --git a/configs/ae350_rv64_xip_defconfig b/configs/ae350_rv64_xip_defconfig index b5bdf94dafb7..49511ab15493 100644 --- a/configs/ae350_rv64_xip_defconfig +++ b/configs/ae350_rv64_xip_defconfig @@ -31,6 +31,7 @@ CONFIG_FTSDC010=y CONFIG_FTSDC010_SDIO=y CONFIG_DM_MTD=y CONFIG_MTD_NOR_FLASH=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_CFI_FLASH=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_CFI=y diff --git a/configs/blanche_defconfig b/configs/blanche_defconfig index 01e9ea372225..f4bb406be3cc 100644 --- a/configs/blanche_defconfig +++ b/configs/blanche_defconfig @@ -55,6 +55,7 @@ CONFIG_RENESAS_SDHI=y CONFIG_MTD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS=y CONFIG_SYS_FLASH_CFI=y CONFIG_DM_SPI_FLASH=y diff --git a/configs/eb_cpu5282_defconfig b/configs/eb_cpu5282_defconfig index d634280de5d3..4cf03abc61e4 100644 --- a/configs/eb_cpu5282_defconfig +++ b/configs/eb_cpu5282_defconfig @@ -45,6 +45,7 @@ CONFIG_LED_STATUS_BOOT=0 CONFIG_LED_STATUS_CMD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_DM_ETH=y diff --git a/configs/eb_cpu5282_internal_defconfig b/configs/eb_cpu5282_internal_defconfig index a726fdb56e37..117851584693 100644 --- a/configs/eb_cpu5282_internal_defconfig +++ b/configs/eb_cpu5282_internal_defconfig @@ -43,6 +43,7 @@ CONFIG_LED_STATUS_BOOT=0 CONFIG_LED_STATUS_CMD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_DM_ETH=y diff --git a/configs/kzm9g_defconfig b/configs/kzm9g_defconfig index 779f0d9ed89b..9a944cad39c2 100644 --- a/configs/kzm9g_defconfig +++ b/configs/kzm9g_defconfig @@ -36,6 +36,7 @@ CONFIG_SYS_I2C_SH=y CONFIG_MTD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_CFI=y CONFIG_SMC911X=y CONFIG_SMC911X_BASE=0x10000000 diff --git a/configs/mccmon6_nor_defconfig b/configs/mccmon6_nor_defconfig index e837b391ebc1..3718d08b6700 100644 --- a/configs/mccmon6_nor_defconfig +++ b/configs/mccmon6_nor_defconfig @@ -60,6 +60,7 @@ CONFIG_MTD=y CONFIG_DM_MTD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_FLASH_CFI_MTD=y CONFIG_SYS_FLASH_PROTECTION=y diff --git a/configs/mccmon6_sd_defconfig b/configs/mccmon6_sd_defconfig index 0f17ccdc85de..3228050dd206 100644 --- a/configs/mccmon6_sd_defconfig +++ b/configs/mccmon6_sd_defconfig @@ -58,6 +58,7 @@ CONFIG_MTD=y CONFIG_DM_MTD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_FLASH_CFI_MTD=y CONFIG_SYS_FLASH_PROTECTION=y diff --git a/configs/omap35_logic_somlv_defconfig b/configs/omap35_logic_somlv_defconfig index 5db671d694ea..ffb0e28569ae 100644 --- a/configs/omap35_logic_somlv_defconfig +++ b/configs/omap35_logic_somlv_defconfig @@ -62,6 +62,7 @@ CONFIG_MMC_OMAP_HS=y CONFIG_MTD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_FLASH_CFI_MTD=y CONFIG_SYS_FLASH_PROTECTION=y diff --git a/configs/omap3_logic_somlv_defconfig b/configs/omap3_logic_somlv_defconfig index 2c5d60d164ae..b49734666d77 100644 --- a/configs/omap3_logic_somlv_defconfig +++ b/configs/omap3_logic_somlv_defconfig @@ -63,6 +63,7 @@ CONFIG_MMC_OMAP36XX_PINS=y CONFIG_MTD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_FLASH_CFI_MTD=y CONFIG_SYS_FLASH_PROTECTION=y diff --git a/configs/r8a77990_ebisu_defconfig b/configs/r8a77990_ebisu_defconfig index 7ba55737d841..3fd65e97c44b 100644 --- a/configs/r8a77990_ebisu_defconfig +++ b/configs/r8a77990_ebisu_defconfig @@ -72,6 +72,7 @@ CONFIG_RENESAS_SDHI=y CONFIG_MTD=y CONFIG_DM_MTD=y CONFIG_MTD_NOR_FLASH=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_CFI_FLASH=y CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS=y CONFIG_FLASH_CFI_MTD=y diff --git a/configs/r8a77995_draak_defconfig b/configs/r8a77995_draak_defconfig index e2a7e5f636dd..ee0f61513175 100644 --- a/configs/r8a77995_draak_defconfig +++ b/configs/r8a77995_draak_defconfig @@ -66,6 +66,7 @@ CONFIG_RENESAS_SDHI=y CONFIG_MTD=y CONFIG_DM_MTD=y CONFIG_MTD_NOR_FLASH=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_CFI_FLASH=y CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS=y CONFIG_FLASH_CFI_MTD=y diff --git a/configs/rcar3_salvator-x_defconfig b/configs/rcar3_salvator-x_defconfig index 7bcbb3a13394..7263b32101d0 100644 --- a/configs/rcar3_salvator-x_defconfig +++ b/configs/rcar3_salvator-x_defconfig @@ -75,6 +75,7 @@ CONFIG_RENESAS_SDHI=y CONFIG_MTD=y CONFIG_DM_MTD=y CONFIG_MTD_NOR_FLASH=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_CFI_FLASH=y CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS=y CONFIG_FLASH_CFI_MTD=y diff --git a/configs/rcar3_ulcb_defconfig b/configs/rcar3_ulcb_defconfig index c953299c0d0f..052465c8d7a9 100644 --- a/configs/rcar3_ulcb_defconfig +++ b/configs/rcar3_ulcb_defconfig @@ -74,6 +74,7 @@ CONFIG_RENESAS_SDHI=y CONFIG_MTD=y CONFIG_DM_MTD=y CONFIG_MTD_NOR_FLASH=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_CFI_FLASH=y CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS=y CONFIG_FLASH_CFI_MTD=y diff --git a/configs/total_compute_defconfig b/configs/total_compute_defconfig index 1a674de8157c..e0f76b711b3c 100644 --- a/configs/total_compute_defconfig +++ b/configs/total_compute_defconfig @@ -49,6 +49,7 @@ CONFIG_ARM_PL180_MMCI=y CONFIG_MTD=y CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_32BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y diff --git a/configs/vexpress_aemv8a_juno_defconfig b/configs/vexpress_aemv8a_juno_defconfig index 688cecb7632c..fdfcf3b49606 100644 --- a/configs/vexpress_aemv8a_juno_defconfig +++ b/configs/vexpress_aemv8a_juno_defconfig @@ -26,6 +26,7 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_UBI=y # CONFIG_MMC is not set CONFIG_MTD=y +CONFIG_SYS_FLASH_CFI_WIDTH_32BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y diff --git a/configs/vexpress_aemv8a_semi_defconfig b/configs/vexpress_aemv8a_semi_defconfig index 95412d24eea3..0ae8ae10a310 100644 --- a/configs/vexpress_aemv8a_semi_defconfig +++ b/configs/vexpress_aemv8a_semi_defconfig @@ -25,6 +25,7 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_UBI=y # CONFIG_MMC is not set CONFIG_MTD=y +CONFIG_SYS_FLASH_CFI_WIDTH_32BIT=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y diff --git a/configs/xtfpga_defconfig b/configs/xtfpga_defconfig index e98af5ec7e63..eab40fc0d133 100644 --- a/configs/xtfpga_defconfig +++ b/configs/xtfpga_defconfig @@ -38,6 +38,7 @@ CONFIG_DM=y # CONFIG_DM_SEQ_ALIAS is not set CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y +CONFIG_SYS_FLASH_CFI_WIDTH_16BIT=y CONFIG_SYS_FLASH_PROTECTION=y CONFIG_SYS_FLASH_CFI=y CONFIG_PHYLIB=y diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig index 4088267dd111..c3f5455347ed 100644 --- a/drivers/mtd/Kconfig +++ b/drivers/mtd/Kconfig @@ -48,6 +48,35 @@ config FLASH_CFI_DRIVER option. Visit <http://www.amd.com/products/nvd/overview/cfi.html> for more information on CFI. +choice + prompt "Data-width of the flash device" + depends on FLASH_CFI_DRIVER + default SYS_FLASH_CFI_WIDTH_8BIT + +config SYS_FLASH_CFI_WIDTH_8BIT + bool "Data-width of the device is 8-bit" + +config SYS_FLASH_CFI_WIDTH_16BIT + bool "Data-width of the device is 16-bit" + +config SYS_FLASH_CFI_WIDTH_32BIT + bool "Data-width of the device is 32-bit" + +config SYS_FLASH_CFI_WIDTH_64BIT + bool "Data-width of the device is 64-bit" + +endchoice + +config SYS_FLASH_CFI_WIDTH + hex + depends on FLASH_CFI_DRIVER + default 0x1 if SYS_FLASH_CFI_WIDTH_8BIT + default 0x2 if SYS_FLASH_CFI_WIDTH_16BIT + default 0x4 if SYS_FLASH_CFI_WIDTH_32BIT + default 0x8 if SYS_FLASH_CFI_WIDTH_64BIT + help + This must be kept in sync with the table in include/flash.h + config CFI_FLASH bool "Enable Driver Model for CFI Flash driver" depends on DM_MTD diff --git a/drivers/mtd/cfi_flash.c b/drivers/mtd/cfi_flash.c index aae3ea0d1b45..495041070650 100644 --- a/drivers/mtd/cfi_flash.c +++ b/drivers/mtd/cfi_flash.c @@ -68,13 +68,6 @@ static uint flash_verbose = 1; flash_info_t flash_info[CFI_MAX_FLASH_BANKS]; /* FLASH chips info */ -/* - * Check if chip width is defined. If not, start detecting with 8bit. - */ -#ifndef CONFIG_SYS_FLASH_CFI_WIDTH -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_8BIT -#endif - #ifdef CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS #define __maybe_weak __weak #else diff --git a/include/configs/M5208EVBE.h b/include/configs/M5208EVBE.h index 135dec0ebb4d..4ca71ad41ba2 100644 --- a/include/configs/M5208EVBE.h +++ b/include/configs/M5208EVBE.h @@ -94,7 +94,6 @@ /* FLASH organization */ #ifdef CONFIG_SYS_FLASH_CFI # define CONFIG_SYS_FLASH_SIZE 0x800000 /* Max size that the board might have */ -# define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT # define CONFIG_SYS_MAX_FLASH_SECT 254 /* max number of sectors on one chip */ #endif diff --git a/include/configs/M5235EVB.h b/include/configs/M5235EVB.h index 88f5f155633c..68b695c6fbbd 100644 --- a/include/configs/M5235EVB.h +++ b/include/configs/M5235EVB.h @@ -102,11 +102,6 @@ */ #ifdef CONFIG_SYS_FLASH_CFI # define CONFIG_SYS_FLASH_SIZE 0x800000 /* Max size that the board might have */ -#ifdef CONFIG_NORFLASH_PS32BIT -# define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_32BIT -#else -# define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT -#endif # define CONFIG_SYS_MAX_FLASH_SECT 137 /* max number of sectors on one chip */ #endif diff --git a/include/configs/M5249EVB.h b/include/configs/M5249EVB.h index 1a604f5c81ea..64eae702160f 100644 --- a/include/configs/M5249EVB.h +++ b/include/configs/M5249EVB.h @@ -79,7 +79,6 @@ #ifdef CONFIG_SYS_FLASH_CFI # define CONFIG_SYS_FLASH_SIZE 0x1000000 /* Max size that the board might have */ -# define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT # define CONFIG_SYS_MAX_FLASH_SECT 137 /* max number of sectors on one chip */ # define CONFIG_SYS_FLASH_CHECKSUM # define CONFIG_SYS_FLASH_BANKS_LIST { CONFIG_SYS_FLASH_BASE } diff --git a/include/configs/M5253DEMO.h b/include/configs/M5253DEMO.h index 0a416dc12266..e81768441ec4 100644 --- a/include/configs/M5253DEMO.h +++ b/include/configs/M5253DEMO.h @@ -115,7 +115,6 @@ * 0x30 is block erase in SST */ # define CONFIG_SYS_FLASH_SIZE 0x800000 -# define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT # define CONFIG_FLASH_CFI_LEGACY #else # define CONFIG_SYS_SST_SECT 2048 diff --git a/include/configs/M5272C3.h b/include/configs/M5272C3.h index 6b4028c17ca2..bd4c531751e2 100644 --- a/include/configs/M5272C3.h +++ b/include/configs/M5272C3.h @@ -102,7 +102,6 @@ */ #ifdef CONFIG_SYS_FLASH_CFI # define CONFIG_SYS_FLASH_SIZE 0x800000 /* Max size that the board might have */ -# define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT # define CONFIG_SYS_MAX_FLASH_SECT 137 /* max number of sectors on one chip */ #endif diff --git a/include/configs/M5282EVB.h b/include/configs/M5282EVB.h index fe04a70b61e9..c0358ccc5269 100644 --- a/include/configs/M5282EVB.h +++ b/include/configs/M5282EVB.h @@ -106,7 +106,6 @@ #ifdef CONFIG_SYS_FLASH_CFI # define CONFIG_SYS_FLASH_SIZE 0x1000000 /* Max size that the board might have */ -# define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT # define CONFIG_SYS_MAX_FLASH_SECT 137 /* max number of sectors on one chip */ # define CONFIG_SYS_FLASH_CHECKSUM # define CONFIG_SYS_FLASH_BANKS_LIST { CONFIG_SYS_FLASH_BASE } diff --git a/include/configs/M53017EVB.h b/include/configs/M53017EVB.h index 9b84d3693a31..15173d49b000 100644 --- a/include/configs/M53017EVB.h +++ b/include/configs/M53017EVB.h @@ -111,7 +111,6 @@ #ifdef CONFIG_SYS_FLASH_CFI # define CONFIG_FLASH_SPANSION_S29WS_N 1 # define CONFIG_SYS_FLASH_SIZE 0x1000000 /* Max size that the board might have */ -# define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT # define CONFIG_SYS_MAX_FLASH_SECT 137 /* max number of sectors on one chip */ #endif diff --git a/include/configs/M5329EVB.h b/include/configs/M5329EVB.h index 7e65f9914f4d..06c023b3ad6a 100644 --- a/include/configs/M5329EVB.h +++ b/include/configs/M5329EVB.h @@ -106,7 +106,6 @@ */ #ifdef CONFIG_SYS_FLASH_CFI # define CONFIG_SYS_FLASH_SIZE 0x800000 /* Max size that the board might have */ -# define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT # define CONFIG_SYS_MAX_FLASH_SECT 137 /* max number of sectors on one chip */ #endif diff --git a/include/configs/M5373EVB.h b/include/configs/M5373EVB.h index b131aefd6dd1..6b2d60fac846 100644 --- a/include/configs/M5373EVB.h +++ b/include/configs/M5373EVB.h @@ -108,7 +108,6 @@ */ #ifdef CONFIG_SYS_FLASH_CFI # define CONFIG_SYS_FLASH_SIZE 0x800000 /* Max size that the board might have */ -# define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT # define CONFIG_SYS_MAX_FLASH_SECT 137 /* max number of sectors on one chip */ #endif diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h index fd5b209a52db..78b359dcea93 100644 --- a/include/configs/am335x_evm.h +++ b/include/configs/am335x_evm.h @@ -241,7 +241,6 @@ #if defined(CONFIG_NOR) #define CONFIG_SYS_MAX_FLASH_SECT 128 #define CONFIG_SYS_FLASH_BASE (0x08000000) -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_FLASH_SIZE 0x01000000 #endif /* NOR support */ diff --git a/include/configs/armadillo-800eva.h b/include/configs/armadillo-800eva.h index 44af5b44badf..e7d685a657e3 100644 --- a/include/configs/armadillo-800eva.h +++ b/include/configs/armadillo-800eva.h @@ -47,7 +47,6 @@ #define CONFIG_SYS_BOOTMAPSZ (8 * 1024 * 1024) /* FLASH */ -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_FLASH_BASE 0x00000000 #define CONFIG_SYS_MAX_FLASH_SECT 512 #define CONFIG_SYS_FLASH_BANKS_LIST { (CONFIG_SYS_FLASH_BASE) } diff --git a/include/configs/ax25-ae350.h b/include/configs/ax25-ae350.h index 633be8f61414..03fe9469bf1a 100644 --- a/include/configs/ax25-ae350.h +++ b/include/configs/ax25-ae350.h @@ -58,7 +58,6 @@ /* use CFI framework */ -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_CFI_FLASH_STATUS_POLL /* support JEDEC */ diff --git a/include/configs/blanche.h b/include/configs/blanche.h index 4f8da5940431..d0f37b6cc20c 100644 --- a/include/configs/blanche.h +++ b/include/configs/blanche.h @@ -28,7 +28,6 @@ #if !defined(CONFIG_MTD_NOR_FLASH) #define CONFIG_SH_QSPI_BASE 0xE6B10000 #else -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_FLASH_SHOW_PROGRESS 45 #define CONFIG_SYS_FLASH_BASE 0x00000000 #define CONFIG_SYS_FLASH_SIZE 0x04000000 /* 64 MB */ diff --git a/include/configs/dra7xx_evm.h b/include/configs/dra7xx_evm.h index e16af8824b40..9f685b198791 100644 --- a/include/configs/dra7xx_evm.h +++ b/include/configs/dra7xx_evm.h @@ -95,7 +95,6 @@ #if defined(CONFIG_NOR) /* NOR: device related configs */ #define CONFIG_SYS_MAX_FLASH_SECT 512 -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_FLASH_SIZE (64 * 1024 * 1024) /* 64 MB */ #define CONFIG_SYS_FLASH_BASE (0x08000000) /* Reduce SPL size by removing unlikey targets */ diff --git a/include/configs/draak.h b/include/configs/draak.h index 476b4c3710a2..a38e48634835 100644 --- a/include/configs/draak.h +++ b/include/configs/draak.h @@ -15,7 +15,6 @@ #define CONFIG_FLASH_SHOW_PROGRESS 45 #define CONFIG_SYS_FLASH_BANKS_LIST { 0x08000000 } -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_MAX_FLASH_SECT 256 #define CONFIG_SYS_WRITE_SWAPPED_DATA diff --git a/include/configs/eb_cpu5282.h b/include/configs/eb_cpu5282.h index 70ee288aa72e..cbc29ddb5180 100644 --- a/include/configs/eb_cpu5282.h +++ b/include/configs/eb_cpu5282.h @@ -102,7 +102,6 @@ #define CONFIG_SYS_FLASH_ERASE_TOUT 10000000 #define CONFIG_SYS_FLASH_SIZE 16*1024*1024 -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_FLASH_BANKS_LIST { CONFIG_SYS_FLASH_BASE } diff --git a/include/configs/ebisu.h b/include/configs/ebisu.h index 3adc4180efd9..3dc111f5248d 100644 --- a/include/configs/ebisu.h +++ b/include/configs/ebisu.h @@ -18,7 +18,6 @@ #define CONFIG_FLASH_SHOW_PROGRESS 45 #define CONFIG_SYS_FLASH_QUIET_TEST #define CONFIG_SYS_FLASH_BANKS_LIST { 0x08000000 } -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_MAX_FLASH_SECT 256 #define CONFIG_SYS_WRITE_SWAPPED_DATA diff --git a/include/configs/ids8313.h b/include/configs/ids8313.h index 3fd441e30ba0..d5c9489bce6e 100644 --- a/include/configs/ids8313.h +++ b/include/configs/ids8313.h @@ -108,7 +108,6 @@ /* * NOR FLASH setup */ -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_8BIT #define CONFIG_FLASH_SHOW_PROGRESS 50 #define CONFIG_SYS_FLASH_BASE 0xFF800000 diff --git a/include/configs/kzm9g.h b/include/configs/kzm9g.h index 2ea8b82dd092..442505adaa14 100644 --- a/include/configs/kzm9g.h +++ b/include/configs/kzm9g.h @@ -19,7 +19,6 @@ /* NOR Flash */ #define KZM_FLASH_BASE (0x00000000) #define CONFIG_SYS_FLASH_BASE (KZM_FLASH_BASE) -#define CONFIG_SYS_FLASH_CFI_WIDTH (FLASH_CFI_16BIT) #define CONFIG_SYS_MAX_FLASH_SECT (512) /* prompt */ diff --git a/include/configs/mccmon6.h b/include/configs/mccmon6.h index dcce52eb7d37..f24a00724173 100644 --- a/include/configs/mccmon6.h +++ b/include/configs/mccmon6.h @@ -31,7 +31,6 @@ /* NOR 16-bit mode */ #define CONFIG_SYS_FLASH_BASE WEIM_ARB_BASE_ADDR -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_FLASH_EMPTY_INFO #define CONFIG_FLASH_VERIFY diff --git a/include/configs/mx6sabreauto.h b/include/configs/mx6sabreauto.h index a212652fd7f0..4537fce19deb 100644 --- a/include/configs/mx6sabreauto.h +++ b/include/configs/mx6sabreauto.h @@ -42,7 +42,6 @@ #define CONFIG_SYS_FLASH_SECT_SIZE (128 * 1024) #define CONFIG_SYS_MAX_FLASH_SECT 256 /* max number of sectors on one chip */ #define CONFIG_SYS_FLASH_EMPTY_INFO -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #endif #define CONFIG_SYS_FSL_USDHC_NUM 2 diff --git a/include/configs/octeon_ebb7304.h b/include/configs/octeon_ebb7304.h index 8c6c57bd546a..7035e6313420 100644 --- a/include/configs/octeon_ebb7304.h +++ b/include/configs/octeon_ebb7304.h @@ -13,7 +13,6 @@ * CFI flash */ #define CONFIG_SYS_MAX_FLASH_SECT 256 -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_8BIT #define CONFIG_SYS_FLASH_EMPTY_INFO /* flinfo indicates empty blocks */ #define PHY_ANEG_TIMEOUT 8000 /* PHY needs a longer aneg time */ diff --git a/include/configs/omap3_logic.h b/include/configs/omap3_logic.h index d3839eb12293..4112e5570f6a 100644 --- a/include/configs/omap3_logic.h +++ b/include/configs/omap3_logic.h @@ -154,7 +154,6 @@ #endif #define CONFIG_SYS_MAX_FLASH_SECT 256 -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_FLASH_SIZE 0x4000000 #define CONFIG_SYS_ENV_SECT_SIZE (128 << 10) /* 128 KiB */ diff --git a/include/configs/salvator-x.h b/include/configs/salvator-x.h index eb00e2b004bc..4b0f20e89b7c 100644 --- a/include/configs/salvator-x.h +++ b/include/configs/salvator-x.h @@ -16,7 +16,6 @@ #define CONFIG_FLASH_SHOW_PROGRESS 45 #define CONFIG_SYS_FLASH_QUIET_TEST #define CONFIG_SYS_FLASH_BANKS_LIST { 0x08000000 } -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_MAX_FLASH_SECT 256 #define CONFIG_SYS_WRITE_SWAPPED_DATA diff --git a/include/configs/total_compute.h b/include/configs/total_compute.h index 7ab792613612..c0495b7e153a 100644 --- a/include/configs/total_compute.h +++ b/include/configs/total_compute.h @@ -50,8 +50,6 @@ /* 256 x 256KiB sectors */ #define CONFIG_SYS_MAX_FLASH_SECT 256 -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_32BIT - #define CONFIG_SYS_FLASH_EMPTY_INFO /* flinfo indicates empty blocks */ #define FLASH_MAX_SECTOR_SIZE 0x00040000 diff --git a/include/configs/ulcb.h b/include/configs/ulcb.h index 14ea40bee3ed..578873295fb9 100644 --- a/include/configs/ulcb.h +++ b/include/configs/ulcb.h @@ -16,7 +16,6 @@ #define CONFIG_FLASH_SHOW_PROGRESS 45 #define CONFIG_SYS_FLASH_QUIET_TEST #define CONFIG_SYS_FLASH_BANKS_LIST { 0x08000000 } -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_MAX_FLASH_SECT 256 #define CONFIG_SYS_WRITE_SWAPPED_DATA diff --git a/include/configs/vexpress_aemv8.h b/include/configs/vexpress_aemv8.h index df76b9a5612f..904ed8df0be8 100644 --- a/include/configs/vexpress_aemv8.h +++ b/include/configs/vexpress_aemv8.h @@ -276,8 +276,6 @@ /* Store environment at top of flash */ #endif -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_32BIT - #ifdef CONFIG_USB_EHCI_HCD #define CONFIG_USB_OHCI_NEW #define CONFIG_SYS_USB_OHCI_MAX_ROOT_PORTS 1 diff --git a/include/configs/xtfpga.h b/include/configs/xtfpga.h index 215b7592d2ae..7392582b5e46 100644 --- a/include/configs/xtfpga.h +++ b/include/configs/xtfpga.h @@ -170,7 +170,6 @@ /* Flash & Environment */ /*=====================*/ -#define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #ifdef CONFIG_XTFPGA_LX60 # define CONFIG_SYS_FLASH_SIZE 0x0040000 /* 4MB */ # define CONFIG_SYS_FLASH_SECT_SZ 0x10000 /* block size 64KB */ diff --git a/scripts/config_whitelist.txt b/scripts/config_whitelist.txt index 06a76b6398ce..0cfb3ba4482c 100644 --- a/scripts/config_whitelist.txt +++ b/scripts/config_whitelist.txt @@ -887,7 +887,6 @@ CONFIG_SYS_FLASH_BASE_PHYS CONFIG_SYS_FLASH_BASE_PHYS_EARLY CONFIG_SYS_FLASH_BR_PRELIM CONFIG_SYS_FLASH_CFI_NONBLOCK -CONFIG_SYS_FLASH_CFI_WIDTH CONFIG_SYS_FLASH_CHECKSUM CONFIG_SYS_FLASH_EMPTY_INFO CONFIG_SYS_FLASH_ERASE_TOUT -- 2.25.1