]> www.infradead.org Git - users/jedix/linux-maple.git/commit
KVM: TDX: vcpu_run: save/restore host state(host kernel gs)
authorIsaku Yamahata <isaku.yamahata@intel.com>
Wed, 29 Jan 2025 09:58:55 +0000 (11:58 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 14 Mar 2025 18:20:54 +0000 (14:20 -0400)
commit81bf40d54cd56e33b4cd381cc719efaa53832468
treef7b17c6efd1e57ba6d23178785e1f29dc9d4c083
parent81bf912b2c15201ac96ee07042f804d02c0f69ee
KVM: TDX: vcpu_run: save/restore host state(host kernel gs)

On entering/exiting TDX vcpu, preserved or clobbered CPU state is different
from the VMX case. Add TDX hooks to save/restore host/guest CPU state.
Save/restore kernel GS base MSR.

Signed-off-by: Isaku Yamahata <isaku.yamahata@intel.com>
Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Message-ID: <20250129095902.16391-7-adrian.hunter@intel.com>
Reviewed-by: Xiayao Li <xiaoyao.li@intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/vmx/main.c
arch/x86/kvm/vmx/tdx.c
arch/x86/kvm/vmx/x86_ops.h