Hi Ahmad,

On Mon, 4 May 2026 at 02:32, Ahmad Fatoum <[email protected]> wrote:
>
> Hello,
>
> On 4/29/26 4:23 PM, Simon Glass wrote:
> > On Tue, 28 Apr 2026 at 08:06, Tom Rini <[email protected]> wrote:
> >> On Tue, Apr 28, 2026 at 04:26:31PM +0530, Beleswar Prasad Padhi wrote:
> >>>> I guess the real question here is, does the spec allow this to be
> >>>> omitted like that?
> >>>
> >>>
> >>> Could you please point me to the spec? I could not find it.
> >>
> >> Sure: https://github.com/open-source-firmware/flat-image-tree/
> >
> > It is mandatory for kernel and firmware images. Instead of allowing it
> > to be optional for 'kernel', we created 'kernel_noload' some years
> > back.
> >
> > Which image type are you using in your case?
>
> FWIW, barebox has always interpreted lack of the load property to mean
> that it should just compute a suitable address itself (i.e. free memory
> aligned as Linux expects on that platform - same as kernel_noload).
>
> Writing that into the spec also allows for Beleswar's use case here,
> although it doesn't give the guarantee that the address will always be
> the image address.
>
> I think that giving a guarantee about the image address is wrong:
>
> - If the code is not relocatable, then its load address can equally well
> be written into the FIT image node
>
> - If the code is relocatable, then forcing the load address to be the
> image data addresses will make non-external FIT unfeasible for most
> users, because of code having the wrong alignment and for external FIT,
> it will mean careful placement of the FIT itself is required, so we
> don't end up with misbehavior at runtime.
>
> I thus suggest, the spec leaves it to bootloaders to select appropriate
> load addresses if its missing and if the bootloader can't, it should
> refuse boot (current U-Boot behavior). Future U-Boot behavior will
> likely need to be adapted, so this loading at image data address is only
> done for these specific firmware images and not in general as otherwise
> it would preclude any other use in future.

This seems reasonable to me.

So load becomes optional for all image types, not just kernel_noload/fpga.

I drafted something here:

https://github.com/open-source-firmware/flat-image-tree/pull/50

Regards,
Simon

Reply via email to