KVM: SVM: fix emulation of msr reads/writes of MSR_FS_BASE and MSR_GS_BASE
authorMaxim Levitsky <mlevitsk@redhat.com>
Fri, 2 Aug 2024 15:16:08 +0000 (18:16 +0300)
committerSean Christopherson <seanjc@google.com>
Thu, 22 Aug 2024 18:25:34 +0000 (11:25 -0700)
commitdad1613e0533b380318281c1519e1a3477c2d0d2
tree0fb423b92d4c0bd69e2005fa011c23a7bbc425f8
parent4bcdd831d9d01e0fb64faea50732b59b2ee88da1
KVM: SVM: fix emulation of msr reads/writes of MSR_FS_BASE and MSR_GS_BASE

If these msrs are read by the emulator (e.g due to 'force emulation' prefix),
SVM code currently fails to extract the corresponding segment bases,
and return them to the emulator.

Fix that.

Cc: stable@vger.kernel.org
Signed-off-by: Maxim Levitsky <mlevitsk@redhat.com>
Link: https://lore.kernel.org/r/20240802151608.72896-3-mlevitsk@redhat.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
arch/x86/kvm/svm/svm.c