Re: [PATCH] target-i386: kvm: cache KVM_GET_SUPPORTED_CPUID data

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jun 14, 2016 at 10:21:41AM +0200, Paolo Bonzini wrote:
> 
> 
> On 14/06/2016 07:01, Chao Peng wrote:
> >> > 
> >> > Which are the CPUID leaves for which KVM_GET_SUPPORTED_CPUID is not
> >> > stateless?  I cannot find any.
> > I have though leaf 0xd, sub leaf 1 is not stateless, as the size of
> > xsave buffer(EBX) is based on XCR0 | IA32_XSS. But after looking KVM
> > code more carefully, seems I was wrong. The code calculates EBX with the
> > host xcr0 but not guest xcr0, nor guest IA32_XSS (not sure if this is
> > the correct behavior), so it can always returns constant data on a
> > certain machine.
> 
> Indeed, KVM computes the correct value at runtime, but
> KVM_GET_SUPPORTED_CPUID runs before there is a value for guest XCR0 or
> guest IA32_XSS.

Yes, this is the point.

> 
> Thanks, I've queued the patch for QEMU 2.7.

Thanks :)

Chao
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux