[U-Boot] 2018.09-rc1 breakage on orangepi pc2
Mark Kettenis
mark.kettenis at xs4all.nl
Sat Aug 4 18:42:20 UTC 2018
> From: Heinrich Schuchardt <xypron.glpk at gmx.de>
> Date: Sat, 4 Aug 2018 14:21:17 +0200
>
> On 08/03/2018 12:07 AM, Mark Kettenis wrote:
> >> Date: Thu, 2 Aug 2018 22:55:23 +0200 (CEST)
> >> From: Mark Kettenis <mark.kettenis at xs4all.nl>
> >>
> >> I can no longer boot OpenBSD on the orangepi pc2. The kernel faults
> >> somewhere in the EFI detection code, almost certainly where it looks
> >> through the configuration table entries looking for the ACPI table.
> >> I've bisected this resulting in:
> >>
> >>
> >> 4182a129ef735bfd6c54788affe1b649ab85b851 is the first bad commit
> >> commit 4182a129ef735bfd6c54788affe1b649ab85b851
> >> Author: Heinrich Schuchardt <xypron.glpk at gmx.de>
> >> Date: Thu Jun 28 12:45:32 2018 +0200
> >>
> >> efi_loader: allocate configuration table array
> >>
> >> The system table contains a link to the list of configurations tables.
> >> These include the device tree, SMBIOS table, and the ACPI table.
> >>
> >> This array is currently statically linked. With the patch it is allocated
> >> as EFI_RUNTIME_SERVICES_DATA. Due to the structure of the system table we
> >> cannot work with a linked list here.
> >>
> >> Signed-off-by: Heinrich Schuchardt <xypron.glpk at gmx.de>
> >> Reviewed-by: Bin Meng <bmeng.cn at gmail.com>
> >> Signed-off-by: Alexander Graf <agraf at suse.de>
> >
> > So after this commit, the ConfigurationTable field of the system table
> > is no longer translated from a physical address into a virtual address
> > when the SerVirtualAddressMap() runtime service gets called.
> >
> > The way SetVirtualAddressMap() is implemented is actually quite nify.
> > It "relocates" the relevant bits by processing the ELF relocations for
> > everything that is marked as __efi_runtime_data. This magically
> > modifies all the pointers in the system table that reference other
> > symbols, such as firmware_vendor, efi_runtime_services and
> > efi_conf_table. But since the diff replaces the reference to
> > efi_conf_table with a dynamically updated pointer, there no longer is
> > a relocation for the tables member.
> >
> >>From the commit message it isn't abvious what is being fixed. I think
> > the commit should be reverted.
> >
> Hello Mark,
>
> thanks for pointing out the following requirement from the UEFI spec
> that is not correctly implemented:
>
> "Several fields of the EFI System Table must be converted from physical
> pointers to virtual pointers using the ConvertPointer() service. These
> fields include FirmwareVendor, RuntimeServices, and ConfigurationTable."
Sorry, but that functionality was implemented and it still works for
the FirmwareVendor and RuntimeServices fields. Your commit introduced
a regression by breaking this functionality for the ConfigurationTable
field.
This regression should really be fixed before 2018.09 gets released.
> I am currently testing a patch for this.
Great. Although I still don't understand what your commit is trying
to fix.
More information about the U-Boot
mailing list