summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorMarek Vasut <[email protected]>2026-07-21 21:48:02 +0200
committerTom Rini <[email protected]>2026-08-10 14:48:11 -0600
commit8da656ae6a9778ffe111c4a3b6a7795b2e7ee6d1 (patch)
tree1b0c31b5cbd9b0ec846c08db8061902f0bd324c3 /scripts
parent93926f630e486d3cb2f2278c2785b2e2e9a3d705 (diff)
board_f: Call initf_malloc() before fdtdec_setup()
In case MULTI_DTB_FIT_GZIP is enabled, fdtdec_setup() does uncompress the compressed DTs in uncompress_blob() using gunzip(), which invokes malloc() internally. The early simple malloc is initialized in board_f initf_malloc() call, which sets up the early simple malloc limit and offset pointer in global data. Currently, the initf_malloc() is called after fdtdec_setup(), which leads to malloc failure in fdtdec_setup() during the gzip decompression, because the early simple malloc is not initialized yet. Call initf_malloc() before fdtdec_setup() to assure fdtdec_setup() can use malloc() during gzip decompression of the DTs. The impact of this change on boot time is negligible, because the initf_malloc() only assigns two fields in global data. Signed-off-by: Marek Vasut <[email protected]> Fixes: 95f4bbd581cf ("lib: fdt: Allow LZO and GZIP DT compression in U-Boot") Reviewed-by: Simon Glass <[email protected]> [trini: Update test/py/tests/test_trace.py] Signed-off-by: Tom Rini <[email protected]>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions