From c99dcc113d2a503164b8d67977d5268c69801e5b Mon Sep 17 00:00:00 2001 From: Alex Date: Fri, 12 May 2023 05:59:35 +0300 Subject: [PATCH] Check for ACPI pointer in x64 too --- Core/Memory/ReserveEssentials.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Core/Memory/ReserveEssentials.cpp b/Core/Memory/ReserveEssentials.cpp index d4d142a..14f7268 100644 --- a/Core/Memory/ReserveEssentials.cpp +++ b/Core/Memory/ReserveEssentials.cpp @@ -101,7 +101,13 @@ namespace Memory debug("Reserving RSDT..."); this->ReservePages((void *)bInfo.RSDP, TO_PAGES(sizeof(BootInfo::RSDPInfo))); -#if defined(a32) +#if defined(a64) + if ((uintptr_t)ACPIPtr > 0x7FE00000) /* FIXME */ + { + error("ACPI table is located above 0x7FE00000, which is not mapped."); + return; + } +#elif defined(a32) if ((uintptr_t)ACPIPtr > 0x2800000) /* FIXME */ { error("ACPI table is located above 0x2800000, which is not mapped.");