KVM: x86: Fix exception reinjection forced to true
authorJoerg Roedel <joerg.roedel@amd.com>
Wed, 5 May 2010 14:04:41 +0000 (16:04 +0200)
committerAvi Kivity <avi@redhat.com>
Wed, 19 May 2010 08:36:37 +0000 (11:36 +0300)
The patch merged recently which allowed to mark an exception
as reinjected has a bug as it always marks the exception as
reinjected. This breaks nested-svm shadow-on-shadow
implementation.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
arch/x86/kvm/x86.c

index 54f73b6..161ede2 100644 (file)
@@ -277,7 +277,7 @@ static void kvm_multiple_exception(struct kvm_vcpu *vcpu,
                vcpu->arch.exception.has_error_code = has_error;
                vcpu->arch.exception.nr = nr;
                vcpu->arch.exception.error_code = error_code;
-               vcpu->arch.exception.reinject = true;
+               vcpu->arch.exception.reinject = reinject;
                return;
        }