]> 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)
commit23fff13ba2a52542563b220d968abc56dde34daa
treefcc53a18d286b78631e7764d6d8b948e355a1566
parent9ecaf21a6522a090aaa4960d571b41332562e074
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