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

[Xen-changelog] [xen-4.0-testing] xen: use s_time_t for periodic timer deadlines.



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1278579783 -3600
# Node ID 1afe3a562711e12ea36c45f3d4b8699e65aaf17b
# Parent  ebdbe57b76fe501d30e75b699929cf2d44bd73aa
xen: use s_time_t for periodic timer deadlines.

Otherwise vcpu_periodic_timer_work() can think the next timer is in
the future (and re-issue it unchanged) while timer_softirq_action()
thinks it's in the past (and fires it immediately), leading to
livelock.

Signed-off-by: Tim Deegan <Tim.Deegan@xxxxxxxxxx>
xen-unstable changeset:   21749:db35740574a5
xen-unstable date:        Thu Jul 08 09:52:34 2010 +0100
---
 xen/common/schedule.c   |    2 +-
 xen/include/xen/sched.h |    4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff -r ebdbe57b76fe -r 1afe3a562711 xen/common/schedule.c
--- a/xen/common/schedule.c     Thu Jul 08 10:02:33 2010 +0100
+++ b/xen/common/schedule.c     Thu Jul 08 10:03:03 2010 +0100
@@ -828,7 +828,7 @@ static void vcpu_periodic_timer_work(str
 static void vcpu_periodic_timer_work(struct vcpu *v)
 {
     s_time_t now = NOW();
-    uint64_t periodic_next_event;
+    s_time_t periodic_next_event;
 
     ASSERT(!active_timer(&v->periodic_timer));
 
diff -r ebdbe57b76fe -r 1afe3a562711 xen/include/xen/sched.h
--- a/xen/include/xen/sched.h   Thu Jul 08 10:02:33 2010 +0100
+++ b/xen/include/xen/sched.h   Thu Jul 08 10:03:03 2010 +0100
@@ -83,8 +83,8 @@ struct vcpu
 
     struct vcpu     *next_in_list;
 
-    uint64_t         periodic_period;
-    uint64_t         periodic_last_event;
+    s_time_t         periodic_period;
+    s_time_t         periodic_last_event;
     struct timer     periodic_timer;
     struct timer     singleshot_timer;
 

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.