]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
KVM: VMX: avoid guest hang on invalid invvpid instruction
authorPaolo Bonzini <pbonzini@redhat.com>
Fri, 18 Mar 2016 15:53:42 +0000 (16:53 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 12 Apr 2016 16:08:34 +0000 (09:08 -0700)
commit f6870ee9e53430f2a318ccf0dd5e66bb46194e43 upstream.

A guest executing an invalid invvpid instruction would hang
because the instruction pointer was not updated.

Reported-by: jmontleo@redhat.com
Tested-by: jmontleo@redhat.com
Fixes: 99b83ac893b84ed1a62ad6d1f2b6cc32026b9e85
Reviewed-by: David Matlack <dmatlack@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/x86/kvm/vmx.c

index 89d5e02b14aec11bc998020d9d460daab345afbb..75d5d5b75e1f1eae267ae6a1bae60893b47d328c 100644 (file)
@@ -7399,6 +7399,7 @@ static int handle_invvpid(struct kvm_vcpu *vcpu)
        if (!(types & (1UL << type))) {
                nested_vmx_failValid(vcpu,
                        VMXERR_INVALID_OPERAND_TO_INVEPT_INVVPID);
+               skip_emulated_instruction(vcpu);
                return 1;
        }