[PATCH 1/1] arm: sunxi: increase SYS_MALLOC_F_LEN

Maxime Ripard maxime at cerno.tech
Mon Jun 8 10:02:38 CEST 2020


Hi,

On Sat, Jun 06, 2020 at 09:58:13AM +0000, Heinrich Schuchardt wrote:
> The current default of 0x400 for SYS_MALLOC_F_LEN is too small if any
> additional drivers marked as DM_FLAG_PRE_RELOC are loaded before
> relocation.
> 
> CONFIG_RSA=y which is needed for UEFI secure boot or for FIT image
> verification loads the driver mod_exp_sw which has DM_FLAG_PRE_RELOC.
> 
> CONFIG_LOG=Y is another setting requiring additional early malloc
> area, cf. log_init().
> 
> When running pine64-lts_defconfig with CONFIG_RSA=y and debug UART enabled
> we see as output in main U-Boot
> 
>     alloc_simple() alloc space exhausted
> 
> With this patch the default values of SYS_MALLOC_F_LEN and
> SPL_SYS_MALLOC_F_LEN on ARCH_SUNXI are raised to 0x2000.
> 
> Signed-off-by: Heinrich Schuchardt <xypron.glpk at gmx.de>

Where is this SYS_MALLOC_F_LEN allocated from (in particular for the
SPL). Is it from the SRAM?

If so, on older SoCs, we probably don't have 8k to spare.

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


More information about the U-Boot mailing list