spl: Drop bd_info in the data section
authorSimon Glass <sjg@chromium.org>
Wed, 23 Dec 2020 02:30:21 +0000 (19:30 -0700)
committerSimon Glass <sjg@chromium.org>
Tue, 5 Jan 2021 19:24:40 +0000 (12:24 -0700)
commit38d6b7ebdaee3e0e8426ef1b9df88bdce8ae2e75
tree8270760e4e3f1e29be75d813b921fb65422c98d8
parentacfb5308f5e51fd1f4428618d704ad0de2358871
spl: Drop bd_info in the data section

This uses up space in the SPL binary but it always starts as zero. Also
some boards cannot support data in TPL (e.g. Intel Apollo Lake).

Use malloc() to allocate this structure instead, by moving the init a
little later, after malloc() is inited. Make this function optional since
it pulls in malloc().

This reduces the TPL binary size on coral by about 64 bytes

Signed-off-by: Simon Glass <sjg@chromium.org>
arch/arm/cpu/armv8/fsl-layerscape/spl.c
common/spl/Kconfig
common/spl/spl.c
include/spl.h