[PATCH v2 3/3] kbuild: SPL/TPL: generate separate asm-offsets.h for SPL and TPL

Tom Rini trini at konsulko.com
Wed Apr 29 14:48:42 CEST 2020


On Fri, Apr 17, 2020 at 04:21:37PM +0900, Masahiro Yamada wrote:

> Currently generic-asm-offsets.h and asm-offsets.h are generated based
> on U-Boot proper config options. The same asm-offsets headers are used
> for building U-Boot SPL/TPL, which causes potential offset mismatch if
> U-Boot proper has different config options from U-Boot SPL/TPL.
> 
> This commit adds:
>   spl/include/generated/(generic-)asm-offsets.h
>   tpl/include/generated/(generic-)asm-offsets.h
> 
> spl/include/generated/(generic-)asm-offsets.h is generated if
> CONFIG_SPL=y, and included when building SPL.
> 
> tpl/include/generated/(generic-)asm-offsets.h is generated if
> CONFIG_TPL=y, and included when building TPL.
> 
> They are created before Kbuild descends into SPL/TPL object directories
> and builds $(obj)/dts/dt-platdata.o because $(obj)/dts/dt-platdata.c
> includes a bunch of headers.
> 
> Prepend -I$(obj)/include to $(UBOOTINCLUDE) so (generic-)asm-offsets.h
> is searched in {spl,tpl}/include/generated/.
> 
> Requested-by: Bin Meng <bmeng.cn at gmail.com>
> Signed-off-by: Masahiro Yamada <masahiroy at kernel.org>
> Tested-by: Bin Meng <bmeng.cn at gmail.com>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20200429/ff2dc3fa/attachment.sig>


More information about the U-Boot mailing list