From aa329f9476a84dc4025010c6cbc8166a30f0350b Mon Sep 17 00:00:00 2001 From: "Liu, Chang" Date: Wed, 22 Oct 2025 17:06:19 +0800 Subject: [PATCH] x86: skip unaddressable memory for multiboot2 On 32-bit x86, when booting under multiboot1 the physical memories above 4GB are skipped and not included as usable memory regions. Make sure we also do this when booting under multiboot2. Signed-off-by: Liu, Chang --- src/arch/x86/kernel/boot_sys.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/arch/x86/kernel/boot_sys.c b/src/arch/x86/kernel/boot_sys.c index 5bb763a13..55b7066fb 100644 --- a/src/arch/x86/kernel/boot_sys.c +++ b/src/arch/x86/kernel/boot_sys.c @@ -671,6 +671,7 @@ static BOOT_CODE bool_t try_boot_sys_mbi2( printf("\tPhysical Memory Region from %llx size %llx type %u\n", m->addr, m->size, m->type); if (m->addr != (uint64_t)(word_t)m->addr) { printf("\t\tPhysical memory region not addressable\n"); + continue; } if (m->type == MULTIBOOT_MMAP_USEABLE_TYPE && m->addr >= HIGHMEM_PADDR) {