Skip to content
Commit 5753743f authored by Haozhong Zhang's avatar Haozhong Zhang Committed by Radim Krčmář
Browse files

KVM: VMX: remove WARN_ON_ONCE in kvm_vcpu_trigger_posted_interrupt



WARN_ON_ONCE(pi_test_sn(&vmx->pi_desc)) in kvm_vcpu_trigger_posted_interrupt()
intends to detect the violation of invariant that VT-d PI notification
event is not suppressed when vcpu is in the guest mode. Because the
two checks for the target vcpu mode and the target suppress field
cannot be performed atomically, the target vcpu mode may change in
between. If that does happen, WARN_ON_ONCE() here may raise false
alarms.

As the previous patch fixed the real invariant breaker, remove this
WARN_ON_ONCE() to avoid false alarms, and document the allowed cases
instead.

Signed-off-by: default avatarHaozhong Zhang <haozhong.zhang@intel.com>
Reported-by: default avatar"Ramamurthy, Venkatesh" <venkatesh.ramamurthy@intel.com>
Reported-by: default avatarDan Williams <dan.j.williams@intel.com>
Reviewed-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
Fixes: 28b835d6

 ("KVM: Update Posted-Interrupts Descriptor when vCPU is preempted")
Signed-off-by: default avatarRadim Krčmář <rkrcmar@redhat.com>
parent dc91f2eb
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment