From: Udit Agarwal Date: Tue, 5 Mar 2019 09:29:33 +0000 Subject: [U-Boot] [PATCH 1/1] Set environment location to ENVL_NOWHERE with CONFIG_ENV_IS_NOWHERE. Message-ID: <20190305092806.24131-1-udit.agarwal@nxp.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Compiles code to set the environment location to ENVL_NOWHERE and return when CONFIG_ENV_IS_NOWHERE is set. Environment location is dependent on CONFIG_ENV_IS_NOWHERE config and not on CONFIG_CHAIN_OF_TRUST. Signed-off-by: Udit Agarwal --- arch/arm/cpu/armv8/fsl-layerscape/cpu.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/arch/arm/cpu/armv8/fsl-layerscape/cpu.c b/arch/arm/cpu/armv8/fsl-layerscape/cpu.c index 34167cdd50..0f2a42f119 100644 --- a/arch/arm/cpu/armv8/fsl-layerscape/cpu.c +++ b/arch/arm/cpu/armv8/fsl-layerscape/cpu.c @@ -795,11 +795,7 @@ enum env_location env_get_location(enum env_operation op, int prio) if (prio) return ENVL_UNKNOWN; -#ifdef CONFIG_CHAIN_OF_TRUST - /* Check Boot Mode - * If Boot Mode is Secure, return ENVL_NOWHERE - */ - if (fsl_check_boot_mode_secure() == 1) +#ifdef CONFIG_ENV_IS_NOWHERE goto done; #endif @@ -830,7 +826,7 @@ enum env_location env_get_location(enum env_operation op, int prio) break; } -#ifdef CONFIG_CHAIN_OF_TRUST +#ifdef CONFIG_ENV_IS_NOWHERE done: #endif return env_loc; -- 2.17.1