diff options
| author | Marcelo Tosatti | 2013-06-19 01:38:25 +0200 |
|---|---|---|
| committer | Paolo Bonzini | 2013-07-03 10:41:32 +0200 |
| commit | 00f4d64ee76e873be881a82d893a591487aa7950 (patch) | |
| tree | 8175716bcd820616bc2fa278d98536de50aa2595 /linux-user/ioctls.h | |
| parent | pci-assign: remove the duplicate function name in debug message (diff) | |
| download | qemu-00f4d64ee76e873be881a82d893a591487aa7950.tar.gz qemu-00f4d64ee76e873be881a82d893a591487aa7950.tar.xz qemu-00f4d64ee76e873be881a82d893a591487aa7950.zip | |
kvmclock: clock should count only if vm is running
kvmclock should not count while vm is paused, because:
1) if the vm is paused for long periods, timekeeping
math can overflow while converting the (large) clocksource
delta to nanoseconds.
2) Users rely on CLOCK_MONOTONIC to count run time, that is,
time which OS has been in a runnable state (see CLOCK_BOOTTIME).
Change kvmclock driver so as to save clock value when vm transitions
from runnable to stopped state, and to restore clock value from stopped
to runnable transition.
Cc: qemu-stable@nongnu.org
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'linux-user/ioctls.h')
0 files changed, 0 insertions, 0 deletions
