From d484e85bb9a01cc6e1786dff9513b001edd3c64e Mon Sep 17 00:00:00 2001 From: p-szafonimateusz Date: Tue, 23 Apr 2024 07:49:37 +0200 Subject: [PATCH] x86_64_acpi.c: make sure that RSDP is mapped rsdp memory may be not mapped when provided from multiboot2 header. For some reason the previous code worked on some machines. Signed-off-by: p-szafonimateusz --- arch/x86_64/src/common/x86_64_acpi.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/x86_64/src/common/x86_64_acpi.c b/arch/x86_64/src/common/x86_64_acpi.c index 2615fb439c..f261627711 100644 --- a/arch/x86_64/src/common/x86_64_acpi.c +++ b/arch/x86_64/src/common/x86_64_acpi.c @@ -454,6 +454,10 @@ int acpi_init(uintptr_t rsdp) acpi->rsdp = (struct acpi_rsdp_s *)rsdp; } + /* Make sure that RSDP is mapped */ + + acpi_map_region((uintptr_t)acpi->rsdp, sizeof(struct acpi_rsdp_s)); + /* Parse RSDP */ ret = acpi_rsdp_parse(acpi->rsdp);