summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2019-01-30 17:25:38 +0100
committerPaolo Bonzini <pbonzini@redhat.com>2019-02-20 22:48:24 +0100
commite0dfacbfe91ad7947f0c44829c0358ac2e17d3c6 (patch)
tree122d325477dfd9300debc8a827b27261d4ac5ceb
parent34333cc6c2cb021662fd32e24e618d1b86de95bf (diff)
KVM: nVMX: remove useless is_protmode check
VMX is only accessible in protected mode, remove a confusing check that causes the conditional to lack a final "else" branch. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
-rw-r--r--arch/x86/kvm/vmx/nested.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kvm/vmx/nested.c b/arch/x86/kvm/vmx/nested.c
index 0050c179c5d3..be9b2c8fd32e 100644
--- a/arch/x86/kvm/vmx/nested.c
+++ b/arch/x86/kvm/vmx/nested.c
@@ -4056,7 +4056,7 @@ int get_vmx_mem_address(struct kvm_vcpu *vcpu, unsigned long exit_qualification,
* destination for long mode!
*/
exn = is_noncanonical_address(*ret, vcpu);
- } else if (is_protmode(vcpu)) {
+ } else {
/*
* When not in long mode, the virtual/linear address is
* unconditionally truncated to 32 bits regardless of the