[U-Boot] [PATCH] spl: descend into lib/ for all the SPL boards

York Sun yorksun at freescale.com
Tue Apr 21 18:53:39 CEST 2015



On 04/20/2015 08:37 PM, Masahiro Yamada wrote:
> Currently, CONFIG_SPL_LIBGENERIC_SUPPORT must be defined
> to build under lib/ directory for SPL.
> 
> This directory contains very basic functions such as memcpy, memset
> in lib/string.c, so it should be very useful for all the boards.
> 
> Because SPL always enables compiler's garbage collection, this change
> should not give impact on its memory footprint.
> 
> Let's allow SPL to descend into lib/ all the time.  As a result,
> CONFIG_SPL_LIBGENERIC_SUPPORT is no longer necessary.

If this macro is not needed, do you want to remove it from README?

> 
> Four files must be adjusted to avoid multiple definition error.
> 
>  - arch/powerpc/cpu/mpc85xx/spl_minimal.c
>     udelay() is not a weak function.  __udelay() is overridable.
> 
>  - arch/powerpc/lib/time.c
>     MPC85xx has its own udelay for CONFIG_SPL_INIT_MINIAL.
>     Enclose the definition with ifdefs.
> 
>  - board/armadeus/apf27/apf27.c
>  - board/vpac270/onenand.c
>     Do not duplicate hang()
> 
> Signed-off-by: Masahiro Yamada <yamada.masahiro at socionext.com>
> ---

Tested on multiple mpc85xx boards. Most are OK but I see issues with B4860QDS
and T4240QDS NAND boot. Probably not caused by this patch. I will ask board
maintainers to follow up.

York


More information about the U-Boot mailing list