From: Patrick Delaunay Date: Wed, 27 Feb 2019 14:20:38 +0000 (+0100) Subject: Convert CONFIG_ENV_SPI_* to Kconfig X-Git-Url: http://git.dujemihanovic.xyz/%22/img/sics.gif/%22/static/git-favicon.png?a=commitdiff_plain;h=abe66b1b5decf9cc2fb5daad42c9e870e5b99b67;p=u-boot.git Convert CONFIG_ENV_SPI_* to Kconfig This converts the following to Kconfig: CONFIG_ENV_SPI_BUS CONFIG_ENV_SPI_CS CONFIG_ENV_SPI_MAX_HZ CONFIG_ENV_SPI_MODE Most of time these value are not needed, CONFIG_SF_DEFAULT with same value is used, so I introduced CONFIG_USE_ENV_SPI_* to force the associated value for the environment. Signed-off-by: Patrick Delaunay --- diff --git a/arch/arm/mach-kirkwood/include/mach/config.h b/arch/arm/mach-kirkwood/include/mach/config.h index aea60688c2..893bd3f763 100644 --- a/arch/arm/mach-kirkwood/include/mach/config.h +++ b/arch/arm/mach-kirkwood/include/mach/config.h @@ -60,21 +60,6 @@ #define NAND_ALLOW_ERASE_ALL 1 #endif -/* - * SPI Flash configuration - */ -#ifdef CONFIG_CMD_SF -#ifndef CONFIG_ENV_SPI_BUS -# define CONFIG_ENV_SPI_BUS 0 -#endif -#ifndef CONFIG_ENV_SPI_CS -# define CONFIG_ENV_SPI_CS 0 -#endif -#ifndef CONFIG_ENV_SPI_MAX_HZ -# define CONFIG_ENV_SPI_MAX_HZ 50000000 -#endif -#endif - /* * Ethernet Driver configuration */ diff --git a/arch/arm/mach-mvebu/include/mach/config.h b/arch/arm/mach-mvebu/include/mach/config.h index e3235fc67e..71c4f70efc 100644 --- a/arch/arm/mach-mvebu/include/mach/config.h +++ b/arch/arm/mach-mvebu/include/mach/config.h @@ -45,21 +45,6 @@ #define MV_UART_CONSOLE_BASE MVEBU_UART0_BASE -/* - * SPI Flash configuration - */ -#ifdef CONFIG_CMD_SF -#ifndef CONFIG_ENV_SPI_BUS -# define CONFIG_ENV_SPI_BUS 0 -#endif -#ifndef CONFIG_ENV_SPI_CS -# define CONFIG_ENV_SPI_CS 0 -#endif -#ifndef CONFIG_ENV_SPI_MAX_HZ -# define CONFIG_ENV_SPI_MAX_HZ 50000000 -#endif -#endif - /* Needed for SPI NOR booting in SPL */ #define CONFIG_DM_SEQ_ALIAS 1 diff --git a/configs/M52277EVB_stmicro_defconfig b/configs/M52277EVB_stmicro_defconfig index 3628729a48..cafc861167 100644 --- a/configs/M52277EVB_stmicro_defconfig +++ b/configs/M52277EVB_stmicro_defconfig @@ -15,6 +15,8 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_DATE=y CONFIG_CMD_JFFS2=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_CS=y +CONFIG_ENV_SPI_CS=2 # CONFIG_NET is not set CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y diff --git a/configs/M54418TWR_defconfig b/configs/M54418TWR_defconfig index f69f405d5a..a239f4a02f 100644 --- a/configs/M54418TWR_defconfig +++ b/configs/M54418TWR_defconfig @@ -20,6 +20,8 @@ CONFIG_CMD_MII=y CONFIG_CMD_PING=y CONFIG_CMD_CACHE=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_CS=y +CONFIG_ENV_SPI_CS=1 CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_ATMEL=y CONFIG_MII=y diff --git a/configs/M54418TWR_serial_mii_defconfig b/configs/M54418TWR_serial_mii_defconfig index b2266a0577..8b72bd35d3 100644 --- a/configs/M54418TWR_serial_mii_defconfig +++ b/configs/M54418TWR_serial_mii_defconfig @@ -20,6 +20,8 @@ CONFIG_CMD_MII=y CONFIG_CMD_PING=y CONFIG_CMD_CACHE=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_CS=y +CONFIG_ENV_SPI_CS=1 CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_ATMEL=y CONFIG_MII=y diff --git a/configs/M54418TWR_serial_rmii_defconfig b/configs/M54418TWR_serial_rmii_defconfig index f69f405d5a..a239f4a02f 100644 --- a/configs/M54418TWR_serial_rmii_defconfig +++ b/configs/M54418TWR_serial_rmii_defconfig @@ -20,6 +20,8 @@ CONFIG_CMD_MII=y CONFIG_CMD_PING=y CONFIG_CMD_CACHE=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_CS=y +CONFIG_ENV_SPI_CS=1 CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_ATMEL=y CONFIG_MII=y diff --git a/configs/M54451EVB_stmicro_defconfig b/configs/M54451EVB_stmicro_defconfig index ce5f65666c..b614ca716d 100644 --- a/configs/M54451EVB_stmicro_defconfig +++ b/configs/M54451EVB_stmicro_defconfig @@ -20,6 +20,8 @@ CONFIG_CMD_PING=y CONFIG_CMD_CACHE=y CONFIG_CMD_DATE=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_CS=y +CONFIG_ENV_SPI_CS=1 CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y diff --git a/configs/M54455EVB_stm33_defconfig b/configs/M54455EVB_stm33_defconfig index fc19de50d1..467bfaee9a 100644 --- a/configs/M54455EVB_stm33_defconfig +++ b/configs/M54455EVB_stm33_defconfig @@ -25,6 +25,8 @@ CONFIG_CMD_FAT=y CONFIG_CMD_JFFS2=y CONFIG_ISO_PARTITION=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_CS=y +CONFIG_ENV_SPI_CS=1 CONFIG_MTD_NOR_FLASH=y CONFIG_FLASH_CFI_DRIVER=y CONFIG_SYS_FLASH_USE_BUFFER_WRITE=y diff --git a/configs/SBx81LIFKW_defconfig b/configs/SBx81LIFKW_defconfig index e0ce1595c5..afda7eda59 100644 --- a/configs/SBx81LIFKW_defconfig +++ b/configs/SBx81LIFKW_defconfig @@ -20,6 +20,8 @@ CONFIG_CMD_SNTP=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-atl-sbx81lifkw" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=20000000 CONFIG_DM=y CONFIG_DM_GPIO=y CONFIG_DM_PCA953X=y diff --git a/configs/SBx81LIFXCAT_defconfig b/configs/SBx81LIFXCAT_defconfig index 4a6e05844f..4cb4797a11 100644 --- a/configs/SBx81LIFXCAT_defconfig +++ b/configs/SBx81LIFXCAT_defconfig @@ -22,6 +22,8 @@ CONFIG_CMD_SNTP=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-atl-sbx81lifxcat" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=20000000 CONFIG_DM=y CONFIG_DM_GPIO=y CONFIG_DM_PCA953X=y diff --git a/configs/ap121_defconfig b/configs/ap121_defconfig index c9dbe4d721..eca24e9d25 100644 --- a/configs/ap121_defconfig +++ b/configs/ap121_defconfig @@ -32,6 +32,8 @@ CONFIG_MTDPARTS_DEFAULT="mtdparts=spi-flash.0:256k(u-boot),64k(u-boot-env),6144k # CONFIG_ISO_PARTITION is not set CONFIG_DEFAULT_DEVICE_TREE="ap121" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=25000000 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_DM_SPI_FLASH=y CONFIG_SPI_FLASH=y diff --git a/configs/ap143_defconfig b/configs/ap143_defconfig index 7c1a296e27..9a5a9f89c6 100644 --- a/configs/ap143_defconfig +++ b/configs/ap143_defconfig @@ -31,6 +31,8 @@ CONFIG_MTDPARTS_DEFAULT="mtdparts=spi-flash.0:256k(u-boot),64k(u-boot-env),6336k # CONFIG_ISO_PARTITION is not set CONFIG_DEFAULT_DEVICE_TREE="ap143" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=25000000 # CONFIG_NET is not set CONFIG_DM_SPI_FLASH=y CONFIG_SPI_FLASH=y diff --git a/configs/at91sam9260ek_dataflash_cs0_defconfig b/configs/at91sam9260ek_dataflash_cs0_defconfig index 7fd844c94b..9b0aa0714e 100644 --- a/configs/at91sam9260ek_dataflash_cs0_defconfig +++ b/configs/at91sam9260ek_dataflash_cs0_defconfig @@ -29,6 +29,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9260ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9260ek_dataflash_cs1_defconfig b/configs/at91sam9260ek_dataflash_cs1_defconfig index c2fc77d78c..1e5d540930 100644 --- a/configs/at91sam9260ek_dataflash_cs1_defconfig +++ b/configs/at91sam9260ek_dataflash_cs1_defconfig @@ -29,6 +29,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9260ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9261ek_dataflash_cs0_defconfig b/configs/at91sam9261ek_dataflash_cs0_defconfig index 431cf280eb..e036ebcad4 100644 --- a/configs/at91sam9261ek_dataflash_cs0_defconfig +++ b/configs/at91sam9261ek_dataflash_cs0_defconfig @@ -30,6 +30,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9261ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9261ek_dataflash_cs3_defconfig b/configs/at91sam9261ek_dataflash_cs3_defconfig index e5efad80de..b67aa90fc9 100644 --- a/configs/at91sam9261ek_dataflash_cs3_defconfig +++ b/configs/at91sam9261ek_dataflash_cs3_defconfig @@ -30,6 +30,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9261ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9263ek_dataflash_cs0_defconfig b/configs/at91sam9263ek_dataflash_cs0_defconfig index a19f309c4a..4f8694f78d 100644 --- a/configs/at91sam9263ek_dataflash_cs0_defconfig +++ b/configs/at91sam9263ek_dataflash_cs0_defconfig @@ -33,6 +33,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9263ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9263ek_dataflash_defconfig b/configs/at91sam9263ek_dataflash_defconfig index a19f309c4a..4f8694f78d 100644 --- a/configs/at91sam9263ek_dataflash_defconfig +++ b/configs/at91sam9263ek_dataflash_defconfig @@ -33,6 +33,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9263ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9g10ek_dataflash_cs0_defconfig b/configs/at91sam9g10ek_dataflash_cs0_defconfig index 7bf0b79e34..6f71d34126 100644 --- a/configs/at91sam9g10ek_dataflash_cs0_defconfig +++ b/configs/at91sam9g10ek_dataflash_cs0_defconfig @@ -30,6 +30,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9261ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9g10ek_dataflash_cs3_defconfig b/configs/at91sam9g10ek_dataflash_cs3_defconfig index b4e8892cca..644d59de73 100644 --- a/configs/at91sam9g10ek_dataflash_cs3_defconfig +++ b/configs/at91sam9g10ek_dataflash_cs3_defconfig @@ -30,6 +30,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9261ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9g20ek_dataflash_cs0_defconfig b/configs/at91sam9g20ek_dataflash_cs0_defconfig index 688c1828f4..c064d01d89 100644 --- a/configs/at91sam9g20ek_dataflash_cs0_defconfig +++ b/configs/at91sam9g20ek_dataflash_cs0_defconfig @@ -29,6 +29,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9g20ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9g20ek_dataflash_cs1_defconfig b/configs/at91sam9g20ek_dataflash_cs1_defconfig index 1eb437936d..1e409eac39 100644 --- a/configs/at91sam9g20ek_dataflash_cs1_defconfig +++ b/configs/at91sam9g20ek_dataflash_cs1_defconfig @@ -29,6 +29,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9g20ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9rlek_dataflash_defconfig b/configs/at91sam9rlek_dataflash_defconfig index 800a92cf81..88c0a430da 100644 --- a/configs/at91sam9rlek_dataflash_defconfig +++ b/configs/at91sam9rlek_dataflash_defconfig @@ -30,6 +30,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9rlek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 # CONFIG_NET is not set CONFIG_DM=y CONFIG_CLK=y diff --git a/configs/at91sam9xeek_dataflash_cs0_defconfig b/configs/at91sam9xeek_dataflash_cs0_defconfig index ac6d9def8c..b125182b53 100644 --- a/configs/at91sam9xeek_dataflash_cs0_defconfig +++ b/configs/at91sam9xeek_dataflash_cs0_defconfig @@ -29,6 +29,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9260ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/at91sam9xeek_dataflash_cs1_defconfig b/configs/at91sam9xeek_dataflash_cs1_defconfig index 56c6f12c47..c07008a9df 100644 --- a/configs/at91sam9xeek_dataflash_cs1_defconfig +++ b/configs/at91sam9xeek_dataflash_cs1_defconfig @@ -29,6 +29,8 @@ CONFIG_CMD_FAT=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9260ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/controlcenterdc_defconfig b/configs/controlcenterdc_defconfig index b2b61b2ca5..08fdc55be2 100644 --- a/configs/controlcenterdc_defconfig +++ b/configs/controlcenterdc_defconfig @@ -44,6 +44,8 @@ CONFIG_EFI_PARTITION=y CONFIG_OF_BOARD_FIXUP=y CONFIG_DEFAULT_DEVICE_TREE="armada-38x-controlcenterdc" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_SPL_OF_TRANSLATE=y CONFIG_SCSI_AHCI=y CONFIG_DM_GPIO=y diff --git a/configs/d2net_v2_defconfig b/configs/d2net_v2_defconfig index 0b27bd7596..28c5c83d3c 100644 --- a/configs/d2net_v2_defconfig +++ b/configs/d2net_v2_defconfig @@ -31,6 +31,8 @@ CONFIG_EFI_PARTITION=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-d2net" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=20000000 CONFIG_MVSATA_IDE=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y diff --git a/configs/da850_am18xxevm_defconfig b/configs/da850_am18xxevm_defconfig index 419224104a..b8c16baf9a 100644 --- a/configs/da850_am18xxevm_defconfig +++ b/configs/da850_am18xxevm_defconfig @@ -39,6 +39,10 @@ CONFIG_SPL_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="da850-evm" CONFIG_SPL_OF_PLATDATA=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=0 +CONFIG_USE_ENV_SPI_MODE=y +CONFIG_ENV_SPI_MODE=0 CONFIG_DM=y CONFIG_SPL_DM=y CONFIG_DA8XX_GPIO=y diff --git a/configs/da850evm_defconfig b/configs/da850evm_defconfig index 41dae05fb9..3ee79432ca 100644 --- a/configs/da850evm_defconfig +++ b/configs/da850evm_defconfig @@ -41,6 +41,10 @@ CONFIG_SPL_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="da850-evm" CONFIG_SPL_OF_PLATDATA=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=0 +CONFIG_USE_ENV_SPI_MODE=y +CONFIG_ENV_SPI_MODE=0 CONFIG_DM=y CONFIG_SPL_DM=y CONFIG_DM_GPIO=y diff --git a/configs/db-88f6720_defconfig b/configs/db-88f6720_defconfig index 2c9254b5cf..3de9766dd1 100644 --- a/configs/db-88f6720_defconfig +++ b/configs/db-88f6720_defconfig @@ -39,6 +39,8 @@ CONFIG_CMD_FS_GENERIC=y # CONFIG_DOS_PARTITION is not set CONFIG_DEFAULT_DEVICE_TREE="armada-375-db" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_OF_TRANSLATE=y CONFIG_MISC=y diff --git a/configs/db-88f6820-amc_defconfig b/configs/db-88f6820-amc_defconfig index 422e8539af..dcf2a25395 100644 --- a/configs/db-88f6820-amc_defconfig +++ b/configs/db-88f6820-amc_defconfig @@ -43,6 +43,8 @@ CONFIG_EFI_PARTITION=y # CONFIG_SPL_PARTITION_UUIDS is not set CONFIG_DEFAULT_DEVICE_TREE="armada-385-amc" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_SPL_OF_TRANSLATE=y CONFIG_BLK=y # CONFIG_SPL_BLK is not set diff --git a/configs/db-88f6820-gp_defconfig b/configs/db-88f6820-gp_defconfig index b36b7c3b2c..a4c00e983d 100644 --- a/configs/db-88f6820-gp_defconfig +++ b/configs/db-88f6820-gp_defconfig @@ -43,6 +43,8 @@ CONFIG_EFI_PARTITION=y # CONFIG_SPL_PARTITION_UUIDS is not set CONFIG_DEFAULT_DEVICE_TREE="armada-388-gp" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_SPL_OF_TRANSLATE=y CONFIG_SCSI_AHCI=y CONFIG_MMC_SDHCI=y diff --git a/configs/db-mv784mp-gp_defconfig b/configs/db-mv784mp-gp_defconfig index b6c61c3a48..98e47ee956 100644 --- a/configs/db-mv784mp-gp_defconfig +++ b/configs/db-mv784mp-gp_defconfig @@ -42,6 +42,8 @@ CONFIG_EFI_PARTITION=y # CONFIG_PARTITION_UUIDS is not set # CONFIG_SPL_PARTITION_UUIDS is not set CONFIG_DEFAULT_DEVICE_TREE="armada-xp-gp" +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_SPL_OF_TRANSLATE=y CONFIG_SATA_MV=y # CONFIG_MMC is not set diff --git a/configs/dreamplug_defconfig b/configs/dreamplug_defconfig index d3263cf9cd..8202848ebf 100644 --- a/configs/dreamplug_defconfig +++ b/configs/dreamplug_defconfig @@ -23,6 +23,8 @@ CONFIG_ISO_PARTITION=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-dreamplug" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_DM=y CONFIG_MVSATA_IDE=y # CONFIG_MMC is not set diff --git a/configs/ds109_defconfig b/configs/ds109_defconfig index 3e4e71bcbf..29d5f98d76 100644 --- a/configs/ds109_defconfig +++ b/configs/ds109_defconfig @@ -18,6 +18,8 @@ CONFIG_ISO_PARTITION=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-ds109" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_DM=y CONFIG_MVSATA_IDE=y CONFIG_DM_I2C=y diff --git a/configs/ds414_defconfig b/configs/ds414_defconfig index ce42f23867..62cad53888 100644 --- a/configs/ds414_defconfig +++ b/configs/ds414_defconfig @@ -39,6 +39,8 @@ CONFIG_CMD_MTDPARTS=y CONFIG_CMD_UBI=y CONFIG_ISO_PARTITION=y CONFIG_DEFAULT_DEVICE_TREE="armada-xp-synology-ds414" +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_OF_TRANSLATE=y # CONFIG_MMC is not set diff --git a/configs/ethernut5_defconfig b/configs/ethernut5_defconfig index b14cf6c8e4..2ec3aae337 100644 --- a/configs/ethernut5_defconfig +++ b/configs/ethernut5_defconfig @@ -45,6 +45,8 @@ CONFIG_CMD_UBI=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="ethernut5" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/inetspace_v2_defconfig b/configs/inetspace_v2_defconfig index cebe4a55ea..ca85973fc2 100644 --- a/configs/inetspace_v2_defconfig +++ b/configs/inetspace_v2_defconfig @@ -31,6 +31,8 @@ CONFIG_EFI_PARTITION=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-is2" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=20000000 CONFIG_MVSATA_IDE=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y diff --git a/configs/ls1012aqds_qspi_defconfig b/configs/ls1012aqds_qspi_defconfig index d2c3eea43b..3212f37621 100644 --- a/configs/ls1012aqds_qspi_defconfig +++ b/configs/ls1012aqds_qspi_defconfig @@ -28,7 +28,6 @@ CONFIG_CMD_MMC=y CONFIG_CMD_PCI=y CONFIG_CMD_SF=y CONFIG_CMD_SPI=y -CONFIG_DEFAULT_SPI_BUS=1 CONFIG_CMD_USB=y CONFIG_DEFAULT_SPI_BUS=1 # CONFIG_CMD_SETEXPR is not set @@ -37,6 +36,12 @@ CONFIG_CMD_DATE=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="fsl-ls1012a-qds" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_BUS=y +CONFIG_ENV_SPI_BUS=0 +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=1000000 +CONFIG_USE_ENV_SPI_MODE=y +CONFIG_ENV_SPI_MODE=0x03 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_DM=y CONFIG_SCSI_AHCI=y diff --git a/configs/ls1012aqds_tfa_defconfig b/configs/ls1012aqds_tfa_defconfig index d18d40a28f..99188d3e58 100644 --- a/configs/ls1012aqds_tfa_defconfig +++ b/configs/ls1012aqds_tfa_defconfig @@ -36,6 +36,12 @@ CONFIG_CMD_DATE=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="fsl-ls1012a-qds" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_BUS=y +CONFIG_ENV_SPI_BUS=0 +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=1000000 +CONFIG_USE_ENV_SPI_MODE=y +CONFIG_ENV_SPI_MODE=0x03 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_DM=y CONFIG_SCSI_AHCI=y diff --git a/configs/ls1043aqds_tfa_defconfig b/configs/ls1043aqds_tfa_defconfig index 712e1673eb..e615f75625 100644 --- a/configs/ls1043aqds_tfa_defconfig +++ b/configs/ls1043aqds_tfa_defconfig @@ -34,6 +34,8 @@ CONFIG_ENV_IS_IN_FLASH=y CONFIG_ENV_IS_IN_MMC=y CONFIG_ENV_IS_IN_NAND=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_BUS=y +CONFIG_ENV_SPI_BUS=0 CONFIG_DM=y CONFIG_SATA_CEVA=y CONFIG_FSL_CAAM=y diff --git a/configs/ls1046aqds_tfa_defconfig b/configs/ls1046aqds_tfa_defconfig index 352da8ab76..ede5df6224 100644 --- a/configs/ls1046aqds_tfa_defconfig +++ b/configs/ls1046aqds_tfa_defconfig @@ -35,6 +35,8 @@ CONFIG_ENV_IS_IN_FLASH=y CONFIG_ENV_IS_IN_MMC=y CONFIG_ENV_IS_IN_NAND=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_BUS=y +CONFIG_ENV_SPI_BUS=0 CONFIG_DM=y CONFIG_SATA_CEVA=y CONFIG_FSL_CAAM=y diff --git a/configs/maxbcm_defconfig b/configs/maxbcm_defconfig index 5c716cdec8..1521392987 100644 --- a/configs/maxbcm_defconfig +++ b/configs/maxbcm_defconfig @@ -30,6 +30,8 @@ CONFIG_CMD_MII=y CONFIG_CMD_PING=y CONFIG_CMD_TIME=y CONFIG_DEFAULT_DEVICE_TREE="armada-xp-maxbcm" +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_SPL_OF_TRANSLATE=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y diff --git a/configs/meesc_dataflash_defconfig b/configs/meesc_dataflash_defconfig index 54adab9203..476700c7ed 100644 --- a/configs/meesc_dataflash_defconfig +++ b/configs/meesc_dataflash_defconfig @@ -20,6 +20,8 @@ CONFIG_CMD_PING=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="at91sam9263ek" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/configs/mscc_jr2_defconfig b/configs/mscc_jr2_defconfig index 9276df22a5..95562b7cd8 100644 --- a/configs/mscc_jr2_defconfig +++ b/configs/mscc_jr2_defconfig @@ -38,6 +38,10 @@ CONFIG_OF_LIST="jr2_pcb110 jr2_pcb111 serval2_pcb112" CONFIG_DTB_RESELECT=y CONFIG_MULTI_DTB_FIT=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=0 +CONFIG_USE_ENV_SPI_MODE=y +CONFIG_ENV_SPI_MODE=0 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_CLK=y CONFIG_DM_GPIO=y diff --git a/configs/mscc_luton_defconfig b/configs/mscc_luton_defconfig index 0fdd9b8f3f..162a514248 100644 --- a/configs/mscc_luton_defconfig +++ b/configs/mscc_luton_defconfig @@ -44,6 +44,10 @@ CONFIG_OF_LIST="luton_pcb090 luton_pcb091" CONFIG_DTB_RESELECT=y CONFIG_MULTI_DTB_FIT=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=0 +CONFIG_USE_ENV_SPI_MODE=y +CONFIG_ENV_SPI_MODE=0 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_CLK=y CONFIG_DM_GPIO=y diff --git a/configs/mscc_ocelot_defconfig b/configs/mscc_ocelot_defconfig index edc476d143..b0dcfaf2df 100644 --- a/configs/mscc_ocelot_defconfig +++ b/configs/mscc_ocelot_defconfig @@ -43,6 +43,10 @@ CONFIG_OF_LIST="ocelot_pcb120 ocelot_pcb123" CONFIG_DTB_RESELECT=y CONFIG_MULTI_DTB_FIT=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=0 +CONFIG_USE_ENV_SPI_MODE=y +CONFIG_ENV_SPI_MODE=0 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_CLK=y CONFIG_DM_GPIO=y diff --git a/configs/mscc_serval_defconfig b/configs/mscc_serval_defconfig index 146188bb0c..f2c95632bd 100644 --- a/configs/mscc_serval_defconfig +++ b/configs/mscc_serval_defconfig @@ -35,6 +35,10 @@ CONFIG_OF_LIST="serval_pcb106 serval_pcb105" CONFIG_DTB_RESELECT=y CONFIG_MULTI_DTB_FIT=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=0 +CONFIG_USE_ENV_SPI_MODE=y +CONFIG_ENV_SPI_MODE=0 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_CLK=y CONFIG_DM_GPIO=y diff --git a/configs/mscc_servalt_defconfig b/configs/mscc_servalt_defconfig index a450f48018..027aaa44d5 100644 --- a/configs/mscc_servalt_defconfig +++ b/configs/mscc_servalt_defconfig @@ -33,6 +33,10 @@ CONFIG_DEFAULT_DEVICE_TREE="servalt_pcb116" CONFIG_DTB_RESELECT=y CONFIG_MULTI_DTB_FIT=y CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=0 +CONFIG_USE_ENV_SPI_MODE=y +CONFIG_ENV_SPI_MODE=0 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_CLK=y CONFIG_DM_GPIO=y diff --git a/configs/net2big_v2_defconfig b/configs/net2big_v2_defconfig index 8996d5214f..44c8d5b35d 100644 --- a/configs/net2big_v2_defconfig +++ b/configs/net2big_v2_defconfig @@ -31,6 +31,8 @@ CONFIG_EFI_PARTITION=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-net2big" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=20000000 CONFIG_MVSATA_IDE=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y diff --git a/configs/netspace_lite_v2_defconfig b/configs/netspace_lite_v2_defconfig index e6d772490a..ac103c3f22 100644 --- a/configs/netspace_lite_v2_defconfig +++ b/configs/netspace_lite_v2_defconfig @@ -31,6 +31,8 @@ CONFIG_EFI_PARTITION=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-ns2lite" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=20000000 CONFIG_MVSATA_IDE=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y diff --git a/configs/netspace_max_v2_defconfig b/configs/netspace_max_v2_defconfig index 89df1f35a6..9eded365b8 100644 --- a/configs/netspace_max_v2_defconfig +++ b/configs/netspace_max_v2_defconfig @@ -31,6 +31,8 @@ CONFIG_EFI_PARTITION=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-ns2max" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=20000000 CONFIG_MVSATA_IDE=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y diff --git a/configs/netspace_mini_v2_defconfig b/configs/netspace_mini_v2_defconfig index 9a5cf19ced..4b0fff4486 100644 --- a/configs/netspace_mini_v2_defconfig +++ b/configs/netspace_mini_v2_defconfig @@ -29,6 +29,8 @@ CONFIG_EFI_PARTITION=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-ns2mini" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=20000000 CONFIG_MVSATA_IDE=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y diff --git a/configs/netspace_v2_defconfig b/configs/netspace_v2_defconfig index bd879abfe7..24749f824e 100644 --- a/configs/netspace_v2_defconfig +++ b/configs/netspace_v2_defconfig @@ -31,6 +31,8 @@ CONFIG_EFI_PARTITION=y CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="kirkwood-ns2" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=20000000 CONFIG_MVSATA_IDE=y # CONFIG_MMC is not set CONFIG_SPI_FLASH=y diff --git a/configs/peach-pi_defconfig b/configs/peach-pi_defconfig index cb818c5ecf..6fc89cd06b 100644 --- a/configs/peach-pi_defconfig +++ b/configs/peach-pi_defconfig @@ -29,6 +29,8 @@ CONFIG_CMD_TPM_TEST=y CONFIG_CMD_EXT4_WRITE=y CONFIG_DEFAULT_DEVICE_TREE="exynos5800-peach-pi" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_BUS=y +CONFIG_ENV_SPI_BUS=1 CONFIG_I2C_CROS_EC_TUNNEL=y CONFIG_I2C_MUX=y CONFIG_I2C_ARB_GPIO_CHALLENGE=y diff --git a/configs/peach-pit_defconfig b/configs/peach-pit_defconfig index bb1558b267..f091d24f4f 100644 --- a/configs/peach-pit_defconfig +++ b/configs/peach-pit_defconfig @@ -28,6 +28,8 @@ CONFIG_CMD_TPM_TEST=y CONFIG_CMD_EXT4_WRITE=y CONFIG_DEFAULT_DEVICE_TREE="exynos5420-peach-pit" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_BUS=y +CONFIG_ENV_SPI_BUS=1 CONFIG_I2C_CROS_EC_TUNNEL=y CONFIG_I2C_MUX=y CONFIG_I2C_ARB_GPIO_CHALLENGE=y diff --git a/configs/smdk5250_defconfig b/configs/smdk5250_defconfig index d24e9e21c5..67413874b9 100644 --- a/configs/smdk5250_defconfig +++ b/configs/smdk5250_defconfig @@ -30,6 +30,8 @@ CONFIG_CMD_REGULATOR=y CONFIG_CMD_EXT4_WRITE=y CONFIG_DEFAULT_DEVICE_TREE="exynos5250-smdk5250" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_BUS=y +CONFIG_ENV_SPI_BUS=1 CONFIG_MMC_DW=y CONFIG_MMC_SDHCI=y CONFIG_MMC_SDHCI_S5P=y diff --git a/configs/smdk5420_defconfig b/configs/smdk5420_defconfig index 704786a473..6a919628d9 100644 --- a/configs/smdk5420_defconfig +++ b/configs/smdk5420_defconfig @@ -25,6 +25,8 @@ CONFIG_CMD_TIME=y CONFIG_CMD_EXT4_WRITE=y CONFIG_DEFAULT_DEVICE_TREE="exynos5420-smdk5420" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_BUS=y +CONFIG_ENV_SPI_BUS=1 CONFIG_MMC_DW=y CONFIG_MMC_SDHCI=y CONFIG_MMC_SDHCI_S5P=y diff --git a/configs/snow_defconfig b/configs/snow_defconfig index 6179a640e1..54bf740577 100644 --- a/configs/snow_defconfig +++ b/configs/snow_defconfig @@ -34,6 +34,8 @@ CONFIG_CMD_TPM_TEST=y CONFIG_CMD_EXT4_WRITE=y CONFIG_DEFAULT_DEVICE_TREE="exynos5250-snow" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_BUS=y +CONFIG_ENV_SPI_BUS=1 CONFIG_I2C_CROS_EC_LDO=y CONFIG_I2C_MUX=y CONFIG_I2C_ARB_GPIO_CHALLENGE=y diff --git a/configs/spring_defconfig b/configs/spring_defconfig index 2bbfa6dcb8..c24aa2ed0d 100644 --- a/configs/spring_defconfig +++ b/configs/spring_defconfig @@ -34,6 +34,8 @@ CONFIG_CMD_TPM_TEST=y CONFIG_CMD_EXT4_WRITE=y CONFIG_DEFAULT_DEVICE_TREE="exynos5250-spring" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_BUS=y +CONFIG_ENV_SPI_BUS=1 CONFIG_I2C_CROS_EC_LDO=y CONFIG_I2C_MUX=y CONFIG_I2C_ARB_GPIO_CHALLENGE=y diff --git a/configs/stmark2_defconfig b/configs/stmark2_defconfig index d74ba67a1b..630b01c233 100644 --- a/configs/stmark2_defconfig +++ b/configs/stmark2_defconfig @@ -20,6 +20,8 @@ CONFIG_CMD_MTDPARTS=y CONFIG_MTDIDS_DEFAULT="nor0=spi-flash.0" CONFIG_MTDPARTS_DEFAULT="mtdparts=spi-flash.0:1m(u-boot),7m(kernel),-(rootfs)" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_CS=y +CONFIG_ENV_SPI_CS=1 # CONFIG_NET is not set CONFIG_MTD_DEVICE=y CONFIG_SPI_FLASH=y diff --git a/configs/theadorable_debug_defconfig b/configs/theadorable_debug_defconfig index cd52220f97..fb9307aaf5 100644 --- a/configs/theadorable_debug_defconfig +++ b/configs/theadorable_debug_defconfig @@ -46,6 +46,8 @@ CONFIG_EFI_PARTITION=y # CONFIG_PARTITION_UUIDS is not set # CONFIG_SPL_PARTITION_UUIDS is not set CONFIG_DEFAULT_DEVICE_TREE="armada-xp-theadorable" +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_OF_TRANSLATE=y CONFIG_SATA_MV=y diff --git a/configs/trimslice_defconfig b/configs/trimslice_defconfig index 23034e860f..bd08adb788 100644 --- a/configs/trimslice_defconfig +++ b/configs/trimslice_defconfig @@ -24,6 +24,8 @@ CONFIG_CMD_EXT4_WRITE=y # CONFIG_SPL_EFI_PARTITION is not set CONFIG_DEFAULT_DEVICE_TREE="tegra20-trimslice" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=48000000 CONFIG_SPL_DM=y CONFIG_SYS_I2C_TEGRA=y CONFIG_SPI_FLASH=y diff --git a/configs/turris_omnia_defconfig b/configs/turris_omnia_defconfig index 7e5943b108..c406b25753 100644 --- a/configs/turris_omnia_defconfig +++ b/configs/turris_omnia_defconfig @@ -35,6 +35,8 @@ CONFIG_CMD_BTRFS=y # CONFIG_SPL_PARTITION_UUIDS is not set CONFIG_DEFAULT_DEVICE_TREE="armada-385-turris-omnia" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=50000000 CONFIG_SPL_OF_TRANSLATE=y CONFIG_SCSI_AHCI=y CONFIG_ATSHA204A=y diff --git a/configs/usb_a9263_dataflash_defconfig b/configs/usb_a9263_dataflash_defconfig index 9f7506f70b..3b9e4a535f 100644 --- a/configs/usb_a9263_dataflash_defconfig +++ b/configs/usb_a9263_dataflash_defconfig @@ -25,6 +25,8 @@ CONFIG_MTDPARTS_DEFAULT="mtdparts=atmel_nand:16m(kernel)ro,120m(root1),-(root2)" CONFIG_OF_CONTROL=y CONFIG_DEFAULT_DEVICE_TREE="usb_a9263" CONFIG_ENV_IS_IN_SPI_FLASH=y +CONFIG_USE_ENV_SPI_MAX_HZ=y +CONFIG_ENV_SPI_MAX_HZ=15000000 CONFIG_DM=y CONFIG_CLK=y CONFIG_CLK_AT91=y diff --git a/env/Kconfig b/env/Kconfig index c22cbbdadc..78300660c7 100644 --- a/env/Kconfig +++ b/env/Kconfig @@ -324,18 +324,57 @@ config ENV_IS_IN_SPI_FLASH during a "saveenv" operation. CONFIG_ENV_OFFSET_REDUND must be aligned to an erase sector boundary. - - CONFIG_ENV_SPI_BUS (optional): - - CONFIG_ENV_SPI_CS (optional): +config USE_ENV_SPI_BUS + bool "SPI flash bus for environment" + depends on ENV_IS_IN_SPI_FLASH + help + Force the SPI bus for environment. + If not defined, use CONFIG_SF_DEFAULT_BUS. + +config ENV_SPI_BUS + int "Value of SPI flash bus for environment" + depends on USE_ENV_SPI_BUS + help + Value the SPI bus and chip select for environment. + +config USE_ENV_SPI_CS + bool "SPI flash chip select for environment" + depends on ENV_IS_IN_SPI_FLASH + help + Force the SPI chip select for environment. + If not defined, use CONFIG_SF_DEFAULT_CS. - Define the SPI bus and chip select. If not defined they will be 0. +config ENV_SPI_CS + int "Value of SPI flash chip select for environment" + depends on USE_ENV_SPI_CS + help + Value of the SPI chip select for environment. - - CONFIG_ENV_SPI_MAX_HZ (optional): +config USE_ENV_SPI_MAX_HZ + bool "SPI flash bus for environment" + depends on ENV_IS_IN_SPI_FLASH + help + Force the SPI max work clock for environment. + If not defined, use CONFIG_SF_DEFAULT_SPEED. - Define the SPI max work clock. If not defined then use 1MHz. +config ENV_SPI_MAX_HZ + int "Value of SPI flash max work for environment" + depends on USE_ENV_SPI_MAX_HZ + help + Value of the SPI max work clock for environment. - - CONFIG_ENV_SPI_MODE (optional): +config USE_ENV_SPI_MODE + bool "SPI flash mode for environment" + depends on ENV_IS_IN_SPI_FLASH + help + Force the SPI work mode for environment. - Define the SPI work mode. If not defined then use SPI_MODE_3. +config ENV_SPI_MODE + hex "Value of SPI flash work mode for environment" + depends on USE_ENV_SPI_MODE + help + Value of the SPI work mode for environment. + See include/spi.h for value. config ENV_IS_IN_UBI bool "Environment in a UBI volume" diff --git a/env/sf.c b/env/sf.c index 23cbad5d88..4f92ae0568 100644 --- a/env/sf.c +++ b/env/sf.c @@ -18,19 +18,6 @@ #include #include -#ifndef CONFIG_ENV_SPI_BUS -# define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#endif -#ifndef CONFIG_ENV_SPI_CS -# define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#endif -#ifndef CONFIG_ENV_SPI_MAX_HZ -# define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED -#endif -#ifndef CONFIG_ENV_SPI_MODE -# define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#endif - #ifndef CONFIG_SPL_BUILD #define CMD_SAVEENV #define INITENV diff --git a/include/configs/B4860QDS.h b/include/configs/B4860QDS.h index 25705ccee3..e8c9cdd73d 100644 --- a/include/configs/B4860QDS.h +++ b/include/configs/B4860QDS.h @@ -99,10 +99,6 @@ #define CONFIG_ENV_OVERWRITE #if defined(CONFIG_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/BSC9131RDB.h b/include/configs/BSC9131RDB.h index 49bea98d35..c01071e60d 100644 --- a/include/configs/BSC9131RDB.h +++ b/include/configs/BSC9131RDB.h @@ -253,10 +253,6 @@ extern unsigned long get_sdram_size(void); * Environment */ #if defined(CONFIG_RAMBOOT_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 #define CONFIG_ENV_SIZE 0x2000 diff --git a/include/configs/BSC9132QDS.h b/include/configs/BSC9132QDS.h index 73cc353082..68100f1d52 100644 --- a/include/configs/BSC9132QDS.h +++ b/include/configs/BSC9132QDS.h @@ -454,10 +454,6 @@ combinations. this should be removed later #define CONFIG_SYS_MMC_ENV_DEV 0 #define CONFIG_ENV_SIZE 0x2000 #elif defined(CONFIG_RAMBOOT_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 #define CONFIG_ENV_SIZE 0x2000 diff --git a/include/configs/C29XPCIE.h b/include/configs/C29XPCIE.h index a18d0412ce..9b83a50fdf 100644 --- a/include/configs/C29XPCIE.h +++ b/include/configs/C29XPCIE.h @@ -380,10 +380,6 @@ */ #if defined(CONFIG_SYS_RAMBOOT) #if defined(CONFIG_RAMBOOT_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 #define CONFIG_ENV_SIZE 0x2000 diff --git a/include/configs/M52277EVB.h b/include/configs/M52277EVB.h index 83d774527a..514733eef7 100644 --- a/include/configs/M52277EVB.h +++ b/include/configs/M52277EVB.h @@ -177,9 +177,6 @@ * Environment is not embedded in u-boot. First time runing may have env * crc error warning if there is no correct environment on the flash. */ -#ifdef CONFIG_CF_SBF -# define CONFIG_ENV_SPI_CS 2 -#endif #define CONFIG_ENV_OVERWRITE 1 /*----------------------------------------------------------------------- diff --git a/include/configs/M54418TWR.h b/include/configs/M54418TWR.h index 4b8ef38c0b..f7b0669fc5 100644 --- a/include/configs/M54418TWR.h +++ b/include/configs/M54418TWR.h @@ -238,7 +238,6 @@ #endif #if defined(CONFIG_CF_SBF) -#define CONFIG_ENV_SPI_CS 1 #define CONFIG_ENV_OFFSET 0x40000 #define CONFIG_ENV_SIZE 0x2000 #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/M54451EVB.h b/include/configs/M54451EVB.h index 87cdbae1db..57c8572aba 100644 --- a/include/configs/M54451EVB.h +++ b/include/configs/M54451EVB.h @@ -198,7 +198,6 @@ * crc error warning if there is no correct environment on the flash. */ #if defined(CONFIG_SYS_STMICRO_BOOT) -# define CONFIG_ENV_SPI_CS 1 # define CONFIG_ENV_OFFSET 0x20000 # define CONFIG_ENV_SIZE 0x2000 # define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/M54455EVB.h b/include/configs/M54455EVB.h index d41b7c4492..448dfc98a9 100644 --- a/include/configs/M54455EVB.h +++ b/include/configs/M54455EVB.h @@ -248,9 +248,6 @@ * Environment is not embedded in u-boot. First time runing may have env * crc error warning if there is no correct environment on the flash. */ -#ifdef CONFIG_CF_SBF -# define CONFIG_ENV_SPI_CS 1 -#endif #undef CONFIG_ENV_OVERWRITE /*----------------------------------------------------------------------- diff --git a/include/configs/MPC8536DS.h b/include/configs/MPC8536DS.h index 11dcf23b81..819129033f 100644 --- a/include/configs/MPC8536DS.h +++ b/include/configs/MPC8536DS.h @@ -524,10 +524,6 @@ #if defined(CONFIG_SYS_RAMBOOT) #if defined(CONFIG_RAMBOOT_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0xF0000 #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/P1010RDB.h b/include/configs/P1010RDB.h index cefa598e8d..4be40d0d02 100644 --- a/include/configs/P1010RDB.h +++ b/include/configs/P1010RDB.h @@ -644,10 +644,6 @@ extern unsigned long get_sdram_size(void); #define CONFIG_SYS_MMC_ENV_DEV 0 #define CONFIG_ENV_SIZE 0x2000 #elif defined(CONFIG_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 #define CONFIG_ENV_SIZE 0x2000 diff --git a/include/configs/P1022DS.h b/include/configs/P1022DS.h index 8bdbabee68..bdbf119c32 100644 --- a/include/configs/P1022DS.h +++ b/include/configs/P1022DS.h @@ -503,10 +503,6 @@ * Environment */ #ifdef CONFIG_SPIFLASH -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/P2041RDB.h b/include/configs/P2041RDB.h index da43320d18..b433308fff 100644 --- a/include/configs/P2041RDB.h +++ b/include/configs/P2041RDB.h @@ -49,10 +49,6 @@ #define CONFIG_ENV_OVERWRITE #if defined(CONFIG_SPIFLASH) - #define CONFIG_ENV_SPI_BUS 0 - #define CONFIG_ENV_SPI_CS 0 - #define CONFIG_ENV_SPI_MAX_HZ 10000000 - #define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/SBx81LIFKW.h b/include/configs/SBx81LIFKW.h index d62fd35e81..1539e8fabb 100644 --- a/include/configs/SBx81LIFKW.h +++ b/include/configs/SBx81LIFKW.h @@ -56,10 +56,6 @@ /* * Environment variables configurations */ -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 20000000 /* 20Mhz */ -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE #define CONFIG_ENV_SECT_SIZE 0x40000 /* 256K */ #define CONFIG_ENV_SIZE 0x02000 #define CONFIG_ENV_OFFSET 0xc0000 /* env starts here - 768K */ diff --git a/include/configs/SBx81LIFXCAT.h b/include/configs/SBx81LIFXCAT.h index 3c8c216d89..af19193052 100644 --- a/include/configs/SBx81LIFXCAT.h +++ b/include/configs/SBx81LIFXCAT.h @@ -56,10 +56,6 @@ /* * Environment variables configurations */ -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 20000000 /* 20Mhz */ -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE #define CONFIG_ENV_SECT_SIZE 0x40000 /* 256K */ #define CONFIG_ENV_SIZE 0x02000 #define CONFIG_ENV_OFFSET 0xc0000 /* env starts here - 768K */ diff --git a/include/configs/T102xQDS.h b/include/configs/T102xQDS.h index 73b70fa680..ef94097e09 100644 --- a/include/configs/T102xQDS.h +++ b/include/configs/T102xQDS.h @@ -129,10 +129,6 @@ #endif #if defined(CONFIG_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/T102xRDB.h b/include/configs/T102xRDB.h index 2ba3a9f8e6..551ba6d935 100644 --- a/include/configs/T102xRDB.h +++ b/include/configs/T102xRDB.h @@ -144,10 +144,6 @@ #endif #if defined(CONFIG_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #if defined(CONFIG_TARGET_T1024RDB) diff --git a/include/configs/T1040QDS.h b/include/configs/T1040QDS.h index 89ace7c1b0..417383c7f0 100644 --- a/include/configs/T1040QDS.h +++ b/include/configs/T1040QDS.h @@ -59,10 +59,6 @@ #ifdef CONFIG_MTD_NOR_FLASH #if defined(CONFIG_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/T104xRDB.h b/include/configs/T104xRDB.h index 0d92f27aab..a7e0f8f508 100644 --- a/include/configs/T104xRDB.h +++ b/include/configs/T104xRDB.h @@ -521,10 +521,6 @@ $(SRCTREE)/board/freescale/t104xrdb/t1042d4_sd_rcw.cfg /* * eSPI - Enhanced SPI */ -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 /* * General PCI diff --git a/include/configs/T208xQDS.h b/include/configs/T208xQDS.h index 8db38943ea..0d53ad50df 100644 --- a/include/configs/T208xQDS.h +++ b/include/configs/T208xQDS.h @@ -125,10 +125,6 @@ #endif #if defined(CONFIG_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/T208xRDB.h b/include/configs/T208xRDB.h index 40a03165ca..a78dd810c6 100644 --- a/include/configs/T208xRDB.h +++ b/include/configs/T208xRDB.h @@ -110,10 +110,6 @@ #define CONFIG_SYS_MEMTEST_END 0x00400000 #if defined(CONFIG_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/T4240QDS.h b/include/configs/T4240QDS.h index 80a4b13fd8..9e70412298 100644 --- a/include/configs/T4240QDS.h +++ b/include/configs/T4240QDS.h @@ -74,10 +74,6 @@ #include "t4qds.h" #if defined(CONFIG_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/T4240RDB.h b/include/configs/T4240RDB.h index f007b62a3d..71258c805d 100644 --- a/include/configs/T4240RDB.h +++ b/include/configs/T4240RDB.h @@ -280,10 +280,6 @@ "bootm 0x01000000 - 0x00f00000" #if defined(CONFIG_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/UCP1020.h b/include/configs/UCP1020.h index 0a996e097c..b518c222d4 100644 --- a/include/configs/UCP1020.h +++ b/include/configs/UCP1020.h @@ -328,10 +328,6 @@ #else -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #ifdef CONFIG_RAMBOOT_SPIFLASH diff --git a/include/configs/adp-ae3xx.h b/include/configs/adp-ae3xx.h index f2268dcb00..1fe33917d0 100644 --- a/include/configs/adp-ae3xx.h +++ b/include/configs/adp-ae3xx.h @@ -201,10 +201,6 @@ #define CONFIG_SYS_MAX_FLASH_SECT 512 /* environments */ -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 50000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SECT_SIZE 0x1000 #define CONFIG_ENV_OFFSET 0x140000 #define CONFIG_ENV_SIZE 8192 diff --git a/include/configs/advantech_dms-ba16.h b/include/configs/advantech_dms-ba16.h index a08f62b060..e2c70605b2 100644 --- a/include/configs/advantech_dms-ba16.h +++ b/include/configs/advantech_dms-ba16.h @@ -212,10 +212,6 @@ #define CONFIG_ENV_SIZE (8 * 1024) #define CONFIG_ENV_OFFSET (768 * 1024) #define CONFIG_ENV_SECT_SIZE (64 * 1024) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_SYS_FSL_USDHC_NUM 3 diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h index d8f05835c2..0834ff5021 100644 --- a/include/configs/am335x_evm.h +++ b/include/configs/am335x_evm.h @@ -284,7 +284,6 @@ #define CONFIG_SYS_SPI_U_BOOT_OFFS 0x20000 #define CONFIG_SYS_REDUNDAND_ENVIRONMENT -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_ENV_SECT_SIZE (4 << 10) /* 4 KB sectors */ #define CONFIG_ENV_OFFSET (768 << 10) /* 768 KiB in */ #define CONFIG_ENV_OFFSET_REDUND (896 << 10) /* 896 KiB in */ diff --git a/include/configs/am43xx_evm.h b/include/configs/am43xx_evm.h index 55faa7bc25..5a6080645a 100644 --- a/include/configs/am43xx_evm.h +++ b/include/configs/am43xx_evm.h @@ -115,7 +115,6 @@ #ifdef CONFIG_QSPI_BOOT #define CONFIG_SYS_REDUNDAND_ENVIRONMENT -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_ENV_SECT_SIZE (64 << 10) /* 64 KB sectors */ #define CONFIG_ENV_OFFSET 0x110000 #define CONFIG_ENV_OFFSET_REDUND 0x120000 diff --git a/include/configs/ap121.h b/include/configs/ap121.h index 96850b5761..0e8c3f70d9 100644 --- a/include/configs/ap121.h +++ b/include/configs/ap121.h @@ -30,7 +30,6 @@ "mtdparts default;" \ "bootm 0x9f650000" -#define CONFIG_ENV_SPI_MAX_HZ 25000000 #define CONFIG_ENV_OFFSET 0x40000 #define CONFIG_ENV_SECT_SIZE 0x10000 #define CONFIG_ENV_SIZE 0x10000 diff --git a/include/configs/ap143.h b/include/configs/ap143.h index 4dbca917e3..fa6921022d 100644 --- a/include/configs/ap143.h +++ b/include/configs/ap143.h @@ -34,7 +34,6 @@ "mtdparts default;" \ "bootm 0x9f680000" -#define CONFIG_ENV_SPI_MAX_HZ 25000000 #define CONFIG_ENV_OFFSET 0x40000 #define CONFIG_ENV_SECT_SIZE 0x10000 #define CONFIG_ENV_SIZE 0x10000 diff --git a/include/configs/aristainetos-common.h b/include/configs/aristainetos-common.h index eecc0213fd..4f28f52402 100644 --- a/include/configs/aristainetos-common.h +++ b/include/configs/aristainetos-common.h @@ -149,10 +149,6 @@ /* Environment organization */ #define CONFIG_ENV_SIZE (12 * 1024) #define CONFIG_SYS_REDUNDAND_ENVIRONMENT -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE #define CONFIG_ENV_SECT_SIZE (0x010000) #define CONFIG_ENV_OFFSET (0x0d0000) #define CONFIG_ENV_OFFSET_REDUND (0x0e0000) diff --git a/include/configs/at91sam9260ek.h b/include/configs/at91sam9260ek.h index 2177512fe8..95710fb4c8 100644 --- a/include/configs/at91sam9260ek.h +++ b/include/configs/at91sam9260ek.h @@ -118,7 +118,6 @@ #define CONFIG_ENV_OFFSET 0x4200 #define CONFIG_ENV_SIZE 0x4200 #define CONFIG_ENV_SECT_SIZE 0x210 -#define CONFIG_ENV_SPI_MAX_HZ 15000000 #define CONFIG_BOOTCOMMAND "sf probe 0:0; " \ "sf read 0x22000000 0x84000 0x294000; " \ "bootm 0x22000000" @@ -128,7 +127,6 @@ #define CONFIG_ENV_OFFSET 0x4200 #define CONFIG_ENV_SIZE 0x4200 #define CONFIG_ENV_SECT_SIZE 0x210 -#define CONFIG_ENV_SPI_MAX_HZ 15000000 #define CONFIG_BOOTCOMMAND "sf probe 0:1; " \ "sf read 0x22000000 0x84000 0x294000; " \ "bootm 0x22000000" diff --git a/include/configs/at91sam9261ek.h b/include/configs/at91sam9261ek.h index 1c7fbe111f..599e2627f6 100644 --- a/include/configs/at91sam9261ek.h +++ b/include/configs/at91sam9261ek.h @@ -104,7 +104,6 @@ #define CONFIG_ENV_OFFSET 0x4200 #define CONFIG_ENV_SIZE 0x4200 #define CONFIG_ENV_SECT_SIZE 0x210 -#define CONFIG_ENV_SPI_MAX_HZ 15000000 #define CONFIG_BOOTCOMMAND "sf probe 0; " \ "sf read 0x22000000 0x84000 0x294000; " \ "bootm 0x22000000" @@ -115,7 +114,6 @@ #define CONFIG_ENV_OFFSET 0x4200 #define CONFIG_ENV_SIZE 0x4200 #define CONFIG_ENV_SECT_SIZE 0x210 -#define CONFIG_ENV_SPI_MAX_HZ 15000000 #define CONFIG_BOOTCOMMAND "sf probe 0:3; " \ "sf read 0x22000000 0x84000 0x294000; " \ "bootm 0x22000000" diff --git a/include/configs/at91sam9263ek.h b/include/configs/at91sam9263ek.h index 856e0328e7..6b1db9ff1e 100644 --- a/include/configs/at91sam9263ek.h +++ b/include/configs/at91sam9263ek.h @@ -222,7 +222,6 @@ #define CONFIG_ENV_OFFSET 0x4200 #define CONFIG_ENV_SIZE 0x4200 #define CONFIG_ENV_SECT_SIZE 0x210 -#define CONFIG_ENV_SPI_MAX_HZ 15000000 #define CONFIG_BOOTCOMMAND "sf probe 0; " \ "sf read 0x22000000 0x84000 0x294000; " \ "bootm 0x22000000" diff --git a/include/configs/at91sam9rlek.h b/include/configs/at91sam9rlek.h index b052071478..3e18716e20 100644 --- a/include/configs/at91sam9rlek.h +++ b/include/configs/at91sam9rlek.h @@ -76,7 +76,6 @@ #define CONFIG_ENV_OFFSET 0x4200 #define CONFIG_ENV_SIZE 0x4200 #define CONFIG_ENV_SECT_SIZE 0x210 -#define CONFIG_ENV_SPI_MAX_HZ 15000000 #define CONFIG_BOOTCOMMAND "sf probe 0; " \ "sf read 0x22000000 0x84000 0x294000; " \ "bootm 0x22000000" diff --git a/include/configs/at91sam9x5ek.h b/include/configs/at91sam9x5ek.h index d43d408426..1abca55112 100644 --- a/include/configs/at91sam9x5ek.h +++ b/include/configs/at91sam9x5ek.h @@ -84,7 +84,6 @@ #define CONFIG_ENV_OFFSET 0x5000 #define CONFIG_ENV_SIZE 0x3000 #define CONFIG_ENV_SECT_SIZE 0x1000 -#define CONFIG_ENV_SPI_MAX_HZ 30000000 #define CONFIG_BOOTCOMMAND "sf probe 0; " \ "sf read 0x22000000 0x100000 0x300000; " \ "bootm 0x22000000" @@ -93,7 +92,6 @@ #define CONFIG_ENV_OFFSET 0x4200 #define CONFIG_ENV_SIZE 0x4200 #define CONFIG_ENV_SECT_SIZE 0x210 -#define CONFIG_ENV_SPI_MAX_HZ 30000000 #define CONFIG_BOOTCOMMAND "sf probe 0; " \ "sf read 0x22000000 0x84000 0x294000; " \ "bootm 0x22000000" diff --git a/include/configs/ax25-ae350.h b/include/configs/ax25-ae350.h index cd0721248a..395f3a442d 100644 --- a/include/configs/ax25-ae350.h +++ b/include/configs/ax25-ae350.h @@ -113,10 +113,6 @@ #define CONFIG_SYS_MAX_FLASH_SECT 512 /* environments */ -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 50000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SECT_SIZE 0x1000 #define CONFIG_ENV_OVERWRITE diff --git a/include/configs/bav335x.h b/include/configs/bav335x.h index 89362229f9..fb9c2a6d04 100644 --- a/include/configs/bav335x.h +++ b/include/configs/bav335x.h @@ -453,7 +453,6 @@ DEFAULT_LINUX_BOOT_ENV \ #define CONFIG_SYS_SPI_U_BOOT_OFFS 0x20000 #define CONFIG_SYS_REDUNDAND_ENVIRONMENT -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_ENV_SECT_SIZE (4 << 10) /* 4 KB sectors */ #define CONFIG_ENV_OFFSET (768 << 10) /* 768 KiB in */ #define CONFIG_ENV_OFFSET_REDUND (896 << 10) /* 896 KiB in */ diff --git a/include/configs/bg0900.h b/include/configs/bg0900.h index 0c3d54a082..832dbbaafc 100644 --- a/include/configs/bg0900.h +++ b/include/configs/bg0900.h @@ -21,10 +21,6 @@ /* SPI FLASH */ #ifdef CONFIG_CMD_SF -#define CONFIG_ENV_SPI_BUS 2 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 40000000 -#define CONFIG_ENV_SPI_MODE SPI_MODE_0 #endif /* Boot Linux */ diff --git a/include/configs/brppt1.h b/include/configs/brppt1.h index 2219663f2e..ae9b75bb87 100644 --- a/include/configs/brppt1.h +++ b/include/configs/brppt1.h @@ -190,7 +190,6 @@ NANDTGTS \ #define CONFIG_SYS_SPI_U_BOOT_OFFS 0x40000 /* Environment */ #define CONFIG_SYS_REDUNDAND_ENVIRONMENT -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_ENV_SECT_SIZE CONFIG_ENV_SIZE #define CONFIG_ENV_OFFSET 0x20000 #define CONFIG_ENV_OFFSET_REDUND (CONFIG_ENV_OFFSET + \ diff --git a/include/configs/cgtqmx6eval.h b/include/configs/cgtqmx6eval.h index ab8d1c64c0..ad0a64a936 100644 --- a/include/configs/cgtqmx6eval.h +++ b/include/configs/cgtqmx6eval.h @@ -217,10 +217,6 @@ #if defined(CONFIG_ENV_IS_IN_SPI_FLASH) #define CONFIG_ENV_OFFSET (768 * 1024) #define CONFIG_ENV_SECT_SIZE (64 * 1024) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #endif #endif /* __CONFIG_CGTQMX6EVAL_H */ diff --git a/include/configs/cl-som-am57x.h b/include/configs/cl-som-am57x.h index 687a9e703c..bf2bb44d48 100644 --- a/include/configs/cl-som-am57x.h +++ b/include/configs/cl-som-am57x.h @@ -42,7 +42,6 @@ #define CONFIG_ENV_SECT_SIZE (64 * 1024) #define CONFIG_ENV_OFFSET (768 * 1024) -#define CONFIG_ENV_SPI_MAX_HZ 48000000 /* EEPROM */ #define CONFIG_SYS_I2C_EEPROM_ADDR 0x50 diff --git a/include/configs/cl-som-imx7.h b/include/configs/cl-som-imx7.h index d895f89c82..26d1a97891 100644 --- a/include/configs/cl-som-imx7.h +++ b/include/configs/cl-som-imx7.h @@ -145,10 +145,6 @@ #define CONFIG_ENV_SIZE SZ_8K #define CONFIG_ENV_OFFSET (768 * 1024) #define CONFIG_ENV_SECT_SIZE (64 * 1024) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED /* MMC Config*/ #define CONFIG_FSL_USDHC diff --git a/include/configs/cm_fx6.h b/include/configs/cm_fx6.h index 2ac888f9f8..dfd96ff8d5 100644 --- a/include/configs/cm_fx6.h +++ b/include/configs/cm_fx6.h @@ -46,10 +46,6 @@ #endif /* Environment */ -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS #define CONFIG_ENV_SECT_SIZE (64 * 1024) #define CONFIG_ENV_SIZE (8 * 1024) #define CONFIG_ENV_OFFSET (768 * 1024) diff --git a/include/configs/cm_t43.h b/include/configs/cm_t43.h index 6df8b8b2a7..ffe4a44c86 100644 --- a/include/configs/cm_t43.h +++ b/include/configs/cm_t43.h @@ -85,7 +85,6 @@ #define CONFIG_ENV_SECT_SIZE (64 * 1024) #define CONFIG_ENV_OFFSET (768 * 1024) -#define CONFIG_ENV_SPI_MAX_HZ 48000000 #define CONFIG_EXTRA_ENV_SETTINGS \ "loadaddr=0x80200000\0" \ diff --git a/include/configs/controlcenterd.h b/include/configs/controlcenterd.h index 69c65f19ed..f1c3522c68 100644 --- a/include/configs/controlcenterd.h +++ b/include/configs/controlcenterd.h @@ -275,10 +275,6 @@ #if defined(CONFIG_TRAILBLAZER) #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #elif defined(CONFIG_RAMBOOT_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/controlcenterdc.h b/include/configs/controlcenterdc.h index edd8749d74..91308377c2 100644 --- a/include/configs/controlcenterdc.h +++ b/include/configs/controlcenterdc.h @@ -43,7 +43,6 @@ #define CONFIG_EHCI_IS_TDI /* Environment in SPI NOR flash */ -#define CONFIG_ENV_SPI_BUS 1 #define CONFIG_ENV_OFFSET (1 << 20) /* 1MiB in */ #define CONFIG_ENV_SIZE (64 << 10) /* 64KiB */ #define CONFIG_ENV_SECT_SIZE (256 << 10) /* 256KiB sectors */ diff --git a/include/configs/corenet_ds.h b/include/configs/corenet_ds.h index a3963db628..f974291eac 100644 --- a/include/configs/corenet_ds.h +++ b/include/configs/corenet_ds.h @@ -60,10 +60,6 @@ #define CONFIG_ENV_OVERWRITE #if defined(CONFIG_SPIFLASH) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/da850evm.h b/include/configs/da850evm.h index 7b1e53f767..583f994807 100644 --- a/include/configs/da850evm.h +++ b/include/configs/da850evm.h @@ -124,8 +124,6 @@ #ifdef CONFIG_SPL_BUILD #define CONFIG_SYS_SPI_BASE DAVINCI_SPI1_BASE #endif -#define CONFIG_ENV_SPI_MAX_HZ 0 -#define CONFIG_ENV_SPI_MODE 0 #ifdef CONFIG_USE_SPIFLASH #define CONFIG_SYS_SPI_U_BOOT_OFFS 0x8000 diff --git a/include/configs/db-88f6820-amc.h b/include/configs/db-88f6820-amc.h index 222bdf81f6..f1bdc2d3e7 100644 --- a/include/configs/db-88f6820-amc.h +++ b/include/configs/db-88f6820-amc.h @@ -22,7 +22,6 @@ #define CONFIG_EHCI_IS_TDI /* Environment in SPI NOR flash */ -#define CONFIG_ENV_SPI_BUS 1 #define CONFIG_ENV_OFFSET (1 << 20) /* 1MiB in */ #define CONFIG_ENV_SIZE (64 << 10) /* 64KiB */ #define CONFIG_ENV_SECT_SIZE (256 << 10) /* 256KiB sectors */ diff --git a/include/configs/db-88f6820-gp.h b/include/configs/db-88f6820-gp.h index 967b133436..d378052a8f 100644 --- a/include/configs/db-88f6820-gp.h +++ b/include/configs/db-88f6820-gp.h @@ -26,8 +26,6 @@ /* * SPI Flash configuration for the environemnt access */ -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 /* SPI NOR flash default params, used by sf commands */ diff --git a/include/configs/dh_imx6.h b/include/configs/dh_imx6.h index 1c1178c342..48514ff076 100644 --- a/include/configs/dh_imx6.h +++ b/include/configs/dh_imx6.h @@ -163,10 +163,6 @@ #define CONFIG_ENV_OFFSET_REDUND \ (CONFIG_ENV_OFFSET + CONFIG_ENV_SECT_SIZE) #define CONFIG_ENV_SIZE_REDUND CONFIG_ENV_SIZE -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #endif #endif /* __DH_IMX6_CONFIG_H */ diff --git a/include/configs/display5.h b/include/configs/display5.h index d729054eb8..8ab47abfa8 100644 --- a/include/configs/display5.h +++ b/include/configs/display5.h @@ -374,11 +374,6 @@ #define CONFIG_ENV_OFFSET_REDUND (CONFIG_ENV_OFFSET + \ CONFIG_ENV_SECT_SIZE) #define CONFIG_ENV_SIZE_REDUND CONFIG_ENV_SIZE - -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #endif #define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW) diff --git a/include/configs/dra7xx_evm.h b/include/configs/dra7xx_evm.h index 36e15824a1..10eac20aa0 100644 --- a/include/configs/dra7xx_evm.h +++ b/include/configs/dra7xx_evm.h @@ -91,7 +91,6 @@ #define CONFIG_SYS_SPI_ARGS_SIZE 0x80000 #if defined(CONFIG_QSPI_BOOT) #define CONFIG_SYS_REDUNDAND_ENVIRONMENT -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_ENV_SIZE (64 << 10) #define CONFIG_ENV_SECT_SIZE (64 << 10) /* 64 KB sectors */ #define CONFIG_ENV_OFFSET 0x1C0000 diff --git a/include/configs/dreamplug.h b/include/configs/dreamplug.h index f4d717213c..28bda14c3d 100644 --- a/include/configs/dreamplug.h +++ b/include/configs/dreamplug.h @@ -35,9 +35,6 @@ #endif #ifdef CONFIG_CMD_SF -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 50000000 /* 50 MHz */ #endif /* diff --git a/include/configs/ds109.h b/include/configs/ds109.h index 2c7928e88c..07367cfef0 100644 --- a/include/configs/ds109.h +++ b/include/configs/ds109.h @@ -38,9 +38,6 @@ #endif #ifdef CONFIG_CMD_SF -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 50000000 /* 50 MHz */ #endif /* diff --git a/include/configs/ea20.h b/include/configs/ea20.h index 800ce03931..88f2e17d40 100644 --- a/include/configs/ea20.h +++ b/include/configs/ea20.h @@ -52,7 +52,6 @@ #define CONFIG_SYS_SPI_BASE DAVINCI_SPI1_BASE #define CONFIG_SYS_SPI_CLK clk_get(DAVINCI_SPI1_CLKID) -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED /* * I2C Configuration diff --git a/include/configs/embestmx6boards.h b/include/configs/embestmx6boards.h index f98454012d..5142680e7d 100644 --- a/include/configs/embestmx6boards.h +++ b/include/configs/embestmx6boards.h @@ -83,10 +83,6 @@ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_ENV_OFFSET (768 * 1024) #define CONFIG_ENV_SECT_SIZE (8 * 1024) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #endif /* Framebuffer */ diff --git a/include/configs/ethernut5.h b/include/configs/ethernut5.h index 0d84c97b98..b86b54209c 100644 --- a/include/configs/ethernut5.h +++ b/include/configs/ethernut5.h @@ -54,7 +54,6 @@ #define CONFIG_ENV_OFFSET 0x3DE000 #define CONFIG_ENV_SIZE (132 << 10) #define CONFIG_ENV_SECT_SIZE CONFIG_ENV_SIZE -#define CONFIG_ENV_SPI_MAX_HZ 15000000 /* NAND flash */ #ifdef CONFIG_CMD_NAND diff --git a/include/configs/exynos5-common.h b/include/configs/exynos5-common.h index 5641f09a4a..db1fc934bb 100644 --- a/include/configs/exynos5-common.h +++ b/include/configs/exynos5-common.h @@ -110,10 +110,7 @@ /* SPI */ #ifdef CONFIG_ENV_IS_IN_SPI_FLASH -#define CONFIG_ENV_SPI_MODE SPI_MODE_0 #define CONFIG_ENV_SECT_SIZE CONFIG_ENV_SIZE -#define CONFIG_ENV_SPI_BUS 1 -#define CONFIG_ENV_SPI_MAX_HZ 50000000 #endif /* Ethernet Controllor Driver */ diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 9ca3ee3920..3336578071 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -172,10 +172,6 @@ #define CONFIG_ENV_SIZE (8 * 1024) #define CONFIG_ENV_OFFSET (768 * 1024) #define CONFIG_ENV_SECT_SIZE (64 * 1024) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_SYS_FSL_USDHC_NUM 3 diff --git a/include/configs/gw_ventana.h b/include/configs/gw_ventana.h index a4215c87cf..84ee44e872 100644 --- a/include/configs/gw_ventana.h +++ b/include/configs/gw_ventana.h @@ -181,10 +181,6 @@ #define CONFIG_ENV_OFFSET (512 * SZ_1K) #define CONFIG_ENV_SECT_SIZE (64 * SZ_1K) #define CONFIG_ENV_SIZE (8 * SZ_1K) - #define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS - #define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS - #define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE - #define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #endif /* Environment */ diff --git a/include/configs/helios4.h b/include/configs/helios4.h index 5a11641315..df4d8bcb3b 100644 --- a/include/configs/helios4.h +++ b/include/configs/helios4.h @@ -45,13 +45,6 @@ CONFIG_SYS_SCSI_MAX_LUN) #ifdef CONFIG_MVEBU_SPL_BOOT_DEVICE_SPI -/* - * SPI Flash configuration for the environment access - */ -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED - /* Environment in SPI NOR flash */ #define CONFIG_ENV_SECT_SIZE SZ_64K #define CONFIG_ENV_SIZE CONFIG_ENV_SECT_SIZE diff --git a/include/configs/km/km_arm.h b/include/configs/km/km_arm.h index f93629ecc9..a2e9cf1fa5 100644 --- a/include/configs/km/km_arm.h +++ b/include/configs/km/km_arm.h @@ -35,10 +35,6 @@ /* SPI NOR Flash default params, used by sf commands */ #if defined CONFIG_KM_ENV_IS_IN_SPI_NOR -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 8100000 -#define CONFIG_ENV_SPI_MODE SPI_MODE_3 #endif /* Reserve 4 MB for malloc */ diff --git a/include/configs/km/kmp204x-common.h b/include/configs/km/kmp204x-common.h index 37b9abc7b2..a52d1df120 100644 --- a/include/configs/km/kmp204x-common.h +++ b/include/configs/km/kmp204x-common.h @@ -39,10 +39,6 @@ #define CONFIG_SYS_DPAA_RMAN /* RMan */ /* Environment in SPI Flash */ -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 20000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_OFFSET 0x100000 /* 1MB for u-boot */ #define CONFIG_ENV_SIZE 0x004000 /* 16K env */ #define CONFIG_ENV_SECT_SIZE 0x010000 diff --git a/include/configs/lacie_kw.h b/include/configs/lacie_kw.h index 1f619a0d27..1ba28b501f 100644 --- a/include/configs/lacie_kw.h +++ b/include/configs/lacie_kw.h @@ -65,10 +65,8 @@ #include "mv-common.h" /* Remove or override few declarations from mv-common.h */ -#undef CONFIG_ENV_SPI_MAX_HZ #undef CONFIG_SYS_IDE_MAXBUS #undef CONFIG_SYS_IDE_MAXDEVICE -#define CONFIG_ENV_SPI_MAX_HZ 20000000 /* 20Mhz */ /* * Enable platform initialisation via misc_init_r() function diff --git a/include/configs/legoev3.h b/include/configs/legoev3.h index ce806d162a..1e239ecadd 100644 --- a/include/configs/legoev3.h +++ b/include/configs/legoev3.h @@ -47,7 +47,6 @@ #define CONFIG_SYS_SPI_BASE DAVINCI_SPI0_BASE #define CONFIG_SYS_SPI_CLK clk_get(DAVINCI_SPI0_CLKID) -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED /* * I2C Configuration diff --git a/include/configs/ls1012a_common.h b/include/configs/ls1012a_common.h index 04639c175f..3a42210c6e 100644 --- a/include/configs/ls1012a_common.h +++ b/include/configs/ls1012a_common.h @@ -40,10 +40,6 @@ #if defined(CONFIG_QSPI_BOOT) || defined(CONFIG_TFABOOT) #define CONFIG_SYS_QE_FW_IN_SPIFLASH #define CONFIG_SYS_FMAN_FW_ADDR 0x400d0000 -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 1000000 -#define CONFIG_ENV_SPI_MODE 0x03 #define CONFIG_SPI_FLASH_SPANSION #define CONFIG_FSL_SPI_INTERFACE #define CONFIG_SF_DATAFLASH diff --git a/include/configs/ls1043a_common.h b/include/configs/ls1043a_common.h index bc804c531e..2e9d476483 100644 --- a/include/configs/ls1043a_common.h +++ b/include/configs/ls1043a_common.h @@ -186,10 +186,6 @@ #define CONFIG_SYS_FMAN_FW_ADDR 0x900000 #define CONFIG_SYS_QE_FW_ADDR 0x940000 -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 1000000 -#define CONFIG_ENV_SPI_MODE 0x03 #else #ifdef CONFIG_NAND_BOOT @@ -208,10 +204,6 @@ #elif defined(CONFIG_QSPI_BOOT) #define CONFIG_SYS_QE_FW_IN_SPIFLASH #define CONFIG_SYS_FMAN_FW_ADDR 0x40900000 -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 1000000 -#define CONFIG_ENV_SPI_MODE 0x03 #else #define CONFIG_SYS_QE_FMAN_FW_IN_NOR /* FMan fireware Pre-load address */ diff --git a/include/configs/ls1046a_common.h b/include/configs/ls1046a_common.h index d9fcd3af5e..24ff2d1547 100644 --- a/include/configs/ls1046a_common.h +++ b/include/configs/ls1046a_common.h @@ -170,10 +170,6 @@ #ifdef CONFIG_TFABOOT #define CONFIG_SYS_FMAN_FW_ADDR 0x900000 -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 1000000 -#define CONFIG_ENV_SPI_MODE 0x03 #else #ifdef CONFIG_SD_BOOT /* @@ -186,10 +182,6 @@ #elif defined(CONFIG_QSPI_BOOT) #define CONFIG_SYS_QE_FW_IN_SPIFLASH #define CONFIG_SYS_FMAN_FW_ADDR 0x40900000 -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 1000000 -#define CONFIG_ENV_SPI_MODE 0x03 #elif defined(CONFIG_NAND_BOOT) #define CONFIG_SYS_QE_FMAN_FW_IN_NAND #define CONFIG_SYS_FMAN_FW_ADDR (36 * CONFIG_SYS_NAND_BLOCK_SIZE) diff --git a/include/configs/lsxl.h b/include/configs/lsxl.h index bcad8a030d..72e62658d0 100644 --- a/include/configs/lsxl.h +++ b/include/configs/lsxl.h @@ -45,10 +45,6 @@ /* loading initramfs images without uimage header */ -/* ST M25P40 */ -#undef CONFIG_ENV_SPI_MAX_HZ -#define CONFIG_ENV_SPI_MAX_HZ 25000000 - /* * Environment variables configurations */ diff --git a/include/configs/meesc.h b/include/configs/meesc.h index 0a03a2f5c7..a1fd5f6195 100644 --- a/include/configs/meesc.h +++ b/include/configs/meesc.h @@ -99,7 +99,6 @@ #define CONFIG_ENV_OFFSET 0x4200 #define CONFIG_ENV_SIZE 0x4200 #define CONFIG_ENV_SECT_SIZE 0x210 -#define CONFIG_ENV_SPI_MAX_HZ 15000000 #elif CONFIG_SYS_USE_NANDFLASH diff --git a/include/configs/microblaze-generic.h b/include/configs/microblaze-generic.h index d81194bb43..d1ab40ec13 100644 --- a/include/configs/microblaze-generic.h +++ b/include/configs/microblaze-generic.h @@ -86,9 +86,6 @@ # define CONFIG_ENV_ADDR (CONFIG_SYS_MONITOR_BASE - CONFIG_ENV_SIZE) # else /* SPIFLASH && !RAMENV */ -# define CONFIG_ENV_SPI_MODE SPI_MODE_3 -# define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED -# define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS /* 128K(two sectors) for env */ # define CONFIG_ENV_SECT_SIZE 0x10000 # define CONFIG_ENV_SIZE (2 * CONFIG_ENV_SECT_SIZE) diff --git a/include/configs/mvebu_armada-37xx.h b/include/configs/mvebu_armada-37xx.h index e8981334ae..10b94f438f 100644 --- a/include/configs/mvebu_armada-37xx.h +++ b/include/configs/mvebu_armada-37xx.h @@ -57,11 +57,7 @@ /* * SPI Flash configuration */ -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -/* SPI NOR flash default params, used by sf commands */ -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE #define CONFIG_MTD_DEVICE /* needed for mtdparts commands */ #define CONFIG_MTD_PARTITIONS /* required for UBI partition support */ diff --git a/include/configs/mvebu_armada-8k.h b/include/configs/mvebu_armada-8k.h index 51f484d2e7..f4972b64dc 100644 --- a/include/configs/mvebu_armada-8k.h +++ b/include/configs/mvebu_armada-8k.h @@ -52,11 +52,6 @@ /* * SPI Flash configuration */ -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 - -/* SPI NOR flash default params, used by sf commands */ -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE #define CONFIG_ENV_OFFSET 0x180000 /* as Marvell U-Boot version */ #define CONFIG_ENV_SIZE (64 << 10) /* 64KiB */ diff --git a/include/configs/mx28evk.h b/include/configs/mx28evk.h index a078e3a0b8..dd045804ae 100644 --- a/include/configs/mx28evk.h +++ b/include/configs/mx28evk.h @@ -48,10 +48,6 @@ #define CONFIG_ENV_OFFSET 0x40000 /* 256K */ #define CONFIG_ENV_OFFSET_REDUND (CONFIG_ENV_OFFSET + CONFIG_ENV_SIZE) #define CONFIG_ENV_SECT_SIZE 0x1000 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_BUS 2 -#define CONFIG_ENV_SPI_MAX_HZ 24000000 -#define CONFIG_ENV_SPI_MODE SPI_MODE_0 #endif /* UBI and NAND partitioning */ diff --git a/include/configs/mx6slevk.h b/include/configs/mx6slevk.h index 2cce3d5d9e..5d649f6e2f 100644 --- a/include/configs/mx6slevk.h +++ b/include/configs/mx6slevk.h @@ -136,10 +136,6 @@ #if defined CONFIG_SPI_BOOT #define CONFIG_ENV_OFFSET (768 * 1024) #define CONFIG_ENV_SECT_SIZE (64 * 1024) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #else #define CONFIG_ENV_OFFSET (8 * SZ_64K) #endif diff --git a/include/configs/nitrogen6x.h b/include/configs/nitrogen6x.h index c37a766368..d941caa905 100644 --- a/include/configs/nitrogen6x.h +++ b/include/configs/nitrogen6x.h @@ -158,10 +158,6 @@ #elif defined(CONFIG_ENV_IS_IN_SPI_FLASH) #define CONFIG_ENV_OFFSET (768 * 1024) #define CONFIG_ENV_SECT_SIZE (8 * 1024) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #endif /* diff --git a/include/configs/omapl138_lcdk.h b/include/configs/omapl138_lcdk.h index 5f5aa57a4b..1786e099ad 100644 --- a/include/configs/omapl138_lcdk.h +++ b/include/configs/omapl138_lcdk.h @@ -119,7 +119,6 @@ #define CONFIG_SYS_SPI_BASE DAVINCI_SPI1_BASE #define CONFIG_SYS_SPI_CLK clk_get(DAVINCI_SPI1_CLKID) -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #ifdef CONFIG_USE_SPIFLASH #define CONFIG_SYS_SPI_U_BOOT_OFFS 0x8000 diff --git a/include/configs/ot1200.h b/include/configs/ot1200.h index 67541819cd..925e7ae3db 100644 --- a/include/configs/ot1200.h +++ b/include/configs/ot1200.h @@ -99,10 +99,6 @@ #define CONFIG_ENV_OFFSET (1024 * 1024) /* M25P16 has an erase size of 64 KiB */ #define CONFIG_ENV_SECT_SIZE (64 * 1024) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_BOOTP_SERVERIP #define CONFIG_BOOTP_BOOTFILE diff --git a/include/configs/p1_p2_rdb_pc.h b/include/configs/p1_p2_rdb_pc.h index 24003c2b1c..8fa91fb81d 100644 --- a/include/configs/p1_p2_rdb_pc.h +++ b/include/configs/p1_p2_rdb_pc.h @@ -700,10 +700,6 @@ * Environment */ #ifdef CONFIG_SPIFLASH -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MAX_HZ 10000000 -#define CONFIG_ENV_SPI_MODE 0 #define CONFIG_ENV_SIZE 0x2000 /* 8KB */ #define CONFIG_ENV_OFFSET 0x100000 /* 1MB */ #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/pcm058.h b/include/configs/pcm058.h index 15dc1b2dbe..b0415b28ad 100644 --- a/include/configs/pcm058.h +++ b/include/configs/pcm058.h @@ -78,10 +78,6 @@ #define CONFIG_ENV_SIZE (16 * 1024) #define CONFIG_ENV_OFFSET (1024 * SZ_1K) #define CONFIG_ENV_SECT_SIZE (64 * SZ_1K) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_SYS_REDUNDAND_ENVIRONMENT #define CONFIG_ENV_OFFSET_REDUND (CONFIG_ENV_OFFSET + \ CONFIG_ENV_SECT_SIZE) diff --git a/include/configs/pfla02.h b/include/configs/pfla02.h index fe54e54595..3a9b85acd8 100644 --- a/include/configs/pfla02.h +++ b/include/configs/pfla02.h @@ -79,10 +79,6 @@ #define CONFIG_ENV_SIZE (16 * 1024) #define CONFIG_ENV_OFFSET (1024 * SZ_1K) #define CONFIG_ENV_SECT_SIZE (64 * SZ_1K) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_SYS_REDUNDAND_ENVIRONMENT #define CONFIG_ENV_OFFSET_REDUND (CONFIG_ENV_OFFSET + \ CONFIG_ENV_SECT_SIZE) diff --git a/include/configs/pm9261.h b/include/configs/pm9261.h index e88948c7f5..c1ce12217a 100644 --- a/include/configs/pm9261.h +++ b/include/configs/pm9261.h @@ -207,7 +207,6 @@ #define CONFIG_ENV_OFFSET 0x4200 #define CONFIG_ENV_SIZE 0x4200 #define CONFIG_ENV_SECT_SIZE 0x210 -#define CONFIG_ENV_SPI_MAX_HZ 15000000 #define CONFIG_BOOTCOMMAND "sf probe 0; " \ "sf read 0x22000000 0x84000 0x210000; " \ "bootm 0x22000000" diff --git a/include/configs/pm9263.h b/include/configs/pm9263.h index f11879b4e9..b09d8515d3 100644 --- a/include/configs/pm9263.h +++ b/include/configs/pm9263.h @@ -236,7 +236,6 @@ #define CONFIG_ENV_OFFSET 0x4200 #define CONFIG_ENV_SIZE 0x4200 #define CONFIG_ENV_SECT_SIZE 0x210 -#define CONFIG_ENV_SPI_MAX_HZ 15000000 #define CONFIG_BOOTCOMMAND "sf probe 0; " \ "sf read 0x22000000 0x84000 0x294000; " \ "bootm 0x22000000" diff --git a/include/configs/puma_rk3399.h b/include/configs/puma_rk3399.h index 45a4ccc18f..4d6085d2dd 100644 --- a/include/configs/puma_rk3399.h +++ b/include/configs/puma_rk3399.h @@ -12,10 +12,6 @@ #define CONFIG_SYS_MMC_ENV_DEV 1 #elif defined(CONFIG_ENV_IS_IN_SPI_FLASH) #define CONFIG_ENV_SECT_SIZE (8 * 1024) -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #endif #define SDRAM_BANK_SIZE (2UL << 30) diff --git a/include/configs/siemens-am33x-common.h b/include/configs/siemens-am33x-common.h index 8f2dd5f4d6..f44a4280f4 100644 --- a/include/configs/siemens-am33x-common.h +++ b/include/configs/siemens-am33x-common.h @@ -179,7 +179,6 @@ * 0x442000 - 0x800000 : Userland */ #if defined(CONFIG_SPI_BOOT) -# define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED # define CONFIG_ENV_OFFSET (892 << 10) /* 892 KiB in */ # define CONFIG_ENV_SECT_SIZE (4 << 10) /* 4 KB sectors */ #endif /* SPI support */ diff --git a/include/configs/socfpga_sr1500.h b/include/configs/socfpga_sr1500.h index d9de07543d..b6a98611c0 100644 --- a/include/configs/socfpga_sr1500.h +++ b/include/configs/socfpga_sr1500.h @@ -35,10 +35,6 @@ #define CONFIG_ENV_SIZE (16 * 1024) #define CONFIG_ENV_OFFSET 0x000e0000 #define CONFIG_ENV_OFFSET_REDUND (CONFIG_ENV_OFFSET + CONFIG_ENV_SECT_SIZE) -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 -#define CONFIG_ENV_SPI_MODE SPI_MODE_3 -#define CONFIG_ENV_SPI_MAX_HZ 100000000 /* Use max of 100MHz */ /* * The QSPI NOR flash layout on SR1500: diff --git a/include/configs/stmark2.h b/include/configs/stmark2.h index fa3d6b8a7b..17f92d89c9 100644 --- a/include/configs/stmark2.h +++ b/include/configs/stmark2.h @@ -65,8 +65,6 @@ /* DSPI and Serial Flash */ #define CONFIG_CF_DSPI #define CONFIG_SERIAL_FLASH -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 1 #define CONFIG_SYS_SBFHDR_SIZE 0x7 @@ -152,7 +150,6 @@ #if defined(CONFIG_CF_SBF) #define CONFIG_ENV_IS_IN_SPI_FLASH 1 -#define CONFIG_ENV_SPI_CS 1 #define CONFIG_ENV_OFFSET 0x40000 #define CONFIG_ENV_SIZE 0x2000 #define CONFIG_ENV_SECT_SIZE 0x10000 diff --git a/include/configs/ti_armv7_keystone2.h b/include/configs/ti_armv7_keystone2.h index 767615a085..fb8c082c1d 100644 --- a/include/configs/ti_armv7_keystone2.h +++ b/include/configs/ti_armv7_keystone2.h @@ -71,7 +71,6 @@ /* SPI Configuration */ #define CONFIG_SYS_SPI_CLK ks_clk_get_rate(KS2_CLK1_6) -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #define CONFIG_SYS_SPI0 #define CONFIG_SYS_SPI_BASE KS2_SPI0_BASE #define CONFIG_SYS_SPI0_NUM_CS 4 diff --git a/include/configs/topic_miami.h b/include/configs/topic_miami.h index c4f01aac59..69aa79bafc 100644 --- a/include/configs/topic_miami.h +++ b/include/configs/topic_miami.h @@ -48,7 +48,6 @@ #define CONFIG_SYS_MEMTEST_END 0x18000000 /* Faster flash, ours may run at 108 MHz */ -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED #undef CONFIG_SPI_FLASH_WINBOND /* Setup proper boot sequences for Miami boards */ diff --git a/include/configs/tqma6.h b/include/configs/tqma6.h index 6c0d4f2008..13e3d60bfe 100644 --- a/include/configs/tqma6.h +++ b/include/configs/tqma6.h @@ -154,11 +154,6 @@ #define CONFIG_ENV_OFFSET_REDUND (CONFIG_ENV_OFFSET + \ CONFIG_ENV_SECT_SIZE) -#define CONFIG_ENV_SPI_BUS (CONFIG_SF_DEFAULT_BUS) -#define CONFIG_ENV_SPI_CS (CONFIG_SF_DEFAULT_CS) -#define CONFIG_ENV_SPI_MAX_HZ (CONFIG_SF_DEFAULT_SPEED) -#define CONFIG_ENV_SPI_MODE (CONFIG_SF_DEFAULT_MODE) - #define TQMA6_FDT_OFFSET (CONFIG_ENV_OFFSET_REDUND + \ CONFIG_ENV_SECT_SIZE) #define TQMA6_FDT_SECT_SIZE (TQMA6_SPI_FLASH_SECTOR_SIZE) diff --git a/include/configs/trimslice.h b/include/configs/trimslice.h index 417c562e62..93db175288 100644 --- a/include/configs/trimslice.h +++ b/include/configs/trimslice.h @@ -23,8 +23,6 @@ /* SPI */ /* Environment in SPI */ -#define CONFIG_ENV_SPI_MAX_HZ 48000000 -#define CONFIG_ENV_SPI_MODE SPI_MODE_0 #define CONFIG_ENV_SECT_SIZE CONFIG_ENV_SIZE /* 1MiB flash, environment located as high as possible */ #define CONFIG_ENV_OFFSET (SZ_1M - CONFIG_ENV_SIZE) diff --git a/include/configs/turris_mox.h b/include/configs/turris_mox.h index 648c87dfa8..5d5394e3e5 100644 --- a/include/configs/turris_mox.h +++ b/include/configs/turris_mox.h @@ -66,11 +66,6 @@ /* * SPI Flash configuration */ -#define CONFIG_ENV_SPI_BUS 0 -#define CONFIG_ENV_SPI_CS 0 - -/* SPI NOR flash default params, used by sf commands */ -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE /* Environment in SPI NOR flash */ #define CONFIG_ENV_OFFSET 0x180000 /* as Marvell U-Boot version */ diff --git a/include/configs/usb_a9263.h b/include/configs/usb_a9263.h index aa8738fe73..fa38274d56 100644 --- a/include/configs/usb_a9263.h +++ b/include/configs/usb_a9263.h @@ -82,7 +82,6 @@ #define CONFIG_ENV_OFFSET 0x2000 #define CONFIG_ENV_SIZE 0x2000 #define CONFIG_ENV_SECT_SIZE CONFIG_ENV_SIZE -#define CONFIG_ENV_SPI_MAX_HZ 15000000 #define CONFIG_BOOTCOMMAND "nboot 21000000 0" #define CONFIG_EXTRA_ENV_SETTINGS \ "mtdparts=" CONFIG_MTDPARTS_DEFAULT "\0" \ diff --git a/include/configs/vcoreiii.h b/include/configs/vcoreiii.h index 8c30c6f09a..2840c7b815 100644 --- a/include/configs/vcoreiii.h +++ b/include/configs/vcoreiii.h @@ -34,8 +34,6 @@ #define CONFIG_ENV_SIZE_REDUND CONFIG_ENV_SIZE #define CONFIG_ENV_OFFSET_REDUND (CONFIG_ENV_OFFSET + CONFIG_ENV_SECT_SIZE) -#define CONFIG_ENV_SPI_MAX_HZ 0 /* This force to read from DT */ -#define CONFIG_ENV_SPI_MODE 0 /* This force to read from DT */ #endif #define CONFIG_SYS_SDRAM_BASE 0x80000000 diff --git a/include/configs/vinco.h b/include/configs/vinco.h index 715ef2a739..ec22a30cda 100644 --- a/include/configs/vinco.h +++ b/include/configs/vinco.h @@ -38,8 +38,6 @@ #ifdef CONFIG_CMD_SF #define CONFIG_ATMEL_SPI0 #define CONFIG_SPI_FLASH_STMICRO -#define CONFIG_ENV_SPI_MAX_HZ 50000000 -#define CONFIG_ENV_SPI_MODE (SPI_MODE_0) #endif /* MMC */ @@ -65,8 +63,6 @@ #ifdef CONFIG_SPI_BOOT /* bootstrap + u-boot + env + linux in serial flash */ -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS /* Use our own mapping for the VInCo platform */ #undef CONFIG_ENV_OFFSET #undef CONFIG_ENV_SIZE diff --git a/include/configs/x530.h b/include/configs/x530.h index d9c1eff9e0..80c898ef7c 100644 --- a/include/configs/x530.h +++ b/include/configs/x530.h @@ -60,8 +60,6 @@ #define CONFIG_EHCI_IS_TDI /* Environment in SPI NOR flash */ -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE #define CONFIG_ENV_OFFSET (1 << 20) /* 1MiB in */ #define CONFIG_ENV_SIZE (64 << 10) /* 64KiB */ #define CONFIG_ENV_SECT_SIZE (256 << 10) /* 256KiB sectors */ diff --git a/include/spi_flash.h b/include/spi_flash.h index 97ec2b3e58..55b4721813 100644 --- a/include/spi_flash.h +++ b/include/spi_flash.h @@ -13,6 +13,20 @@ #include #include +/* by default ENV use the same parameters than SF command */ +#ifndef CONFIG_ENV_SPI_BUS +# define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS +#endif +#ifndef CONFIG_ENV_SPI_CS +# define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS +#endif +#ifndef CONFIG_ENV_SPI_MAX_HZ +# define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED +#endif +#ifndef CONFIG_ENV_SPI_MODE +# define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE +#endif + struct spi_slave; struct dm_spi_flash_ops {