[U-Boot] [PATCH] dlmalloc: ensure gd is set for early free

Stephen Warren swarren at wwwdotorg.org
Wed May 23 19:32:53 UTC 2018


On 05/23/2018 01:07 PM, Eugeniu Rosca wrote:
> This fix seems to be a twin of v2015.01 commit 854d2b9753e4 ("dlmalloc:
> ensure gd is set for early alloc"). Here is a gdb backtrace to make them
> look even more similar (sandbox build):
...
> Interestingly, this issue appears on a very old v2015.04 U-boot, but
> not on u-boot/master (even if the fix applies cleanly to u-boot/master).
> With the patch applied, my ancient u-boot starts to work properly:

That's probably because of 2f0bcd4de1ab0cb03f01428a334cd91f8870504c 
"malloc: use hidden visibility" which prevents code outside of U-Boot 
from using U-Boot's malloc/free?

(I only remember this because I very recently bisected an issue in an 
old branch that caused sandbox crashes after upgrading the OS on a test 
machine and triggering the bug that commit fixes.)


More information about the U-Boot mailing list