KVM: nVMX: don't clear mtf_pending when nested events are blocked
[linux-2.6-microblaze.git] / arch / x86 / kvm / vmx / nested.c
index de23230..cbc9ea2 100644 (file)
@@ -3645,7 +3645,8 @@ static int vmx_check_nested_events(struct kvm_vcpu *vcpu)
         * Clear the MTF state. If a higher priority VM-exit is delivered first,
         * this state is discarded.
         */
-       vmx->nested.mtf_pending = false;
+       if (!block_nested_events)
+               vmx->nested.mtf_pending = false;
 
        if (lapic_in_kernel(vcpu) &&
                test_bit(KVM_APIC_INIT, &apic->pending_events)) {