[RFC PATCH v3 14/27] KVM: SVM: Do not inhibit AVIC for SEV-SNP guests if Secure AVIC is enabled
From: Naveen N Rao (AMD)
Date: Wed Jul 08 2026 - 02:48:28 EST
Now that Secure AVIC mode is appropriately handled by the AVIC code, do
not inhibit APICv for SEV-SNP guests that have Secure AVIC enabled.
Signed-off-by: Naveen N Rao (AMD) <naveen@xxxxxxxxxx>
---
arch/x86/kvm/svm/sev.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/x86/kvm/svm/sev.c b/arch/x86/kvm/svm/sev.c
index a12e7e9f9fa1..00cb45ce145f 100644
--- a/arch/x86/kvm/svm/sev.c
+++ b/arch/x86/kvm/svm/sev.c
@@ -569,10 +569,10 @@ static int __sev_guest_init(struct kvm *kvm, struct kvm_sev_cmd *argp,
if (snp_is_secure_avic_enabled(kvm)) {
kvm->arch.apicv_has_irq_bypass = false;
to_kvm_svm(kvm)->avic_ipiv_is_not_supported = true;
+ } else {
+ kvm_set_apicv_inhibit(kvm, APICV_INHIBIT_REASON_SEV);
}
- kvm_set_apicv_inhibit(kvm, APICV_INHIBIT_REASON_SEV);
-
return 0;
e_free:
--
2.54.0