[PATCH] lib/acpi: Enable QEMU special cases for ARM
Alexander Graf
agraf at csgraf.de
Sun Feb 27 15:10:35 CET 2022
With QEMU, we receive ACPI tables from the hypervisor rather than build
them ourselves in U-Boot. That logic however hard codes the target to the
x86 QEMU target, leaving ARM out on the fun.
Let's add the ARM QEMU config as well to the ifdefs so that we can consume
QEMU provided firmware tables there as well.
Signed-off-by: Alexander Graf <agraf at csgraf.de>
---
lib/acpi/Makefile | 2 ++
lib/acpi/acpi_writer.c | 2 +-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/lib/acpi/Makefile b/lib/acpi/Makefile
index 956b5a0d72..66ba0e94ac 100644
--- a/lib/acpi/Makefile
+++ b/lib/acpi/Makefile
@@ -9,6 +9,7 @@ obj-y += acpi_writer.o
# With QEMU the ACPI tables come from there, not from U-Boot
ifndef CONFIG_QEMU
+ifndef CONFIG_ARCH_QEMU
obj-y += base.o
obj-y += csrt.o
obj-y += mcfg.o
@@ -21,3 +22,4 @@ endif
obj-y += facs.o
obj-y += ssdt.o
endif
+endif
diff --git a/lib/acpi/acpi_writer.c b/lib/acpi/acpi_writer.c
index 946f90e8e7..9c252aa58d 100644
--- a/lib/acpi/acpi_writer.c
+++ b/lib/acpi/acpi_writer.c
@@ -48,7 +48,7 @@ int acpi_write_one(struct acpi_ctx *ctx, const struct acpi_writer *entry)
return 0;
}
-#ifndef CONFIG_QEMU
+#if !defined(CONFIG_QEMU) && !defined(CONFIG_ARCH_QEMU)
static int acpi_write_all(struct acpi_ctx *ctx)
{
const struct acpi_writer *writer =
--
2.32.0
More information about the U-Boot
mailing list