summaryrefslogtreecommitdiffstats
path: root/include/hw/i386/pc.h
diff options
context:
space:
mode:
authorMarcelo Tosatti2016-11-21 11:50:04 +0100
committerPaolo Bonzini2016-12-22 16:00:56 +0100
commit6053a86fe7bd3d5b07b49dae6c05f2cd0d44e687 (patch)
tree2719d6b7ef95784f1499ec1ddc66f402129e1ba3 /include/hw/i386/pc.h
parentkvm: sync linux headers (diff)
downloadqemu-6053a86fe7bd3d5b07b49dae6c05f2cd0d44e687.tar.gz
qemu-6053a86fe7bd3d5b07b49dae6c05f2cd0d44e687.tar.xz
qemu-6053a86fe7bd3d5b07b49dae6c05f2cd0d44e687.zip
kvmclock: reduce kvmclock difference on migration
Check for KVM_CAP_ADJUST_CLOCK capability KVM_CLOCK_TSC_STABLE, which indicates that KVM_GET_CLOCK returns a value as seen by the guest at that moment. For new machine types, use this value rather than reading from guest memory. This reduces kvmclock difference on migration from 5s to 0.1s (when max_downtime == 5s). Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com> Message-Id: <20161121105052.598267440@redhat.com> [Add comment explaining what is going on. - Paolo] Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'include/hw/i386/pc.h')
-rw-r--r--include/hw/i386/pc.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/hw/i386/pc.h b/include/hw/i386/pc.h
index b37bc5b139..b22e699c46 100644
--- a/include/hw/i386/pc.h
+++ b/include/hw/i386/pc.h
@@ -379,6 +379,11 @@ bool e820_get_entry(int, uint32_t, uint64_t *, uint64_t *);
#define PC_COMPAT_2_7 \
HW_COMPAT_2_7 \
{\
+ .driver = "kvmclock",\
+ .property = "x-mach-use-reliable-get-clock",\
+ .value = "off",\
+ },\
+ {\
.driver = TYPE_X86_CPU,\
.property = "l3-cache",\
.value = "off",\