]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: SEV: Init target VMCBs in sev_migrate_from
authorPeter Gonda <pgonda@google.com>
Thu, 23 Jun 2022 17:34:06 +0000 (10:34 -0700)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 24 Jun 2022 08:10:18 +0000 (04:10 -0400)
commit9f60595fa4c0344df0a13205f599a013caf30726
treeee62722d600d3f8a2e94fefa741cb8bd0312edac
parent6d6a0b3c615536496dfb9bb3dcd214a95224df7b
KVM: SEV: Init target VMCBs in sev_migrate_from

The target VMCBs during an intra-host migration need to correctly setup
for running SEV and SEV-ES guests. Add sev_init_vmcb() function and make
sev_es_init_vmcb() static. sev_init_vmcb() uses the now private function
to init SEV-ES guests VMCBs when needed.

Fixes: 7d473e792ae7 ("KVM: SEV: Add support for SEV-ES intra host migration")
Fixes: 0f9a534d193e ("KVM: SEV: Add support for SEV intra host migration")
Signed-off-by: Peter Gonda <pgonda@google.com>
Cc: Marc Orr <marcorr@google.com>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Sean Christopherson <seanjc@google.com>
Cc: Tom Lendacky <thomas.lendacky@amd.com>
Cc: kvm@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Message-Id: <20220623173406.744645-1-pgonda@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/svm/sev.c
arch/x86/kvm/svm/svm.c
arch/x86/kvm/svm/svm.h