FABRIC-3.10.8 MC-3b: waking a worker core

Each worker core sets up its own IPI receiver before going online (amd64
LAPIC + vector 0x22 with its own stub, aarch64 banked GIC SGI 0, riscv64
sie.SSIE); core 0 sends by ICR / GICD_SGIR / SBI IPI. Park lets exactly
one interrupt in without a lost-wake window. Boot self-test: IPI round
trips 3/3 and 'woke x3, IPIs x3' on all three ISAs; worker vCPU threads
0.0% on the host. 3-ISA acceptance clean.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Robert Allan James
2026-09-26 16:31:01 -04:00
co-authored by Claude Opus 5.5
parent d7745b49be
commit 71e0be96b0
24 changed files with 46016 additions and 8 deletions
+9
View File
@@ -60,6 +60,11 @@
* before, so this path was previously dormant. */
#define APIC_SPURIOUS_VECTOR 0xFF
/* amd64 (FABRIC-3.10.8 MC-3b): the inter-processor wake vector. Needs its
* own stub in isr.S -- vectors past 33 otherwise land in the default stub,
* which reports 255. */
#define SK_IPI_VECTOR 0x22
/* Initialize Local APIC (enables APIC, sets spurious vector) */
int apic_init(BootInfo *boot_info);
@@ -72,6 +77,10 @@ uint8_t apic_id(void);
* Returns 0 once delivered, -1 if still pending after the bound. */
int apic_send_ipi(uint8_t dest_apic_id, uint32_t icr_low);
/* amd64 (MC-3b): on a secondary core, enable its own LAPIC (SIVR, TPR 0)
* so it can take SK_IPI_VECTOR. Its timer LVT stays masked. */
void apic_secondary_enable(void);
/* Send End-of-Interrupt signal */
void apic_eoi(void);