On Mon, Feb 03, 2025 at 05:38:44PM -0700, Simon Glass wrote: > Hi Tom, > > On Mon, 3 Feb 2025 at 13:09, Tom Rini <tr...@konsulko.com> wrote: > > > > On Mon, Feb 03, 2025 at 10:42:08AM -0700, Simon Glass wrote: > > > > > The app does not have this symbol. Also the memory where the app is > > > loaded is not under U-Boot's control. Disable this reservation for > > > the EFI app. > > > > > > Signed-off-by: Simon Glass <s...@chromium.org> > > > --- > > > > > > lib/lmb.c | 3 ++- > > > 1 file changed, 2 insertions(+), 1 deletion(-) > > > > > > diff --git a/lib/lmb.c b/lib/lmb.c > > > index 588787d2a90..420eae4d0b8 100644 > > > --- a/lib/lmb.c > > > +++ b/lib/lmb.c > > > @@ -560,7 +560,8 @@ static void lmb_reserve_uboot_region(void) > > > lmb_reserve_flags(rsv_start, bank_end - rsv_start + 1, > > > LMB_NOOVERWRITE); > > > > > > - if (gd->flags & GD_FLG_SKIP_RELOC) > > > + if (!IS_ENABLED(CONFIG_EFI_APP) && > > > + (gd->flags & GD_FLG_SKIP_RELOC)) > > > lmb_reserve_flags((phys_addr_t)(uintptr_t)_start, > > > gd->mon_len, LMB_NOOVERWRITE); > > > > What prevents U-Boot from overwriting itself, with U-Boot commands? Also > > how is this linking today? I see lmb_reserve_uboot_region in > > efi-x86_app64 for example. > > The only memory U-Boot can use when running as an EFI app is that > which it has allocated using EFI calls. The actual U-Boot code is > certainly in memory somewhere, but does not lie between gd->ram_start > and (gd->ram_start + gd->ram_size)
That's not what the commit message means to me. But the next question is, is EFI_APP setting SKIP_RELOC? -- Tom
signature.asc
Description: PGP signature