[U-Boot] [PATCH][v2] armv8:ls2080a: Reorganise NAND_BOOT code in config flag

Tom Rini trini at konsulko.com
Thu Mar 2 13:45:16 UTC 2017


On Thu, Mar 02, 2017 at 04:05:48PM +0530, Santan Kumar wrote:

> Add CONFIG_NAND_BOOT config flag to organise
> NAND_BOOT specific code in config flag like
> -nand-boot specfic errata errata_rcw_src()
> -CONFIG_SYS_NAND_U_BOOT_DST,etc
> 
> Signed-off-by: Santan Kumar <santan.kumar at nxp.com>
> Signed-off-by: Priyanka Jain <priyanka.jain at nxp.com>
> Signed-off-by: Abhimanyu Saini <abhimanyu.saini at nxp.com>
> ---
> Changes for v2:
>  Rebased to latest codebase
>  Incorporated York's comments to defined CONFIG_NAND_BOOT
>  in new line
> 
>  arch/arm/cpu/armv8/fsl-layerscape/soc.c | 2 +-
>  configs/ls2080aqds_nand_defconfig       | 1 +
>  configs/ls2080ardb_nand_defconfig       | 1 +
>  include/configs/ls2080a_common.h        | 5 +++++
>  include/configs/ls2080aqds.h            | 4 +++-
>  5 files changed, 11 insertions(+), 2 deletions(-)
[snip]
> --- a/include/configs/ls2080a_common.h
> +++ b/include/configs/ls2080a_common.h
> @@ -216,6 +216,7 @@ unsigned long long get_qixis_addr(void);
>  
>  #define CONFIG_PANIC_HANG	/* do not reset board on panic */
>  
> +#ifdef CONFIG_SPL
>  #define CONFIG_SPL_BSS_START_ADDR	0x80100000
>  #define CONFIG_SPL_BSS_MAX_SIZE		0x00100000
>  #define CONFIG_SPL_FRAMEWORK
> @@ -225,11 +226,15 @@ unsigned long long get_qixis_addr(void);
>  #define CONFIG_SPL_TARGET		"u-boot-with-spl.bin"
>  #define CONFIG_SPL_TEXT_BASE		0x1800a000
>  
> +#ifdef CONFIG_NAND_BOOT
> +#define CONFIG_SPL_NAND_SUPPORT
>  #define CONFIG_SYS_NAND_U_BOOT_DST	0x80400000
>  #define CONFIG_SYS_NAND_U_BOOT_START	CONFIG_SYS_NAND_U_BOOT_DST
> +#endif
>  #define CONFIG_SYS_SPL_MALLOC_SIZE	0x00100000
>  #define CONFIG_SYS_SPL_MALLOC_START	0x80200000
>  #define CONFIG_SYS_MONITOR_LEN		(640 * 1024)
> +#endif
>  
>  #define CONFIG_SYS_BOOTM_LEN   (64 << 20)      /* Increase max gunzip size */

This applies to the other config file as well.  But, why do you need to
hide CONFIG_SPL_xxx behind a check for CONFIG_SPL?  That seems wrong.
Also, CONFIG_SPL_NAND_SUPPORT is in Kconfig so we should be select'ing
that under NAND_BOOT (which is also in Kconfig).  We should not have to
hide those used values as well, either.

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20170302/a513dc1d/attachment.sig>


More information about the U-Boot mailing list