From: Kishon Vijay Abraham I Secure AVIC does not support injecting exception from the hypervisor. Take an early return from svm_inject_exception() for Secure AVIC enabled guests. Hardware takes care of delivering exceptions initiated by the guest as well as re-injecting exceptions initiated by the guest (in case there's an intercept before delivering the exception). Signed-off-by: Kishon Vijay Abraham I Signed-off-by: Neeraj Upadhyay --- arch/x86/kvm/svm/svm.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/x86/kvm/svm/svm.c b/arch/x86/kvm/svm/svm.c index 7811a87bc111..fdd612c975ae 100644 --- a/arch/x86/kvm/svm/svm.c +++ b/arch/x86/kvm/svm/svm.c @@ -374,6 +374,9 @@ static void svm_inject_exception(struct kvm_vcpu *vcpu) struct kvm_queued_exception *ex = &vcpu->arch.exception; struct vcpu_svm *svm = to_svm(vcpu); + if (sev_savic_active(vcpu->kvm)) + return; + kvm_deliver_exception_payload(vcpu, ex); if (kvm_exception_is_soft(ex->vector) && -- 2.34.1