summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHeinrich Schuchardt <xypron.glpk@gmx.de>2021-02-21 10:16:58 +0100
committerHeinrich Schuchardt <xypron.glpk@gmx.de>2021-02-26 16:17:43 +0100
commit992b1731e6afc9ae4507e3ae22b6bcd1f2cb4ffc (patch)
treea6e1ae5e717a295b6f8f88b77d4881955a5cf635
parentc28d5d704d3347fcbe5e49ab561973c00bf9337f (diff)
downloadu-boot-992b1731e6afc9ae4507e3ae22b6bcd1f2cb4ffc.tar.gz
efi_loader: ACPI tables must be in EfiACPIReclaimMemory
The UEFI spec does not allow ACPI tables to be in runtime services memory. It recommends EfiACPIReclaimMemory. Remove a superfluous check that the allocated pages are 16 byte aligned. EFI pages are 4 KiB aligned. Fixes: 86df34d42b05 ("efi_loader: Install ACPI configuration tables") Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
-rw-r--r--lib/efi_loader/efi_acpi.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/efi_loader/efi_acpi.c b/lib/efi_loader/efi_acpi.c
index 585b2d2b63..a62c34009c 100644
--- a/lib/efi_loader/efi_acpi.c
+++ b/lib/efi_loader/efi_acpi.c
@@ -25,7 +25,7 @@ efi_status_t efi_acpi_register(void)
/* Reserve 64kiB page for ACPI */
ret = efi_allocate_pages(EFI_ALLOCATE_MAX_ADDRESS,
- EFI_RUNTIME_SERVICES_DATA, 16, &acpi);
+ EFI_ACPI_RECLAIM_MEMORY, 16, &acpi);
if (ret != EFI_SUCCESS)
return ret;
@@ -34,7 +34,6 @@ efi_status_t efi_acpi_register(void)
* a 4k-aligned address, so it is safe to assume that
* write_acpi_tables() will write the table at that address.
*/
- assert(!(acpi & 0xf));
write_acpi_tables(acpi);
/* And expose them to our EFI payload */