]> git.baikalelectronics.ru Git - kernel.git/commit
kvm: x86: request masterclock update any time guest uses different msr
authorOliver Upton <oupton@google.com>
Tue, 27 Oct 2020 23:10:43 +0000 (16:10 -0700)
committerPaolo Bonzini <pbonzini@redhat.com>
Sun, 8 Nov 2020 09:41:30 +0000 (04:41 -0500)
commit5ce647f61ef6e3ca61c50b1986ad807cb4dfd95c
tree196efc2317a5c15c0007fc84ce84c2a96041acc7
parent7fe28a993c2aebb210af6080ce3537c60994a553
kvm: x86: request masterclock update any time guest uses different msr

Commit 973298976c13 ("kvm: x86: encapsulate wrmsr(MSR_KVM_SYSTEM_TIME)
emulation in helper fn", 2020-10-21) subtly changed the behavior of guest
writes to MSR_KVM_SYSTEM_TIME(_NEW). Restore the previous behavior; update
the masterclock any time the guest uses a different msr than before.

Fixes: 973298976c13 ("kvm: x86: encapsulate wrmsr(MSR_KVM_SYSTEM_TIME) emulation in helper fn", 2020-10-21)
Signed-off-by: Oliver Upton <oupton@google.com>
Reviewed-by: Peter Shier <pshier@google.com>
Message-Id: <20201027231044.655110-6-oupton@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/x86.c