提交 72636420 编写于 作者: A Avi Kivity 提交者: Marcelo Tosatti

KVM: VMX: Return real real-mode segment data even if emulate_invalid_guest_state=1

emulate_invalid_guest_state=1 doesn't mean we don't munge the segments in the
vmcs; we do.  So we need to return the real ones (maintained by vmx_set_segment).
Signed-off-by: NAvi Kivity <avi@redhat.com>
Signed-off-by: NMarcelo Tosatti <mtosatti@redhat.com>
上级 0afbe2f8
...@@ -3108,8 +3108,7 @@ static void vmx_get_segment(struct kvm_vcpu *vcpu, ...@@ -3108,8 +3108,7 @@ static void vmx_get_segment(struct kvm_vcpu *vcpu,
if (vmx->rmode.vm86_active if (vmx->rmode.vm86_active
&& (seg == VCPU_SREG_TR || seg == VCPU_SREG_ES && (seg == VCPU_SREG_TR || seg == VCPU_SREG_ES
|| seg == VCPU_SREG_DS || seg == VCPU_SREG_FS || seg == VCPU_SREG_DS || seg == VCPU_SREG_FS
|| seg == VCPU_SREG_GS) || seg == VCPU_SREG_GS)) {
&& !emulate_invalid_guest_state) {
*var = vmx->rmode.segs[seg]; *var = vmx->rmode.segs[seg];
if (seg == VCPU_SREG_TR if (seg == VCPU_SREG_TR
|| var->selector == vmx_read_guest_seg_selector(vmx, seg)) || var->selector == vmx_read_guest_seg_selector(vmx, seg))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册