unable to boot windows with 256 cpus
While testing ACPI cpu hotplug changes I stumbled on BSOD in case QEMU is configured with 256 CPUs, Windows Server 2012R2x64 fails to boot with bugcheck 5C
qemu-system-x86_64 -m 4G -smp 2,sockets=64,cores=4,maxcpus=256 -M q35,kernel-irqchip=split -enable-kvm -device intel-iommu,intremap=on,eim=on ws2012r2x64DCchk.qcow2
Looking at stacktrace, it seems that is fails when trying to initialize iommu
hal_interrupt_remapping_setup_failure_nt!initbootprocessor
Any idea what to try to figure out what QEMU is missing wrt intremap?
PS:
WS2016 boots eventually, but CPU hotplug doesn't work, symptoms (unconfirmed yet) like SCI isn't being delivered. With RHEL76 the same config works fine.
---
*******************************************************************************
* * * Bugcheck Analysis * * *
*******************************************************************************
HAL_INITIALIZATION_FAILED (5c)
Arguments:
Arg1: 0000000000007000
Arg2: 0000000000000618
Arg3: ffffffffc00000bb
Arg4: 0000000000000000
Debugging Details:
------------------
DEFAULT_BUCKET_ID: WIN8_DRIVER_FAULT
BUGCHECK_STR: 0x5C
CURRENT_IRQL: 0
ANALYSIS_VERSION: 6.3.9600.16384 (debuggers(dbg).130821-1623) amd64fre
DPC_STACK_BASE: FFFFF80225BE3FB0
LAST_CONTROL_TRANSFER: from fffff80221aa9714 to fffff80221c95801
STACK_TEXT:fffff80225bdbcd8 fffff80221aa9714 : fffff6fc01114af8 fffff6fb7e0088a0 fffff6fb7dbf0040 fffff6fb7dbedf80 : nt!DbgBreakPointWithStatus+0x1 fffff80225bdbce0 fffff80221aaabff : 0000000000000004 0000000000000000 0000000000000000 ffffffffc00000bb : nt!KiBugCheckDebugBreak+0x14 fffff80225bdbd50 fffff80221c8fb94 : 000000000000005c 0000000000007000 0000000000000618 ffffffffc00000bb : nt!KeBugCheck2+0xdd7 fffff80225bdc460 fffff8022297c94a : 000000000000005c 0000000000007000 0000000000000618 ffffffffc00000bb : nt!KeBugCheckEx+0x104 fffff80225bdc4a0 fffff8022297c9ac : fffff80220c735d0 0000000000000000 0000000000000009 fffff80220c735f0 : hal!HalpInitializeInterrupts+0x406 fffff80225bdc4f0 fffff802229728aa : fffff80220c735d0 fffff802229742ce fffff80220c735d0 0000000000000007 : hal!HalpInterruptInitDiscard+0x3c fffff80225bdc520 fffff8022297221c : fffff80200000008 0000000000000000 fffff80220c735d0 0000000000000008 : hal!HalpInterruptInitSystem+0xf6 fffff80225bdc560 fffff8022297c537 : fffff80200000006 fffff8020000000c fffff80220c735d0 fffff80220c735d0 : hal!HalpInitSystemHelper+0x44 fffff80225bdc5c0 fffff8022285467d : fffff80220c735d0 fffff80220c735d0 fffff80225bdc6f0 0000000000010228 : hal!HalpInitSystemPhase0+0x1b fffff80225bdc5f0 fffff802222d065f : fffff80220c735d0 0000000000000000 0000000000000000 fffff80221cf6180 : nt!InitBootProcessor+0x265 fffff80225bdc870 fffff802222e4073 : fffff802222ae400 fffff802222aeac0 fffff80225bdd000 fffff80221cf6180 : nt!KiInitializeKernel+0xd83 fffff80225bdcc10 0000000000000000 : 0000000000000000 0000000000000000 0000000000000000 0000000000000000 : nt!KiSystemStartup+0x193
STACK_COMMAND: kb
FOLLOWUP_IP:
nt!InitBootProcessor+265
fffff802`2285467d 84c0 test al,al
SYMBOL_STACK_INDEX: 9
SYMBOL_NAME: nt!InitBootProcessor+265
FOLLOWUP_NAME: MachineOwner
MODULE_NAME: nt
IMAGE_NAME: ntkrnlmp.exe
DEBUG_FLR_IMAGE_TIMESTAMP: 5215d150
IMAGE_VERSION: 6.3.9600.16384
BUCKET_ID_FUNC_OFFSET: 265
FAILURE_BUCKET_ID: 0x5C_HAL_INTERRUPT_REMAPPING_SETUP_FAILURE_nt!InitBootProcessor
BUCKET_ID: 0x5C_HAL_INTERRUPT_REMAPPING_SETUP_FAILURE_nt!InitBootProcessor
ANALYSIS_SOURCE: KM
FAILURE_ID_HASH_STRING: km:0x5c_hal_interrupt_remapping_setup_failure_nt!initbootprocessor
FAILURE_ID_HASH: {85a33624-5d0e-3044-bbaa-0bdba50d221b}
Quoted 9 lines · Igor Mammedov
While testing ACPI cpu hotplug changes I stumbled on BSOD in case QEMU is configured with 256 CPUs, Windows Server 2012R2x64 fails to boot with bugcheck 5C
qemu-system-x86_64 -m 4G -smp 2,sockets=64,cores=4,maxcpus=256 -M q35,kernel-irqchip=split -enable-kvm -device intel-iommu,intremap=on,eim=on ws2012r2x64DCchk.qcow2
Looking at stacktrace, it seems that is fails when trying to initialize iommu
Quoted 7 lines
hal_interrupt_remapping_setup_failure_nt!initbootprocessor
Any idea what to try to figure out what QEMU is missing wrt intremap?
PS:
WS2016 boots eventually, but CPU hotplug doesn't work, symptoms (unconfirmed yet) like SCI isn't being delivered. With RHEL76 the same config works fine.
Igor,
Could you try this again but with vtd tracepoints enabled?
-trace enable="vtd_*"
I think we don't need to capture all the trace outputs, but only until when the HAL error message triggered should work.
Thanks,
Signature · 1 line
Peter Xu
Quoted 18 lines · On Wed, 15 Jul 2020 14:28:19 -0400 Peter Xu <[email protected]> wrote:
Quoted 9 lines · Igor Mammedov
While testing ACPI cpu hotplug changes I stumbled on BSOD in case QEMU is configured with 256 CPUs, Windows Server 2012R2x64 fails to boot with bugcheck 5C
qemu-system-x86_64 -m 4G -smp 2,sockets=64,cores=4,maxcpus=256 -M q35,kernel-irqchip=split -enable-kvm -device intel-iommu,intremap=on,eim=on ws2012r2x64DCchk.qcow2
Looking at stacktrace, it seems that is fails when trying to initialize iommu
Quoted 7 lines
hal_interrupt_remapping_setup_failure_nt!initbootprocessor
Any idea what to try to figure out what QEMU is missing wrt intremap?
PS:
WS2016 boots eventually, but CPU hotplug doesn't work, symptoms (unconfirmed yet) like SCI isn't being delivered. With RHEL76 the same config works fine.
Quoted 8 lines
Igor,
Could you try this again but with vtd tracepoints enabled?
-trace enable="vtd_*"
I think we don't need to capture all the trace outputs, but only until when the HAL error message triggered should work.
here is all it outputs.
[email protected]:vtd_context_cache_reset [email protected]:vtd_switch_address_space Device 00:00.0 switching address space (iommu enabled=0) [email protected]:vtd_switch_address_space Device 00:01.0 switching address space (iommu enabled=0) [email protected]:vtd_switch_address_space Device 00:02.0 switching address space (iommu enabled=0) [email protected]:vtd_switch_address_space Device 00:1f.0 switching address space (iommu enabled=0) [email protected]:vtd_switch_address_space Device 00:1f.2 switching address space (iommu enabled=0) [email protected]:vtd_switch_address_space Device 00:1f.3 switching address space (iommu enabled=0) [email protected]:vtd_context_cache_reset [email protected]:vtd_switch_address_space Device 00:00.0 switching address space (iommu enabled=0) [email protected]:vtd_switch_address_space Device 00:01.0 switching address space (iommu enabled=0) [email protected]:vtd_switch_address_space Device 00:02.0 switching address space (iommu enabled=0) [email protected]:vtd_switch_address_space Device 00:1f.0 switching address space (iommu enabled=0) [email protected]:vtd_switch_address_space Device 00:1f.2 switching address space (iommu enabled=0) [email protected]:vtd_switch_address_space Device 00:1f.3 switching address space (iommu enabled=0)
Quoted 3 lines
Thanks,