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

[Xen-changelog] Check for existence of VLAPIC before relinquishing it,



# HG changeset patch
# User kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID fb1f2498ce1effcbf9bc0b101ae71331ea9cb38c
# Parent  37cafca1539e429495e0bd639aa874576e3bd8b6
Check for existence of VLAPIC before relinquishing it,
or a vmx guest can die very early.

Signed-off-by: Xin Li <xin.b.li@xxxxxxxxx>

diff -r 37cafca1539e -r fb1f2498ce1e xen/arch/x86/vmx.c
--- a/xen/arch/x86/vmx.c        Thu Dec 15 19:38:44 2005
+++ b/xen/arch/x86/vmx.c        Thu Dec 15 19:42:09 2005
@@ -110,12 +110,12 @@
     vpit = &v->domain->arch.vmx_platform.vmx_pit;
     if ( active_ac_timer(&(vpit->pit_timer)) )
         rem_ac_timer(&vpit->pit_timer);
-    if ( active_ac_timer(&v->arch.arch_vmx.hlt_timer) ) {
+    if ( active_ac_timer(&v->arch.arch_vmx.hlt_timer) )
         rem_ac_timer(&v->arch.arch_vmx.hlt_timer);
-    }
-    if ( vmx_apic_support(v->domain) ) {
-        rem_ac_timer( &(VLAPIC(v)->vlapic_timer) );
-        xfree( VLAPIC(v) );
+    if ( vmx_apic_support(v->domain) && (VLAPIC(v) != NULL) )
+    {
+        rem_ac_timer(&VLAPIC(v)->vlapic_timer);
+        xfree(VLAPIC(v));
     }
 }
 

_______________________________________________
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®.