Skip to content

Add -cpu host CPU type

Andre Przywara qemu-devel 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest6 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6allow hypervisor CPUID bit to be overridentarget-i386/helper.c+11 -120 replies
2/6introduce -cpu host targettarget-i386/helper.c+59 -60 replies
3/6CPUID Fn8000_0001.EAX is family/model/stepping, not featurestarget-i386/helper.c+1 -10 replies
4/6fix KVMs GET_SUPPORTED_CPUID feature usagetarget-i386/helper.c target-i386/kvm.c+22 -290 replies
5/6remove CPUID host hackstarget-i386/helper.c+5 -220 replies
6/6preserve the hypervisor bit while KVM trims the CPUID bitstarget-i386/cpu.h target-i386/kvm.c+5 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [Qemu-devel] [PATCH 0/6] Add -cpu host CPU type

Hi,

this patchset adds a new CPU type called "host" which mimics the host CPU in many ways. It's main usecase is to reveal most of the CPU features to KVM guests.
KVM provides in the kernel a feature to trim the guest's CPU bits to be not more capable than the host's one. This is currently broken in userspace (both qemu.git and qemu-kvm.git), so fix this on the way, since without it most guests will crash.
Additionally allow control over the hypervisor bit, which is somewhat special, because it's the only bit which is not present in the host, but should be set in the guest.
Patch 1-3 should apply easily to qemu-kvm.git, Patch 4 needs a little tweak. Patch 5 and 6 are entirely different, although it's broken there in a similar way. If you need the patchset against qemu-kvm.git, drop me a note.

Regards,
Andre.