]> git.proxmox.com Git - mirror_ubuntu-bionic-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)
committerStefan Bader <stefan.bader@canonical.com>
Mon, 1 Oct 2018 12:57:27 +0000 (14:57 +0200)
commitf7f5542f20216dfab9d220582a74c56825d96c9a
tree4a01e877bd0fadd251f535fb1a7b21d8d15b03a7
parentc1b94ae2fdfa015bf7e15ebd6376047734ab56c0
X86/KVM: Properly update 'tsc_offset' to represent the running guest

BugLink: http://bugs.launchpad.net/bugs/1794889
[ Upstream commit e79f245ddec17bbd89d73cd0169dba4be46c9b55 ]

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>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
arch/x86/include/asm/kvm_host.h
arch/x86/kvm/svm.c
arch/x86/kvm/vmx.c
arch/x86/kvm/x86.c