WHPX x86 updates for QEMU 11.1
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v3 Latest37 patches 7 repliesIn review
- v238 patches 1 replySuperseded
- v138 patches 0 repliesSuperseded
v1->v2 from the cover letter
- Build fixup for macOS and OpenBSD
- a bit of cleanup
Patches in v3 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/37 | target/i386: emulate: include name of unhandled instructiontarget/ | +2 | 0 replies | |
| 2/37 | whpx: i386: x2apic emulationtarget/ | +133 | 0 replies | |
| 3/37 | whpx: i386: wire up feature probinginclude/ target/ target/ +3 more | +370 | 0 replies | |
| 4/37 | whpx: i386: disable TbFlushHypercalls for emulated LAPICtarget/ | +6 | 0 replies | |
| 5/37 | whpx: i386: enable x2apic by default for user-mode LAPICtarget/ | +7 | 0 replies | |
| 6/37 | whpx: i386: reintroduce enlightenments for Windows 10accel/ include/ target/ +1 more | +58 | 0 replies | |
| 7/37 | whpx: i386: introduce proper cpuid supporttarget/ target/ | +122 | 0 replies | |
| 8/37 | whpx: i386: kernel-irqchip=off fixesinclude/ target/ | +7 | 0 replies | |
| 9/37 | whpx: i386: use WHvX64RegisterCr8 only when kernel-irqchip=offtarget/ | +22 | 0 replies | |
| 10/37 | whpx: i386: disable kernel-irqchip on Windows 10 when PIC enabledtarget/ | +39 | 0 replies | |
| 11/37 | whpx: i386: IO port fast path cleanuptarget/ | +13 | 0 replies | |
| 12/37 | whpx: i386: disable enlightenments and LAPIC for isapctarget/ | +8 | 0 replies | |
| 13/37 | whpx: i386: interrupt priority supporttarget/ | +20 | 0 replies | |
| 14/37 | hw/intc: apic: disallow APIC reads when disabledhw/ | +9 | 0 replies | |
| 15/37 | whpx: i386: fix CPUID[1:EDX].APIC reportinginclude/ target/ target/ | +84 | 0 replies | |
| 16/37 | whpx: i386: set apicbase value only on successtarget/ | +2 | 0 replies | |
| 17/37 | whpx: i386: unknown MSR configurabilityaccel/ include/ include/ +2 more | +54 | 0 replies | |
| 18/37 | whpx: i386: enable GuestIdleReg enlightenmenttarget/ | +1 | 0 replies | |
| 19/37 | whpx: i386: tighten APIC base validity checktarget/ | +3 | 0 replies | |
| 20/37 | whpx: i386: ignore vpassist when kernel-irqchip=offtarget/ | +13 | 0 replies | |
| 21/37 | target: i386: HLT type that ignores EFLAGS.IFtarget/ target/ | +8 | 1 reply | |
| 22/37 | whpx: i386: add HV_X64_MSR_GUEST_IDLE when !kernel-irqchiptarget/ | +43 | 1 reply | |
| 23/37 | whpx: i386: some x2APIC awarenesstarget/ | +10 | 0 replies | |
| 24/37 | whpx: i386: set WHvX64RegisterInitialApicIdtarget/ | +5 | 0 replies | |
| 25/37 | whpx: i386: Pause VM on fatal exception to be able to inspect statetarget/ | +1 | 0 replies | |
| 26/37 | target/i386: emulate: use exception_payload for fault addresstarget/ target/ | +5 | 1 reply | |
| 27/37 | target/i386: make xsave_buf present unconditionallytarget/ | +0 | 0 replies | |
| 28/37 | target/i386: add de/compaction to xsave_helpertarget/ target/ | +258 | 1 reply | |
| 29/37 | whpx: xsave supportinclude/ target/ | +292 | 0 replies | |
| 30/37 | whpx: i386: set APIC ID only when APIC presenttarget/ | +1 | 0 replies | |
| 31/37 | whpx: i386: update migration blocker messagetarget/ | +2 | 0 replies | |
| 32/37 | whpx: i386: don't increment eip on MSR access raising GPFtarget/ | +12 | 0 replies | |
| 33/37 | target/i386: emulate, hvf: rdmsr/wrmsr GPF handlingtarget/ target/ target/ +1 more | +17 | 0 replies | |
| 34/37 | whpx: i386: add feature to intercept #GP MSR accessesaccel/ include/ target/ | +166 | 0 replies | |
| 35/37 | whpx: i386: nested virt settingsaccel/ include/ target/ | +66 | 2 replies | |
| 36/37 | whpx: i386: add SeparateSecurityDomain flag and make defaultaccel/ include/ target/ | +65 | 0 replies | |
| 37/37 | whpx: i386: documentation updatedocs/ | +11 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v3 yet.
Cover letter [PATCH v3 00/37] WHPX x86 updates for QEMU 11.1
This rolls over my previous series posted earlier in this mailing list. ..and adds some more.
Git tree: https://github.com/mediouni-m/qemu whpx-i386-202604-4
Some highlights:
1
- user-mode x2APIC emulation (kernel-irqchip=off) for better performance when it has to be used.
- CPU model emulation on both Windows 10 and 11
- configurable behavior for unknown MSRs and adding a way to trap on GPFs raised by Hyper-V on MSR acccess
- when -M hyperv=off, report the hypervisor as VMware for guests to use either the VMware CPUID leaf or the vmport interface to get the TSC and APIC frequencies.
If the vmware CPUID frequency leaf is disabled, then KVM is reported.
- xsave save/restore support
- Pause the VM to be able to inspect state on a fatal fault instead of just exiting
- adding emulation of an oddball idle MSR used by Windows when kernel-irqchip=off.
- disable kernel-irqchip and Hyper-V enlightenments for isapc
- for Windows 10, change the default to an emulated x2APIC (kernel-irqchip=off). The recommended way to use the Hyper-V LAPIC is not to use -M kernel-irqchip=on, but -M pic=off.
And as the last commit, a documentation update.
Bug reports and patches are welcome.
However, due to reasons, I'll probably step aside from this all for a bit so don't expect immediate replies.
v1->v2:
- Build fixup for macOS and OpenBSD
- a bit of cleanup
v2->v3:
Unfortunately this rev has quite a bit of changes...
- Some fixes here and there.
- Merging in Windows 10 support into something less separate.
- Move new x86-specific (at least for now) properties into a new whpx_arch_accel_class_init method.
- Add nested virt settings and separate security domain accelerator properties.
Magnus Kulke (1):
target/i386: add de/compaction to xsave_helper
Mohamed Mediouni (36):
target/i386: emulate: include name of unhandled instruction
whpx: i386: x2apic emulation
whpx: i386: wire up feature probing
whpx: i386: disable TbFlushHypercalls for emulated LAPIC
whpx: i386: enable x2apic by default for user-mode LAPIC
whpx: i386: reintroduce enlightenments for Windows 10
whpx: i386: introduce proper cpuid support
whpx: i386: kernel-irqchip=off fixes
whpx: i386: use WHvX64RegisterCr8 only when kernel-irqchip=off
whpx: i386: disable kernel-irqchip on Windows 10 when PIC enabled
whpx: i386: IO port fast path cleanup
whpx: i386: disable enlightenments and LAPIC for isapc
whpx: i386: interrupt priority support
hw/intc: apic: disallow APIC reads when disabled
whpx: i386: fix CPUID[1:EDX].APIC reporting
whpx: i386: set apicbase value only on success
whpx: i386: unknown MSR configurability
whpx: i386: enable GuestIdleReg enlightenment
whpx: i386: tighten APIC base validity check
whpx: i386: ignore vpassist when kernel-irqchip=off
target: i386: HLT type that ignores EFLAGS.IF
whpx: i386: add HV_X64_MSR_GUEST_IDLE when !kernel-irqchip
whpx: i386: some x2APIC awareness
whpx: i386: set WHvX64RegisterInitialApicId
whpx: i386: Pause VM on fatal exception to be able to inspect state target/i386: emulate: use exception_payload for fault address target/i386: make xsave_buf present unconditionally
whpx: xsave support
whpx: i386: set APIC ID only when APIC present
whpx: i386: update migration blocker message
whpx: i386: don't increment eip on MSR access raising GPF target/i386: emulate, hvf: rdmsr/wrmsr GPF handling
whpx: i386: add feature to intercept #GP MSR accesses
whpx: i386: nested virt settings
whpx: i386: add SeparateSecurityDomain flag and make default
whpx: i386: documentation update
accel/whpx/whpx-common.c | 8 + docs/system/whpx.rst | 40 +- hw/intc/apic.c | 9 + include/system/whpx-all.h | 1 + include/system/whpx-common.h | 2 +- include/system/whpx-internal.h | 31 + target/arm/whpx/whpx-all.c | 5 + target/i386/cpu.c | 27 +- target/i386/cpu.h | 6 +- target/i386/emulate/x86_emu.c | 14 +- target/i386/emulate/x86_emu.h | 4 +- target/i386/emulate/x86_mmu.c | 3 +- target/i386/hvf/hvf-i386.h | 4 +- target/i386/hvf/hvf.c | 9 +- target/i386/whpx/meson.build | 1 + target/i386/whpx/whpx-all.c | 1489 +++++++++++++++++++++++----- target/i386/whpx/whpx-apic.c | 83 +- target/i386/whpx/whpx-cpu-legacy.c | 158 +++ target/i386/whpx/whpx-i386.h | 12 + target/i386/xsave_helper.c | 256 +++++ 20 files changed, 1875 insertions(+), 287 deletions(-) create mode 100644 target/i386/whpx/whpx-cpu-legacy.c create mode 100644 target/i386/whpx/whpx-i386.h
Signature · 1 line
2.50.1 (Apple Git-155)