diff options
author | Frieder Schrempf <frieder.schrempf@kontron.de> | 2019-10-23 10:41:20 +0300 |
---|---|---|
committer | Jagan Teki <jagan@amarulasolutions.com> | 2019-10-24 22:18:32 +0300 |
commit | 832ce20278db00aeeed5576f1296a6d905d31563 (patch) | |
tree | 52d24fa8f3dc40c446d28cf4babd65bcd231af9a /include/configs/da850evm.h | |
parent | 73d74b58812373b4973d1fd38fc37f4e6083ab91 (diff) | |
download | u-boot-832ce20278db00aeeed5576f1296a6d905d31563.tar.xz |
mtd: spi: Clean up usage of CONFIG_SPI_FLASH_MTD
Most boards currently use SPI_FLASH_MTD only in U-Boot proper, not in
SPL. They often rely on hacks in the board header files to include
this option conditionally. To be able to fix this, we previously
introduced a separate option SPL_SPI_FLASH_MTD.
Therefore we can now adjust the Makefile and change the code in
sf_probe.c and sf_internal.h to use CONFIG_IS_ENABLED(SPI_FLASH_MTD).
We also need to move all occurences of CONFIG_SPI_FLASH_MTD from the
header files to the according defconfigs. The affected boards are
socfpga, aristainetos, cm_fx6, display5, ventana, rcar-gen2, dh_imx6
and da850evm.
We do this all in one patch to guarantee bisectibility.
This change was tested with buildman to make sure it does not
introduce any regressions by comparing the resulting binary sizes.
Signed-off-by: Frieder Schrempf <frieder.schrempf@kontron.de>
Reviewed-by: Stefan Roese <sr@denx.de>
Reviewed-by: Simon Goldschmidt <simon.k.r.goldschmidt@gmail.com>
Acked-by: Lukasz Majewski <lukma@denx.de>
Reviewed-by: Heiko Schocher <hs@denx.de>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
Diffstat (limited to 'include/configs/da850evm.h')
-rw-r--r-- | include/configs/da850evm.h | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/include/configs/da850evm.h b/include/configs/da850evm.h index 41f0813a01..6876134a00 100644 --- a/include/configs/da850evm.h +++ b/include/configs/da850evm.h @@ -190,16 +190,11 @@ #define CONFIG_ENV_SECT_SIZE CONFIG_SYS_FLASH_SECT_SZ #endif -#ifdef CONFIG_USE_SPIFLASH -#ifdef CONFIG_ENV_IS_IN_SPI_FLASH +#if defined(CONFIG_USE_SPIFLASH) && defined(CONFIG_ENV_IS_IN_SPI_FLASH) #define CONFIG_ENV_SIZE (64 << 10) #define CONFIG_ENV_OFFSET (512 << 10) #define CONFIG_ENV_SECT_SIZE (64 << 10) #endif -#ifdef CONFIG_SPL_BUILD -#undef CONFIG_SPI_FLASH_MTD -#endif -#endif /* * U-Boot general configuration |