]> git.baikalelectronics.ru Git - kernel.git/commit
kvm: kvmclock: let KVM_GET_CLOCK return whether the master clock is in use
authorPaolo Bonzini <pbonzini@redhat.com>
Wed, 9 Nov 2016 16:48:15 +0000 (17:48 +0100)
committerRadim Krčmář <rkrcmar@redhat.com>
Sat, 19 Nov 2016 18:04:16 +0000 (19:04 +0100)
commit2b13e4fc8161ceb7228001e812e02632df79972f
treefcc53a18d286b78631e7764d6d8b948e355a1566
parent1b20152c4cca388be2f265012cca88a1164715e9
kvm: kvmclock: let KVM_GET_CLOCK return whether the master clock is in use

Userspace can read the exact value of kvmclock by reading the TSC
and fetching the timekeeping parameters out of guest memory.  This
however is brittle and not necessary anymore with KVM 4.11.  Provide
a mechanism that lets userspace know if the new KVM_GET_CLOCK
semantics are in effect, and---since we are at it---if the clock
is stable across all VCPUs.

Cc: Radim Krčmář <rkrcmar@redhat.com>
Cc: Marcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
Documentation/virtual/kvm/api.txt
arch/x86/kvm/x86.c
include/uapi/linux/kvm.h