imx8mp_evk: boot error "alloc space exhausted"

ZHIZHIKIN Andrey andrey.zhizhikin at leica-geosystems.com
Thu Dec 17 13:51:57 CET 2020


Hello Peng,

Just a gentle ping here: can you take a look at the failure reported below?

I've also added Alice Guo since there was some work done om imx8mp_evk board,
and uboot-imx list here.

Thanks a lot!

> -----Original Message-----
> From: ZHIZHIKIN Andrey
> Sent: Tuesday, December 8, 2020 2:40 PM
> To: Peng Fan <peng.fan at nxp.com>
> Cc: U-Boot Mailing List <u-boot at lists.denx.de>; festevam at gmail.com; Stefano
> Babic <sbabic at denx.de>
> Subject: imx8mp_evk: boot error "alloc space exhausted"
> 
> Hello Peng,
> 
> I've tried to boot the i.MX8M Plus EVK with U-Boot 2020.10 and faced the error
> message during the boot process, which indicates that the allocation space in
> early malloc area is exhausted.
> 
> Looking at the log, I was able to bisect it to the commit 28fff3fa1c ("imx:
> imx8mp_evk: fix boot issue"), where the CONFIG_SYS_MALLOC_F_LEN has been
> reduced from 0x10000 to 0x8000 and CONFIG_SPL_SYS_MALLOC_SIMPLE was
> enabled.
> 
> Extract from the patch shows the following diff:
> -CONFIG_SYS_MALLOC_F_LEN=0x10000
> +CONFIG_SYS_MALLOC_F_LEN=0x8000
> +CONFIG_SPL_SYS_MALLOC_SIMPLE=y
> 
> 
> If the CONFIG_SYS_MALLOC_F_LEN is returned to the original value - error
> message disappears, and I can observe that the total occupation of early malloc
> area (reported via bdinfo) contains following count:
> -----------------
> u-boot=> bdinfo
> <snip>
> Early malloc usage: a648 / 10000
> -----------------
> 
> As it can be seen, the value 0xa648 overflows the imposed limit of 0x8000,
> causing 2 allocations after ATF execution to fail.
> 
> According to the Patchwork [1], this has been already reported by Fabio but
> there was no resolution provided to address this further. Neither the commit
> message in 28fff3fa1c provides any additional hint on why those config options
> were setup with those values.
> 
> V1 of this patch series did not have any config options in it, and the changelog of
> v2 is also missing to advise why those options were added to the series.
> 
> Can you please explain why CONFIG_SYS_MALLOC_F_LEN and
> CONFIG_SPL_SYS_MALLOC_SIMPLE config options were added with that patch,
> and if it is safe to have them reverted to the original values?
> 
> Another
> 
> 
> Thanks a lot!
> 
> Regards,
> Andrey
> 
> 
> Link: [1]:
> http://patchwork.ozlabs.org/project/uboot/patch/20200512093901.14831-2-
> peng.fan at nxp.com/

-- Andrey


More information about the U-Boot mailing list