mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2026-06-02 09:46:37 +03:00
env: Make use of IF_ENABLED_INT in spi flash support
In order to build the spi flash environment driver, but with CONFIG_ENV_REDUNDANT disabled we must make use of IF_ENABLED_INT to check for a value in CONFIG_ENV_OFFSET_REDUND otherwise we will fail to build. Signed-off-by: Tom Rini <trini@konsulko.com>
This commit is contained in:
3
env/sf.c
vendored
3
env/sf.c
vendored
@@ -396,7 +396,8 @@ static int env_sf_init_early(void)
|
||||
|
||||
if (IS_ENABLED(CONFIG_ENV_REDUNDANT)) {
|
||||
read2_fail = spi_flash_read(env_flash,
|
||||
CONFIG_ENV_OFFSET_REDUND,
|
||||
IF_ENABLED_INT(CONFIG_ENV_REDUNDANT,
|
||||
CONFIG_ENV_OFFSET_REDUND),
|
||||
CONFIG_ENV_SIZE, tmp_env2);
|
||||
ret = env_check_redund((char *)tmp_env1, read1_fail,
|
||||
(char *)tmp_env2, read2_fail);
|
||||
|
||||
Reference in New Issue
Block a user