diff options
-rw-r--r-- | drivers/kvm/vmx.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/kvm/vmx.c b/drivers/kvm/vmx.c index ad97014aa6eb..fc01c4b08fd5 100644 --- a/drivers/kvm/vmx.c +++ b/drivers/kvm/vmx.c | |||
@@ -884,6 +884,8 @@ static void vmx_set_segment(struct kvm_vcpu *vcpu, | |||
884 | ar |= (var->db & 1) << 14; | 884 | ar |= (var->db & 1) << 14; |
885 | ar |= (var->g & 1) << 15; | 885 | ar |= (var->g & 1) << 15; |
886 | } | 886 | } |
887 | if (ar == 0) /* a 0 value means unusable */ | ||
888 | ar = AR_UNUSABLE_MASK; | ||
887 | vmcs_write32(sf->ar_bytes, ar); | 889 | vmcs_write32(sf->ar_bytes, ar); |
888 | } | 890 | } |
889 | 891 | ||