AROS SMP x86_64 fails to start application processors in Hyper-V
Describe the bug AROS fails to start the secondary AP's under HyperV. INIT and De-Assert IPI's appear to send correctly, but the startup/rip IPI causes a triple fault on the secondary AP, halting AROS
To Reproduce Steps to reproduce the behavior: Boot the SMP build in HyperV.
Expected behaviour AROS should start the cores and boot..
Screenshots
Architecture
- pc (native)
CPU
- x86_64
Additional context
The Last debug before the VM resets -:
[Kernel] PlatformAllocGDT[1]: GDT @ 0x0000000000102180 [Kernel] PlatformAllocTLS[1]: TLS @ 0x0000000000102370 [Kernel] PlatformAllocIDT[1]: Allocated IDT at 0x0000000000102400 [APIC] core_APIC_GetNumber() [APIC] core_APIC_GetNumber: APIC ID 000 [APIC] core_APIC_GetNumberFromLocal() [Kernel:APIC-IA32.000] core_APIC_Wake(001 @ 0000000000004000) [Kernel:APIC-IA32.000] core_APIC_Wake: Base @ 00000000fee00000 [APIC] core_APIC_GetNumber() [APIC] core_APIC_GetNumber: APIC ID 000 [APIC] core_APIC_GetNumberFromLocal() [Kernel:APIC-IA32.000] ia32_ipi_send: Command 0x0000C500 to target 001 [Kernel:APIC-IA32.000] ia32_ipi_send: Waiting for IPI to complete [Kernel:APIC-IA32.000] ia32_ipi_send: ... left wait loop (status = 0x00000000) [APIC] core_APIC_GetNumber() [APIC] core_APIC_GetNumber: APIC ID 000 [APIC] core_APIC_GetNumberFromLocal() [Kernel:APIC-IA32.000] ia32_ipi_send: Command 0x00088500 to target 001 [Kernel:APIC-IA32.000] ia32_ipi_send: Waiting for IPI to complete [Kernel:APIC-IA32.000] ia32_ipi_send: ... left wait loop (status = 0x00000000) [Kernel:APIC-IA32.000] core_APIC_Wake: Attempting STARTUP .. 1 [APIC] core_APIC_GetNumber() [APIC] core_APIC_GetNumber: APIC ID 000 [APIC] core_APIC_GetNumberFromLocal() [Kernel:APIC-IA32.000] ia32_ipi_send: Command 0x00000604 to target 001 [Kerne
- the VM reboots here.
Fault located - AVX hasn't been enabled on the secondary cores, causing AROS to crash when it creates the CPU context for the cores bootstrap task (which caches the current AVX register values).
Patch will be pushed later today.