]> git.ipfire.org Git - thirdparty/linux.git/commit
KVM: nVMX: Switch to vmcs01 to update APIC page on-demand if L2 is active
authorSean Christopherson <seanjc@google.com>
Fri, 9 Jan 2026 03:45:30 +0000 (19:45 -0800)
committerSean Christopherson <seanjc@google.com>
Wed, 14 Jan 2026 01:35:32 +0000 (17:35 -0800)
commit51c821d6d0ba038506d8b1c522f0b2b0ed756dd3
tree05cbc420f2141aabfa9f271a872333cf5b8d0053
parent2bf889a68fbab33133ef9ec1000399913b2c65c4
KVM: nVMX: Switch to vmcs01 to update APIC page on-demand if L2 is active

If the KVM-owned APIC-access page is migrated while L2 is running,
temporarily load vmcs01 and immediately update APIC_ACCESS_ADDR instead
of deferring the update until the next nested VM-Exit.  Once changing
the virtual APIC mode is converted to always do on-demand updates, all
of the "defer until vmcs01 is active" logic will be gone.

Reviewed-by: Chao Gao <chao.gao@intel.com>
Link: https://patch.msgid.link/20260109034532.1012993-7-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
arch/x86/kvm/vmx/nested.c
arch/x86/kvm/vmx/vmx.c
arch/x86/kvm/vmx/vmx.h