Re: [RFC PATCH v3 03/27] x86/kvm: Disable PV_SEND_IPI if Secure AVIC is enabled

From: Naveen N Rao

Date: Tue Jul 14 2026 - 05:53:13 EST


On Mon, Jul 13, 2026 at 12:52:06PM -0500, Tom Lendacky wrote:
> On 7/8/26 01:32, Naveen N Rao (AMD) wrote:
> > In Secure AVIC mode, Linux does not allow IPIs to be injected as the
> > hypervisor is untrusted. This is achieved by not setting the IPI vector
> > in SAVIC_ALLOWED_IRR in the Secure AVIC guest APIC Backing page. Due to
> > this, PV_SEND_IPI cannot work since it needs KVM to be able to inject
> > IPIs into the guest. Disable the same.
>
> Another guest patch...
>
> Does this have an impact on the hypervisor? Is the injected IPI just
> ignored because of the SAVIC_ALLOWED_IRR? How would the hypervisor know
> that it needs to schedule the target vCPU if not using this, a write to
> the ICR?

No impact on the hypervisor. Previous KVM implementation relied on
disabling these at the hypervisor level, which is ok too. But, this
really should be a guest policy since PV_SEND_IPI can work if the guest
chooses to allow IPIs (via SAVIC_ALLOWED_IRR).

In the absence of this, guest will use the regular IPI path and go
through the savic driver, which will do a SVM_EXIT_MSR VMGEXIT to
request hypervisor assistance for IPI delivery.


- Naveen