VOGONS


First post, by superfury

User metadata
Rank l33t++
Rank
l33t++

What happens when in SMP a x86 AP processor triple faults? Does it broadcast a shutdown signal, forcing all CPU cores to reset (BSP to reset, all APs in waiting-for-SIPI state waiting to be woken up using INIT-SIPI-SIPI)? The BSP still sends a shutdown doing this when it triple faults afaik? What happens on one of the APs when it triple faults?

Author of the UniPCemu emulator.
UniPCemu Git repository
UniPCemu for Android, Windows, PSP, Vita and Switch on itch.io

Reply 1 of 4, by arjunae

User metadata
Rank Newbie
Rank
Newbie

I monitored this situation happening multiple times during development on a virtual machine which faults with a guru meditation. From what i read itl just stop an send a broadcast to all other cores which in turn will reset then. This should not happen in general with a correctly set up idt anyways.

Reply 2 of 4, by superfury

User metadata
Rank l33t++
Rank
l33t++
arjunae wrote on Today, 11:51:

I monitored this situation happening multiple times during development on a virtual machine which faults with a guru meditation. From what i read itl just stop an send a broadcast to all other cores which in turn will reset then. This should not happen in general with a correctly set up idt anyways.

What kind of broadcast does the (AP) CPU send? I'd assume some kind of IPI, but what kind (NMI, interrupt, SMI or perhaps what's programmed in the AP's error LVT)? The error vector programmed one? What about if it happens on the BSP? Will the BSP trigger a shutdown on the motherboard that triggers a global mothetboard-driven CPU reset (or INIT IPI to waiting-for-SIPI state for an AP)?

Author of the UniPCemu emulator.
UniPCemu Git repository
UniPCemu for Android, Windows, PSP, Vita and Switch on itch.io

Reply 3 of 4, by arjunae

User metadata
Rank Newbie
Rank
Newbie

hmm. let me see. intel docs are not very specific here. page 3386 only states that " The processor generates a special bus cycle to indicate that it has entered shutdown mode" no ipi i guess because the CPU core might not be healthy enough to talk to its Local APIC . what are you trying to archive ?

Reply 4 of 4, by superfury

User metadata
Rank l33t++
Rank
l33t++

Simply make my x86 emulator (UniPCemu) compatible with such cases. Right now the BSP triggers a full hardware-style reset of all cores (triggering their reset lines), while APs simply do nothing and halt in shutdown mode (to be reset using an INIT) when they triple fault (in fact, they all enter shutdown mode when a triple fault occurs (the affected core), while the BSP only triggers the system wide reset if the i440fx hardware is configured to respond to shutdown. Otherwise it will act like the other cores and remain in shutdown mode.

Author of the UniPCemu emulator.
UniPCemu Git repository
UniPCemu for Android, Windows, PSP, Vita and Switch on itch.io