WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-3.1-testing] hvm: Initialize vlapic->timer_last_upd

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-3.1-testing] hvm: Initialize vlapic->timer_last_update.
From: "Xen patchbot-3.1-testing" <patchbot-3.1-testing@xxxxxxxxxxxxxxxxxxx>
Date: Mon, 10 Dec 2007 03:10:48 -0800
Delivery-date: Mon, 10 Dec 2007 03:29:37 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1196962487 0
# Node ID 42ce3cbd17ccc4fc0e81ea58af737c73ad1c008b
# Parent  3b423ab38b7ae6e27fdf3407ecf903b07f863575
hvm: Initialize vlapic->timer_last_update.

Without the fix, before the first vlapic timer interrupt is injected,
the "vlapic->timer_last_update" in vlapic_get_tmcct()  is always 0,
causing a wrong value of counter_passed.

Signed-off-by: Dexuan Cui <dexuan.cui@xxxxxxxxx>
xen-unstable changeset:   16536:89e7031e153c62b9ce223a58a7ba49df285784a7
xen-unstable date:        Wed Dec 05 14:01:39 2007 +0000
---
 xen/arch/x86/hvm/vlapic.c |    2 ++
 1 files changed, 2 insertions(+)

diff -r 3b423ab38b7a -r 42ce3cbd17cc xen/arch/x86/hvm/vlapic.c
--- a/xen/arch/x86/hvm/vlapic.c Thu Dec 06 17:31:45 2007 +0000
+++ b/xen/arch/x86/hvm/vlapic.c Thu Dec 06 17:34:47 2007 +0000
@@ -660,6 +660,7 @@ static void vlapic_write(struct vcpu *v,
         vlapic_set_reg(vlapic, APIC_TMICT, val);
         create_periodic_time(current, &vlapic->pt, period, vlapic->pt.irq,
                              !vlapic_lvtt_period(vlapic), NULL, vlapic);
+        vlapic->timer_last_update = vlapic->pt.last_plt_gtime;
 
         HVM_DBG_LOG(DBG_LEVEL_VLAPIC,
                     "bus cycle is %uns, "
@@ -821,6 +822,7 @@ static void lapic_rearm(struct vlapic *s
         s->pt.irq = lvtt & APIC_VECTOR_MASK;
         create_periodic_time(vlapic_vcpu(s), &s->pt, period, s->pt.irq,
                              !vlapic_lvtt_period(s), NULL, s);
+        s->timer_last_update = s->pt.last_plt_gtime;
 
         printk("lapic_load to rearm the actimer:"
                "bus cycle is %uns, "

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-3.1-testing] hvm: Initialize vlapic->timer_last_update., Xen patchbot-3.1-testing <=