Skip to content

Commit 56fe28d

Browse files
Maxim Levitskybonzini
authored andcommitted
KVM: nSVM: mark vmcb as dirty when forcingly leaving the guest mode
We overwrite most of vmcb fields while doing so, so we must mark it as dirty. Signed-off-by: Maxim Levitsky <mlevitsk@redhat.com> Message-Id: <20210107093854.882483-5-mlevitsk@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
1 parent 81f76ad commit 56fe28d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

arch/x86/kvm/svm/nested.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -754,6 +754,7 @@ void svm_leave_nested(struct vcpu_svm *svm)
754754
leave_guest_mode(&svm->vcpu);
755755
copy_vmcb_control_area(&vmcb->control, &hsave->control);
756756
nested_svm_uninit_mmu_context(&svm->vcpu);
757+
vmcb_mark_all_dirty(svm->vmcb);
757758
}
758759

759760
kvm_clear_request(KVM_REQ_GET_NESTED_STATE_PAGES, &svm->vcpu);

0 commit comments

Comments
 (0)