Commit deee59ba authored by Maxim Levitsky's avatar Maxim Levitsky Committed by Paolo Bonzini
Browse files

KVM: nSVM: fix a typo in svm_leave_nested



When forcibly leaving the nested mode, we should switch to vmcb01

Fixes: 4995a368 ("KVM: SVM: Use a separate vmcb for the nested L2 guest")

Signed-off-by: default avatarMaxim Levitsky <mlevitsk@redhat.com>
Message-Id: <20210503125446.1353307-2-mlevitsk@redhat.com>
Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
parent 262de410
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -886,7 +886,7 @@ void svm_leave_nested(struct vcpu_svm *svm)
		svm->nested.nested_run_pending = 0;
		leave_guest_mode(vcpu);

		svm_switch_vmcb(svm, &svm->nested.vmcb02);
		svm_switch_vmcb(svm, &svm->vmcb01);

		nested_svm_uninit_mmu_context(vcpu);
		vmcb_mark_all_dirty(svm->vmcb);