qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH 0/2] qemu-timer/mc146818rtc: fix timer issues relate


From: Paul Donohue
Subject: [Qemu-devel] [PATCH 0/2] qemu-timer/mc146818rtc: fix timer issues related to clock changes
Date: Fri, 12 Jun 2015 10:05:41 -0400

If the host clock jumps forward or backward without resetting the mc146818rtc's 
periodic timer, the periodic timer interrupts will either fire rapidly 
(consuming host CPU and blocking operation of the VM) until the timer catches 
up to the new host clock, or will stall until the host clock catches up with 
the prior date used by the periodic timer.

A "reset notifier" mechanism was introduced a while back that resets the 
mc146818rtc's periodic timer if the host clock jumps backward while the VM is 
running.  However, the timer is not reset if the host clock jumps forward while 
the VM is running, or if the clock jumps either forward or backward when 
loading a snapshot or migration.

In one test case, when loading a 3 week old snapshot, the timer loop consumed 
CPU and blocked the VM for nearly 90 seconds.

The following patches fix this issue by resetting the timer in these cases.

Paul Donohue (2):
  qemu-timer: Call clock reset notifiers on large forward jumps
  mc146818rtc: Reset the periodic timer on resume from snapshot

 hw/timer/mc146818rtc.c | 6 ++++++
 include/qemu/timer.h   | 9 +++++++++
 qemu-timer.c           | 2 +-
 3 files changed, 16 insertions(+), 1 deletion(-)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]