On 24/12/2017 17:12, Liran Alon wrote: > > + kvm_before_handle_host_interrupts(vcpu); > local_irq_enable(); > + kvm_after_handle_host_interrupts(vcpu); > preempt_enable(); This should be around the call to kvm_x86_ops->handle_external_intr, not here. Also, perhaps you could: 1) do the kvm_before_handle_* unconditionally before the point where NMIs would be injected; 2) remove the kvm_after_handle_* from vmx_complete_atomic_exit and svm_vcpu_run; 3) only do kvm_after_handle_* after kvm_x86_ops->handle_external_intr, not before it. Paolo