Convert CONFIG_ENV_SPI_* to Kconfig
authorPatrick Delaunay <patrick.delaunay@st.com>
Wed, 27 Feb 2019 14:20:38 +0000 (15:20 +0100)
committerTom Rini <trini@konsulko.com>
Mon, 25 Mar 2019 21:36:59 +0000 (17:36 -0400)
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 <patrick.delaunay@st.com>
165 files changed:
arch/arm/mach-kirkwood/include/mach/config.h
arch/arm/mach-mvebu/include/mach/config.h
configs/M52277EVB_stmicro_defconfig
configs/M54418TWR_defconfig
configs/M54418TWR_serial_mii_defconfig
configs/M54418TWR_serial_rmii_defconfig
configs/M54451EVB_stmicro_defconfig
configs/M54455EVB_stm33_defconfig
configs/SBx81LIFKW_defconfig
configs/SBx81LIFXCAT_defconfig
configs/ap121_defconfig
configs/ap143_defconfig
configs/at91sam9260ek_dataflash_cs0_defconfig
configs/at91sam9260ek_dataflash_cs1_defconfig
configs/at91sam9261ek_dataflash_cs0_defconfig
configs/at91sam9261ek_dataflash_cs3_defconfig
configs/at91sam9263ek_dataflash_cs0_defconfig
configs/at91sam9263ek_dataflash_defconfig
configs/at91sam9g10ek_dataflash_cs0_defconfig
configs/at91sam9g10ek_dataflash_cs3_defconfig
configs/at91sam9g20ek_dataflash_cs0_defconfig
configs/at91sam9g20ek_dataflash_cs1_defconfig
configs/at91sam9rlek_dataflash_defconfig
configs/at91sam9xeek_dataflash_cs0_defconfig
configs/at91sam9xeek_dataflash_cs1_defconfig
configs/controlcenterdc_defconfig
configs/d2net_v2_defconfig
configs/da850_am18xxevm_defconfig
configs/da850evm_defconfig
configs/db-88f6720_defconfig
configs/db-88f6820-amc_defconfig
configs/db-88f6820-gp_defconfig
configs/db-mv784mp-gp_defconfig
configs/dreamplug_defconfig
configs/ds109_defconfig
configs/ds414_defconfig
configs/ethernut5_defconfig
configs/inetspace_v2_defconfig
configs/ls1012aqds_qspi_defconfig
configs/ls1012aqds_tfa_defconfig
configs/ls1043aqds_tfa_defconfig
configs/ls1046aqds_tfa_defconfig
configs/maxbcm_defconfig
configs/meesc_dataflash_defconfig
configs/mscc_jr2_defconfig
configs/mscc_luton_defconfig
configs/mscc_ocelot_defconfig
configs/mscc_serval_defconfig
configs/mscc_servalt_defconfig
configs/net2big_v2_defconfig
configs/netspace_lite_v2_defconfig
configs/netspace_max_v2_defconfig
configs/netspace_mini_v2_defconfig
configs/netspace_v2_defconfig
configs/peach-pi_defconfig
configs/peach-pit_defconfig
configs/smdk5250_defconfig
configs/smdk5420_defconfig
configs/snow_defconfig
configs/spring_defconfig
configs/stmark2_defconfig
configs/theadorable_debug_defconfig
configs/trimslice_defconfig
configs/turris_omnia_defconfig
configs/usb_a9263_dataflash_defconfig
env/Kconfig
env/sf.c
include/configs/B4860QDS.h
include/configs/BSC9131RDB.h
include/configs/BSC9132QDS.h
include/configs/C29XPCIE.h
include/configs/M52277EVB.h
include/configs/M54418TWR.h
include/configs/M54451EVB.h
include/configs/M54455EVB.h
include/configs/MPC8536DS.h
include/configs/P1010RDB.h
include/configs/P1022DS.h
include/configs/P2041RDB.h
include/configs/SBx81LIFKW.h
include/configs/SBx81LIFXCAT.h
include/configs/T102xQDS.h
include/configs/T102xRDB.h
include/configs/T1040QDS.h
include/configs/T104xRDB.h
include/configs/T208xQDS.h
include/configs/T208xRDB.h
include/configs/T4240QDS.h
include/configs/T4240RDB.h
include/configs/UCP1020.h
include/configs/adp-ae3xx.h
include/configs/advantech_dms-ba16.h
include/configs/am335x_evm.h
include/configs/am43xx_evm.h
include/configs/ap121.h
include/configs/ap143.h
include/configs/aristainetos-common.h
include/configs/at91sam9260ek.h
include/configs/at91sam9261ek.h
include/configs/at91sam9263ek.h
include/configs/at91sam9rlek.h
include/configs/at91sam9x5ek.h
include/configs/ax25-ae350.h
include/configs/bav335x.h
include/configs/bg0900.h
include/configs/brppt1.h
include/configs/cgtqmx6eval.h
include/configs/cl-som-am57x.h
include/configs/cl-som-imx7.h
include/configs/cm_fx6.h
include/configs/cm_t43.h
include/configs/controlcenterd.h
include/configs/controlcenterdc.h
include/configs/corenet_ds.h
include/configs/da850evm.h
include/configs/db-88f6820-amc.h
include/configs/db-88f6820-gp.h
include/configs/dh_imx6.h
include/configs/display5.h
include/configs/dra7xx_evm.h
include/configs/dreamplug.h
include/configs/ds109.h
include/configs/ea20.h
include/configs/embestmx6boards.h
include/configs/ethernut5.h
include/configs/exynos5-common.h
include/configs/ge_bx50v3.h
include/configs/gw_ventana.h
include/configs/helios4.h
include/configs/km/km_arm.h
include/configs/km/kmp204x-common.h
include/configs/lacie_kw.h
include/configs/legoev3.h
include/configs/ls1012a_common.h
include/configs/ls1043a_common.h
include/configs/ls1046a_common.h
include/configs/lsxl.h
include/configs/meesc.h
include/configs/microblaze-generic.h
include/configs/mvebu_armada-37xx.h
include/configs/mvebu_armada-8k.h
include/configs/mx28evk.h
include/configs/mx6slevk.h
include/configs/nitrogen6x.h
include/configs/omapl138_lcdk.h
include/configs/ot1200.h
include/configs/p1_p2_rdb_pc.h
include/configs/pcm058.h
include/configs/pfla02.h
include/configs/pm9261.h
include/configs/pm9263.h
include/configs/puma_rk3399.h
include/configs/siemens-am33x-common.h
include/configs/socfpga_sr1500.h
include/configs/stmark2.h
include/configs/ti_armv7_keystone2.h
include/configs/topic_miami.h
include/configs/tqma6.h
include/configs/trimslice.h
include/configs/turris_mox.h
include/configs/usb_a9263.h
include/configs/vcoreiii.h
include/configs/vinco.h
include/configs/x530.h
include/spi_flash.h

index aea6068..893bd3f 100644 (file)
 #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
  */
 #ifdef CONFIG_CMD_NET
index e3235fc..71c4f70 100644 (file)
 
 #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
 
index 3628729..cafc861 100644 (file)
@@ -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
index f69f405..a239f4a 100644 (file)
@@ -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
index b2266a0..8b72bd3 100644 (file)
@@ -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
index f69f405..a239f4a 100644 (file)
@@ -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
index ce5f656..b614ca7 100644 (file)
@@ -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
index fc19de5..467bfae 100644 (file)
@@ -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
index e0ce159..afda7ed 100644 (file)
@@ -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
index 4a6e058..4cb4797 100644 (file)
@@ -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
index c9dbe4d..eca24e9 100644 (file)
@@ -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
index 7c1a296..9a5a9f8 100644 (file)
@@ -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
index 7fd844c..9b0aa07 100644 (file)
@@ -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
index c2fc77d..1e5d540 100644 (file)
@@ -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
index 431cf28..e036ebc 100644 (file)
@@ -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
index e5efad8..b67aa90 100644 (file)
@@ -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
index a19f309..4f8694f 100644 (file)
@@ -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
index a19f309..4f8694f 100644 (file)
@@ -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
index 7bf0b79..6f71d34 100644 (file)
@@ -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
index b4e8892..644d59d 100644 (file)
@@ -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
index 688c182..c064d01 100644 (file)
@@ -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
index 1eb4379..1e409ea 100644 (file)
@@ -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
index 800a92c..88c0a43 100644 (file)
@@ -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
index ac6d9de..b125182 100644 (file)
@@ -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
index 56c6f12..c07008a 100644 (file)
@@ -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
index b2b61b2..08fdc55 100644 (file)
@@ -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
index 0b27bd7..28c5c83 100644 (file)
@@ -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
index 4192241..b8c16ba 100644 (file)
@@ -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
index 41dae05..3ee7943 100644 (file)
@@ -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
index 2c9254b..3de9766 100644 (file)
@@ -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
index 422e853..dcf2a25 100644 (file)
@@ -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
index b36b7c3..a4c00e9 100644 (file)
@@ -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
index b6c61c3..98e47ee 100644 (file)
@@ -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
index d3263cf..8202848 100644 (file)
@@ -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
index 3e4e71b..29d5f98 100644 (file)
@@ -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
index ce42f23..62cad53 100644 (file)
@@ -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
index b14cf6c..2ec3aae 100644 (file)
@@ -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
index cebe4a5..ca85973 100644 (file)
@@ -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
index d2c3eea..3212f37 100644 (file)
@@ -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
index d18d40a..99188d3 100644 (file)
@@ -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
index 712e167..e615f75 100644 (file)
@@ -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
index 352da8a..ede5df6 100644 (file)
@@ -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
index 5c716cd..1521392 100644 (file)
@@ -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
index 54adab9..476700c 100644 (file)
@@ -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
index 9276df2..95562b7 100644 (file)
@@ -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
index 0fdd9b8..162a514 100644 (file)
@@ -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
index edc476d..b0dcfaf 100644 (file)
@@ -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
index 146188b..f2c9563 100644 (file)
@@ -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
index a450f48..027aaa4 100644 (file)
@@ -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
index 8996d52..44c8d5b 100644 (file)
@@ -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
index e6d7724..ac103c3 100644 (file)
@@ -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
index 89df1f3..9eded36 100644 (file)
@@ -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
index 9a5cf19..4b0fff4 100644 (file)
@@ -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
index bd879ab..24749f8 100644 (file)
@@ -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
index cb818c5..6fc89cd 100644 (file)
@@ -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
index bb1558b..f091d24 100644 (file)
@@ -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
index d24e9e2..6741387 100644 (file)
@@ -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
index 704786a..6a91962 100644 (file)
@@ -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
index 6179a64..54bf740 100644 (file)
@@ -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
index 2bbfa6d..c24aa2e 100644 (file)
@@ -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
index d74ba67..630b01c 100644 (file)
@@ -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
index cd52220..fb9307a 100644 (file)
@@ -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
index 23034e8..bd08adb 100644 (file)
@@ -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
index 7e5943b..c406b25 100644 (file)
@@ -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
index 9f7506f..3b9e4a5 100644 (file)
@@ -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
index c22cbbd..7830066 100644 (file)
@@ -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"
index 23cbad5..4f92ae0 100644 (file)
--- a/env/sf.c
+++ b/env/sf.c
 #include <errno.h>
 #include <dm/device-internal.h>
 
-#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
index 25705cc..e8c9cdd 100644 (file)
 #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
index 49bea98..c01071e 100644 (file)
@@ -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
index 73cc353..68100f1 100644 (file)
@@ -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
index a18d041..9b83a50 100644 (file)
  */
 #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
index 83d7745..514733e 100644 (file)
  * 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
 
 /*-----------------------------------------------------------------------
index 4b8ef38..f7b0669 100644 (file)
 #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
index 87cdbae..57c8572 100644 (file)
  * 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
index d41b7c4..448dfc9 100644 (file)
  * 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
 
 /*-----------------------------------------------------------------------
index 11dcf23..8191290 100644 (file)
 
 #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
index cefa598..4be40d0 100644 (file)
@@ -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
index 8bdbabe..bdbf119 100644 (file)
  * 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
index da43320..b433308 100644 (file)
 #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
index d62fd35..1539e8f 100644 (file)
 /*
  *  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 */
index 3c8c216..af19193 100644 (file)
 /*
  *  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 */
index 73b70fa..ef94097 100644 (file)
 #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
index 2ba3a9f..551ba6d 100644 (file)
 #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)
index 89ace7c..417383c 100644 (file)
 
 #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
index 0d92f27..a7e0f8f 100644 (file)
@@ -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
index 8db3894..0d53ad5 100644 (file)
 #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
index 40a0316..a78dd81 100644 (file)
 #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
index 80a4b13..9e70412 100644 (file)
 #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
index f007b62..71258c8 100644 (file)
        "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
index 0a996e0..b518c22 100644 (file)
 
 #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
 
index f2268dc..1fe3391 100644 (file)
 #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
index a08f62b..e2c7060 100644 (file)
 #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
 
index d8f0583..0834ff5 100644 (file)
 #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 */
index 55faa7b..5a60806 100644 (file)
 
 #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
index 96850b5..0e8c3f7 100644 (file)
@@ -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
index 4dbca91..fa69210 100644 (file)
@@ -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
index eecc021..4f28f52 100644 (file)
 /* 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)
index 2177512..95710fb 100644 (file)
 #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"
 #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"
index 1c7fbe1..599e262 100644 (file)
 #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"
 #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"
index 856e032..6b1db9f 100644 (file)
 #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"
index b052071..3e18716 100644 (file)
@@ -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"
index d43d408..1abca55 100644 (file)
@@ -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"
index cd07212..395f3a4 100644 (file)
 #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
 
index 8936222..fb9c2a6 100644 (file)
@@ -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 */
index 0c3d54a..832dbba 100644 (file)
 
 /* 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 */
index 2219663..ae9b75b 100644 (file)
@@ -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 + \
index ab8d1c6..ad0a64a 100644 (file)
 #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 */
index 687a9e7..bf2bb44 100644 (file)
@@ -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
index d895f89..26d1a97 100644 (file)
 #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
index 2ac888f..dfd96ff 100644 (file)
 #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)
index 6df8b8b..ffe4a44 100644 (file)
@@ -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" \
index 69c65f1..f1c3522 100644 (file)
 #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
index edd8749..9130837 100644 (file)
@@ -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 */
index a3963db..f974291 100644 (file)
 #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
index 7b1e53f..583f994 100644 (file)
 #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
index 222bdf8..f1bdc2d 100644 (file)
@@ -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 */
index 967b133..d378052 100644 (file)
@@ -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 */
 
index 1c1178c..48514ff 100644 (file)
 #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 */
index d729054..8ab47ab 100644 (file)
 #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)
index 36e1582..10eac20 100644 (file)
@@ -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
index f4d7172..28bda14 100644 (file)
@@ -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
 
 /*
index 2c7928e..07367cf 100644 (file)
@@ -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
 
 /*
index 800ce03..88f2e17 100644 (file)
@@ -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
index f984540..5142680 100644 (file)
 #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 */
index 0d84c97..b86b542 100644 (file)
@@ -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
index 5641f09..db1fc93 100644 (file)
 /* 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 */
index 9ca3ee3..3336578 100644 (file)
 #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
 
index a4215c8..84ee44e 100644 (file)
   #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 */
index 5a11641..df4d8bc 100644 (file)
                                        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
index f93629e..a2e9cf1 100644 (file)
 /* 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 */
index 37b9abc..a52d1df 100644 (file)
 #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
index 1f619a0..1ba28b5 100644 (file)
 #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
index ce806d1..1e239ec 100644 (file)
@@ -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
index 04639c1..3a42210 100644 (file)
 #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
index bc804c5..2e9d476 100644 (file)
 #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
 #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 */
index d9fcd3a..24ff2d1 100644 (file)
 
 #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
 /*
 #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)
index bcad8a0..72e6265 100644 (file)
 
 /* loading initramfs images without uimage header */
 
-/* ST M25P40 */
-#undef CONFIG_ENV_SPI_MAX_HZ
-#define CONFIG_ENV_SPI_MAX_HZ          25000000
-
 /*
  *  Environment variables configurations
  */
index 0a03a2f..a1fd5f6 100644 (file)
@@ -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
 
index d81194b..d1ab40e 100644 (file)
@@ -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)
index e898133..10b94f4 100644 (file)
 /*
  * 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 */
 
index 51f484d..f4972b6 100644 (file)
 /*
  * 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 */
index a078e3a..dd04580 100644 (file)
 #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 */
index 2cce3d5..5d649f6 100644 (file)
 #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
index c37a766..d941caa 100644 (file)
 #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
 
 /*
index 5f5aa57..1786e09 100644 (file)
 
 #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
index 6754181..925e7ae 100644 (file)
 #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
index 24003c2..8fa91fb 100644 (file)
  * 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
index 15dc1b2..b0415b2 100644 (file)
 #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)
index fe54e54..3a9b85a 100644 (file)
 #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)
index e88948c..c1ce122 100644 (file)
 #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"
index f11879b..b09d851 100644 (file)
 #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"
index 45a4ccc..4d6085d 100644 (file)
 #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)
index 8f2dd5f..f44a428 100644 (file)
  * 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 */
index d9de075..b6a9861 100644 (file)
 #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:
index fa3d6b8..17f92d8 100644 (file)
@@ -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
 
 
 #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
index 767615a..fb8c082 100644 (file)
@@ -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
index c4f01aa..69aa79b 100644 (file)
@@ -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 */
index 6c0d4f2..13e3d60 100644 (file)
 #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)
index 417c562..93db175 100644 (file)
@@ -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)
index 648c87d..5d5394e 100644 (file)
 /*
  * 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 */
index aa8738f..fa38274 100644 (file)
@@ -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" \
index 8c30c6f..2840c7b 100644 (file)
@@ -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
index 715ef2a..ec22a30 100644 (file)
@@ -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
index d9c1eff..80c898e 100644 (file)
@@ -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 */
index 97ec2b3..55b4721 100644 (file)
 #include <linux/types.h>
 #include <linux/mtd/spi-nor.h>
 
+/* 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 {