All of lore.kernel.org
 help / color / mirror / Atom feed
* Question about XEN Hypervisor MSR capability exposion to VMs
@ 2015-10-31  2:53 Liuyingdong
  2015-11-02  2:04 ` Zhang, Yang Z
  2015-11-02 11:00 ` Andrew Cooper
  0 siblings, 2 replies; 3+ messages in thread
From: Liuyingdong @ 2015-10-31  2:53 UTC (permalink / raw)
  To: xen-devel
  Cc: kevin.tian, wei.liu2, andrew.cooper3, Huangpeng (Peter),
	dietmar.hahn, huangzhichao@huawei.com >> Huangzhichao,
	boris.ostrovsky

Hi All

We encountered a blue screen problem when live migrate
Win8.1/Win2012R2 64bit VM from V3 processor to non-V3
processor sandbox, KVM does not has this problem.

After looking into the MSR capabilities, we found XEN
hypervisor exposed bit 39 and bit 18 to the VM, from
Intel manual bit 39 refers to reserve bit and should
not be set, bit 18 refers to MWAIT/MONITOR capability,
from my understanding it should not exposed to the VM
too.
BTW, KVM does not expose bit 18/39 to the VM.

Below is the boot message:
(XEN) read msr: ecx=c0000083, msr_value=0xfffff80028ddf240
(XEN) read msr: ecx=1a0, msr_value=0x4000801889
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
(XEN) write msr:msr=40000071, msr_value=0x10000000000082f
(XEN) write msr:msr=40000070, msr_value=0x0
(XEN) write msr:msr=40000071, msr_value=0x20000000000082f
(XEN) write msr:msr=40000070, msr_value=0x0
(XEN) read msr: ecx=17, msr_value=0x0
(XEN) write msr:msr=8b, msr_value=0x0
(XEN) read msr: ecx=8b, msr_value=0x2d00000000

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Question about XEN Hypervisor MSR capability exposion to VMs
  2015-10-31  2:53 Question about XEN Hypervisor MSR capability exposion to VMs Liuyingdong
@ 2015-11-02  2:04 ` Zhang, Yang Z
  2015-11-02 11:00 ` Andrew Cooper
  1 sibling, 0 replies; 3+ messages in thread
From: Zhang, Yang Z @ 2015-11-02  2:04 UTC (permalink / raw)
  To: Liuyingdong, xen-devel@lists.xen.org
  Cc: Tian, Kevin, wei.liu2@citrix.com, andrew.cooper3@citrix.com,
	Huangpeng (Peter), dietmar.hahn@ts.fujitsu.com,
	huangzhichao@huawei.com >> Huangzhichao,
	boris.ostrovsky@oracle.com

Liuyingdong wrote on 2015-10-31:
> Hi All
> 
> We encountered a blue screen problem when live migrate
> Win8.1/Win2012R2 64bit VM from V3 processor to non-V3 processor
> sandbox, KVM does not has this problem.
> 
> After looking into the MSR capabilities, we found XEN hypervisor
> exposed bit 39 and bit 18 to the VM, from Intel manual bit 39 refers
> to reserve bit and should not be set, bit 18 refers to MWAIT/MONITOR

Reserved doesn't mean it must be zero or one. Can you help to check it on host?

> capability, from my understanding it should not exposed to the VM too.

Yes, the MWAIT/MONITOR should be hidden from guest.

> BTW, KVM does not expose bit 18/39 to the VM.
> 
> Below is the boot message: (XEN) read msr: ecx=c0000083,
> msr_value=0xfffff80028ddf240 (XEN) read msr: ecx=1a0,
> msr_value=0x4000801889
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ (XEN)
> write msr:msr=40000071, msr_value=0x10000000000082f (XEN) write
> msr:msr=40000070, msr_value=0x0 (XEN) write msr:msr=40000071,
> msr_value=0x20000000000082f (XEN) write msr:msr=40000070, msr_value=0x0
> (XEN) read msr: ecx=17, msr_value=0x0 (XEN) write msr:msr=8b,
> msr_value=0x0 (XEN) read msr: ecx=8b, msr_value=0x2d00000000



Best regards,
Yang

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Question about XEN Hypervisor MSR capability exposion to VMs
  2015-10-31  2:53 Question about XEN Hypervisor MSR capability exposion to VMs Liuyingdong
  2015-11-02  2:04 ` Zhang, Yang Z
@ 2015-11-02 11:00 ` Andrew Cooper
  1 sibling, 0 replies; 3+ messages in thread
From: Andrew Cooper @ 2015-11-02 11:00 UTC (permalink / raw)
  To: Liuyingdong, xen-devel
  Cc: kevin.tian, wei.liu2, Huangpeng (Peter), dietmar.hahn,
	huangzhichao@huawei.com >> Huangzhichao, boris.ostrovsky

On 31/10/15 02:53, Liuyingdong wrote:
> Hi All
>
> We encountered a blue screen problem when live migrate
> Win8.1/Win2012R2 64bit VM from V3 processor to non-V3
> processor sandbox, KVM does not has this problem.
>
> After looking into the MSR capabilities, we found XEN
> hypervisor exposed bit 39 and bit 18 to the VM, from
> Intel manual bit 39 refers to reserve bit and should
> not be set, bit 18 refers to MWAIT/MONITOR capability,
> from my understanding it should not exposed to the VM
> too.
> BTW, KVM does not expose bit 18/39 to the VM.
>
> Below is the boot message:
> (XEN) read msr: ecx=c0000083, msr_value=0xfffff80028ddf240
> (XEN) read msr: ecx=1a0, msr_value=0x4000801889
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> (XEN) write msr:msr=40000071, msr_value=0x10000000000082f
> (XEN) write msr:msr=40000070, msr_value=0x0
> (XEN) write msr:msr=40000071, msr_value=0x20000000000082f
> (XEN) write msr:msr=40000070, msr_value=0x0
> (XEN) read msr: ecx=17, msr_value=0x0
> (XEN) write msr:msr=8b, msr_value=0x0
> (XEN) read msr: ecx=8b, msr_value=0x2d00000000
>

Xen currently does not make any attempt to level MSRs (it is unfortunate
that this area has been overlooked).

I have also encountered windows BSODs for this - 0x109 Critical
Structure Corruption I am guessing?

I am currently working on fixes to CPUID levelling (as it is more
important than MSRs at the moment), but have plans to fix MSR levelling
after that.

~Andrew

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-11-02 11:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-31  2:53 Question about XEN Hypervisor MSR capability exposion to VMs Liuyingdong
2015-11-02  2:04 ` Zhang, Yang Z
2015-11-02 11:00 ` Andrew Cooper

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.