[U-Boot] [PATCH v3] common/Makefile: Add new symbol CONFIG_SPL_ENV_SUPPORT for environment in SPL
Zhang Ying-B40530
B40530 at freescale.com
Thu May 16 09:17:50 CEST 2013
-----Original Message-----
From: Tom Rini [mailto:tom.rini at gmail.com] On Behalf Of Tom Rini
Sent: Wednesday, May 15, 2013 10:07 PM
To: Zhang Ying-B40530
Cc: u-boot at lists.denx.de; Wood Scott-B07421; afleming at gmail.com; Xie Xiaobo-R63061; Zhang Ying-B40530
Subject: Re: [U-Boot] [PATCH v3] common/Makefile: Add new symbol CONFIG_SPL_ENV_SUPPORT for environment in SPL
On Wed, May 15, 2013 at 10:15:28AM +0800, ying.zhang at freescale.com wrote:
> From: Ying Zhang <b40530 at freescale.com>
>
> There will need the environment in SPL for reasons other than network
> support (in particular, hwconfig contains info for how to set up DDR).
>
> Add a new symbol CONFIG_SPL_ENV_SUPPORT to replace CONFIG_SPL_NET_SUPPORT
> for environment in common/Makefile.
>
> Signed-off-by: Ying Zhang <b40530 at freescale.com>
[snip]
> # environment
> @@ -67,7 +66,6 @@ COBJS-$(CONFIG_ENV_IS_IN_ONENAND) += env_onenand.o
> COBJS-$(CONFIG_ENV_IS_IN_SPI_FLASH) += env_sf.o
> COBJS-$(CONFIG_ENV_IS_IN_REMOTE) += env_remote.o
> COBJS-$(CONFIG_ENV_IS_IN_UBI) += env_ubi.o
> -COBJS-$(CONFIG_ENV_IS_NOWHERE) += env_nowhere.o
You need to move all of these options down so that adding them to SPL
later, as needed, doesn't have further deltas, and to keep things
organized still.
> # command
> COBJS-$(CONFIG_CMD_AMBAPP) += cmd_ambapp.o
> @@ -215,18 +213,16 @@ COBJS-$(CONFIG_CMD_GPT) += cmd_gpt.o
> endif
>
> ifdef CONFIG_SPL_BUILD
> -COBJS-y += cmd_nvedit.o
> -COBJS-y += env_common.o
> COBJS-$(CONFIG_ENV_IS_IN_FLASH) += env_flash.o
This CONFIG_ENV_IS_IN_FLASH is now duplicated and needs to be removed,
when you move all of the other CONFIG_ENV_IS_... down to the always part
of the Makefile.
[snip]
> diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h
> index ef00306..f47d3d1 100644
> --- a/include/configs/am335x_evm.h
> +++ b/include/configs/am335x_evm.h
> @@ -325,6 +325,7 @@
> #define CONFIG_SPL_GPIO_SUPPORT
> #define CONFIG_SPL_YMODEM_SUPPORT
> #define CONFIG_SPL_NET_SUPPORT
> +#define CONFIG_SPL_ENV_SUPPORT
> #define CONFIG_SPL_NET_VCI_STRING "AM335x U-Boot SPL"
> #define CONFIG_SPL_ETH_SUPPORT
> #define CONFIG_SPL_SPI_SUPPORT
> diff --git a/include/configs/pcm051.h b/include/configs/pcm051.h
> index d0ea74e..926842f 100644
> --- a/include/configs/pcm051.h
> +++ b/include/configs/pcm051.h
> @@ -224,6 +224,7 @@
> #define CONFIG_SPL_GPIO_SUPPORT
> #define CONFIG_SPL_YMODEM_SUPPORT
> #define CONFIG_SPL_NET_SUPPORT
> +#define CONFIG_SPL_ENV_SUPPORT
> #define CONFIG_SPL_NET_VCI_STRING "pcm051 U-Boot SPL"
> #define CONFIG_SPL_ETH_SUPPORT
> #define CONFIG_SPL_SPI_SUPPORT
Have you made sure these two boards still compile? I bet they don't as
they aren't setting CONFIG_ENV_IS_NOWHERE for SPL and
CONFIG_ENV_IS_...somewhere-else for non-SPL.
[Zhang Ying]
Oh, there are some confusion. I thought CONFIG_ENV_IS_xxx defined is
consistent for both SPL and non-SPL.
If you want to set CONFIG_ENV_IS_NOWHERE for SPL and CONFIG_ENV_IS_xxx
somewhere-else for non-SPL, so all of lines CONFIG_ENV_IS_... cann't
be moved to the public area, because CONFIG_ENV_IS_NOWHERE has always
been not effective and CONFIG_ENV_IS_... has been effective in
common/Makefile.
Unless we define some new symbols that for SPL?
More information about the U-Boot
mailing list