[PATCH v1 13/24] puma-rk3399: remove check for ENV_IS_NOWHERE, it is an SPL config

Simon Glass sjg at chromium.org
Wed Feb 22 22:19:59 CET 2023


Hi Troy,

On Tue, 21 Feb 2023 at 18:39, Troy Kisky <troykiskyboundary at gmail.com> wrote:
>
> When IS_ENABLED(CONFIG_ENV_IS_NOWHERE) is converted to
> CONFIG_IS_ENABLED(ENV_IS_NOWHERE) this will give unwanted errors
> on spl builds.
>
> Signed-off-by: Troy Kisky <troykiskyboundary at gmail.com>
> ---
>
>  board/theobroma-systems/puma_rk3399/puma-rk3399.c | 4 ----
>  1 file changed, 4 deletions(-)
>
> diff --git a/board/theobroma-systems/puma_rk3399/puma-rk3399.c b/board/theobroma-systems/puma_rk3399/puma-rk3399.c
> index 97f398bd754..614a60ee8f9 100644
> --- a/board/theobroma-systems/puma_rk3399/puma-rk3399.c
> +++ b/board/theobroma-systems/puma_rk3399/puma-rk3399.c
> @@ -136,10 +136,6 @@ int mmc_get_env_dev(void)
>         return CONFIG_SYS_MMC_ENV_DEV;
>  }
>
> -#if !IS_ENABLED(CONFIG_ENV_IS_NOWHERE)
> -#error Please enable CONFIG_ENV_IS_NOWHERE
> -#endif
> -
>  enum env_location arch_env_get_location(enum env_operation op, int prio)
>  {
>         const char *boot_device =
> --
> 2.34.1
>

For this and the previous patch, I wonder whether something like this
might be safer:

#if CONFIG_IS_ENABLED(ENV_SUPPORT)
#if !IS_ENABLED(CONFIG_ENV_IS_NOWHERE)
#error Please enable CONFIG_ENV_IS_NOWHERE
#endif
#endif


More information about the U-Boot mailing list