]> git.baikalelectronics.ru Git - kernel.git/commit
X86/KVM: Properly update 'tsc_offset' to represent the running guest
authorKarimAllah Ahmed <karahmed@amazon.de>
Sat, 14 Apr 2018 03:10:52 +0000 (05:10 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Mon, 16 Apr 2018 15:50:11 +0000 (17:50 +0200)
commit8830755ec219c0f0717d201b1fe8400eefb7e1c3
tree0cf1274bfc8df0b80aeb1908a052e707fe9082c0
parent1472e541a58370a8d58180ee9248185d4f0d361d
X86/KVM: Properly update 'tsc_offset' to represent the running guest

Update 'tsc_offset' on vmentry/vmexit of L2 guests to ensure that it always
captures the TSC_OFFSET of the running guest whether it is the L1 or L2
guest.

Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Radim Krčmář <rkrcmar@redhat.com>
Cc: kvm@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Reviewed-by: Jim Mattson <jmattson@google.com>
Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: KarimAllah Ahmed <karahmed@amazon.de>
[AMD changes, fix update_ia32_tsc_adjust_msr. - Paolo]
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/include/asm/kvm_host.h
arch/x86/kvm/svm.c
arch/x86/kvm/vmx.c
arch/x86/kvm/x86.c