From e44584b5ae7aaf43d2241138149b38ff15072e60 Mon Sep 17 00:00:00 2001 From: Ian Moffett Date: Mon, 17 Nov 2025 17:02:00 -0500 Subject: kern/amd64: mp: Ensure core is online capable Section 5.2.12.2, table 5.23 of the ACPI spec states that the flags needs to have the enabled bit [0] or online capable bit [1] set for startup, otherwise it should just be ignored. Signed-off-by: Ian Moffett --- sys/arch/amd64/cpu/mp.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'sys/arch/amd64/cpu') diff --git a/sys/arch/amd64/cpu/mp.c b/sys/arch/amd64/cpu/mp.c index 09c824e..ae40025 100644 --- a/sys/arch/amd64/cpu/mp.c +++ b/sys/arch/amd64/cpu/mp.c @@ -73,6 +73,11 @@ cpu_lapic_cb(struct apic_header *h, size_t arg) return -1; } + /* If not online capable, continue */ + if (!ISSET(lapic->flags, 0x3)) { + return -1; + } + /* Prepare the IPI packet */ ipi.dest_id = lapic->apic_id; ipi.vector = 0; -- cgit v1.2.3