Marcelo Tosatti 00f4d64ee7 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>
2013-07-03 10:41:32 +02:00
..
2013-06-25 19:15:46 +01:00
2013-05-01 13:06:07 +02:00
2013-06-20 16:39:52 +02:00
2013-04-19 11:36:33 +02:00
2013-06-07 14:55:33 +02:00
2013-06-07 12:14:45 +02:00
2013-06-07 14:55:33 +02:00
2013-04-20 17:54:52 +00:00
2013-05-01 20:55:21 +04:00
2013-04-08 18:13:10 +02:00
2013-06-02 18:13:37 +03:00
2013-06-02 18:13:37 +03:00
2013-06-20 16:39:52 +02:00
2013-06-21 22:52:50 +04:00
2013-06-02 18:14:02 +03:00
2013-06-07 14:55:25 +02:00
2013-06-07 14:55:33 +02:00
2013-06-24 08:41:07 +02:00