From: Fred Griffoul For consistency with commit 7afe79f5734a ("KVM: nVMX: Mark vmcs12's APIC access page dirty when unmapping"), which marks the page dirty during unmap operations, also mark it dirty during vmcs12 page synchronization. Signed-off-by: Fred Griffoul [sean: use kvm_vcpu_map_mark_dirty()] Signed-off-by: Sean Christopherson --- arch/x86/kvm/vmx/vmx.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/arch/x86/kvm/vmx/vmx.c b/arch/x86/kvm/vmx/vmx.c index cc38d08935e8..72ac42fdf3b1 100644 --- a/arch/x86/kvm/vmx/vmx.c +++ b/arch/x86/kvm/vmx/vmx.c @@ -6382,10 +6382,7 @@ static void nested_vmx_mark_all_vmcs12_pages_dirty(struct kvm_vcpu *vcpu) { struct vcpu_vmx *vmx = to_vmx(vcpu); - /* - * Don't need to mark the APIC access page dirty; it is never - * written to by the CPU during APIC virtualization. - */ + kvm_vcpu_map_mark_dirty(vcpu, &vmx->nested.apic_access_page_map); kvm_vcpu_map_mark_dirty(vcpu, &vmx->nested.virtual_apic_map); kvm_vcpu_map_mark_dirty(vcpu, &vmx->nested.pi_desc_map); } -- 2.52.0.rc2.455.g230fcf2819-goog