]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
spl: fit: fix loadables load under sandbox
authorFrancesco Valla <francesco@valla.it>
Thu, 4 Jun 2026 20:41:36 +0000 (22:41 +0200)
committerTom Rini <trini@konsulko.com>
Wed, 17 Jun 2026 20:16:41 +0000 (14:16 -0600)
Align the fit_image_load() call done for the loadables to the ones for
other artifatcs (firmware, kernel, fdt), calling virt_to_phys() on the
pointer that contains the FIT location.

This is needed to support the 'sandbox' environment.

Signed-off-by: Francesco Valla <francesco@valla.it>
common/spl/spl_fit.c

index 46ebcabe56a15585c6a23132fc7b025e0614537b..229eda0582f1551d0a52ed5d927fea24a840f48e 100644 (file)
@@ -1024,7 +1024,7 @@ int spl_load_fit_image(struct spl_image_info *spl_image,
 #ifdef CONFIG_SPL_FIT_SIGNATURE
                images.verify = 1;
 #endif
-               ret = fit_image_load(&images, (ulong)header,
+               ret = fit_image_load(&images, virt_to_phys((void *)header),
                                     &uname, &fit_uname_config,
                                     IH_ARCH_DEFAULT, IH_TYPE_LOADABLE, -1,
                                     FIT_LOAD_OPTIONAL_NON_ZERO,