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

[Xen-changelog] [xen-unstable] xen/arm: implement vcpu_timer_destroy


  • To: xen-changelog@xxxxxxxxxxxxxxxxxxx
  • From: Xen patchbot-unstable <patchbot@xxxxxxx>
  • Date: Wed, 06 Feb 2013 10:00:13 +0000
  • Delivery-date: Wed, 06 Feb 2013 10:00:21 +0000
  • List-id: "Change log for Mercurial \(receive only\)" <xen-changelog.lists.xen.org>

# HG changeset patch
# User Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
# Date 1360063869 0
# Node ID cc814b75e06f4d8f3ddc3ef88cc8c1e160a01ab0
# Parent  9a272a8ac323ff95c3b239a43d20cb437408ec0f
xen/arm: implement vcpu_timer_destroy

Implement a function to destroy the per-vcpu phys and virt timers, call
it from vcpu_destroy.

Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
Acked-by: Tim Deegan <tim@xxxxxxx>
Committed-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
---


diff -r 9a272a8ac323 -r cc814b75e06f xen/arch/arm/domain.c
--- a/xen/arch/arm/domain.c     Tue Feb 05 11:31:08 2013 +0000
+++ b/xen/arch/arm/domain.c     Tue Feb 05 11:31:09 2013 +0000
@@ -399,6 +399,7 @@ int vcpu_initialise(struct vcpu *v)
 
 void vcpu_destroy(struct vcpu *v)
 {
+    vcpu_timer_destroy(v);
     free_xenheap_pages(v->arch.stack, STACK_ORDER);
 }
 
diff -r 9a272a8ac323 -r cc814b75e06f xen/arch/arm/vtimer.c
--- a/xen/arch/arm/vtimer.c     Tue Feb 05 11:31:08 2013 +0000
+++ b/xen/arch/arm/vtimer.c     Tue Feb 05 11:31:09 2013 +0000
@@ -65,6 +65,12 @@ int vcpu_vtimer_init(struct vcpu *v)
     return 0;
 }
 
+void vcpu_timer_destroy(struct vcpu *v)
+{
+    kill_timer(&v->arch.virt_timer.timer);
+    kill_timer(&v->arch.phys_timer.timer);
+}
+
 int virt_timer_save(struct vcpu *v)
 {
     v->arch.virt_timer.ctl = READ_CP32(CNTV_CTL);
diff -r 9a272a8ac323 -r cc814b75e06f xen/arch/arm/vtimer.h
--- a/xen/arch/arm/vtimer.h     Tue Feb 05 11:31:08 2013 +0000
+++ b/xen/arch/arm/vtimer.h     Tue Feb 05 11:31:09 2013 +0000
@@ -24,6 +24,7 @@ extern int vcpu_vtimer_init(struct vcpu 
 extern int vtimer_emulate(struct cpu_user_regs *regs, union hsr hsr);
 extern int virt_timer_save(struct vcpu *v);
 extern int virt_timer_restore(struct vcpu *v);
+extern void vcpu_timer_destroy(struct vcpu *v);
 
 #endif
 

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
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®.