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-devel

[Xen-devel] [3.0.4 PATCH][RESEND] disable events fix

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [3.0.4 PATCH][RESEND] disable events fix
From: John Levon <levon@xxxxxxxxxxxxxxxxx>
Date: Thu, 1 Feb 2007 20:05:41 +0000
Delivery-date: Thu, 01 Feb 2007 12:03:14 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.9i
As this affects domU's I'd like to get this in 3.0.4-2 if possible.

thanks
john

# HG changeset patch
# User john.levon@xxxxxxx
# Date 1170358345 28800
# Node ID 46b2669ec422e54c52972b02534e50093784b3d7
# Parent  be18b8e43f73e46314b0d796a68d7949e9c8bc86
Save disable event flags in guest context

We weren't storing the *disables_events flags when grabbing the guest context,
causing 64-bit guests that use the flags to fail when restoring.

Signed-off-by: John Levon <john.levon@xxxxxxx>

diff --git a/xen/arch/x86/domctl.c b/xen/arch/x86/domctl.c
--- a/xen/arch/x86/domctl.c
+++ b/xen/arch/x86/domctl.c
@@ -305,11 +305,15 @@ void arch_getdomaininfo_ctxt(
         c->user_regs.eflags |= v->arch.iopl << 12;
     }
 
-    c->flags = 0;
     if ( test_bit(_VCPUF_fpu_initialised, &v->vcpu_flags) )
-        c->flags |= VGCF_i387_valid;
+        __set_bit(_VGCF_i387_valid, &c->flags);
+    else
+        __clear_bit(_VGCF_i387_valid, &c->flags);
+
     if ( guest_kernel_mode(v, &v->arch.guest_context.user_regs) )
-        c->flags |= VGCF_in_kernel;
+        __set_bit(_VGCF_in_kernel, &c->flags);
+    else
+        __clear_bit(_VGCF_in_kernel, &c->flags);
 
     c->ctrlreg[3] = xen_pfn_to_cr3(pagetable_get_pfn(v->arch.guest_table));
 

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [3.0.4 PATCH][RESEND] disable events fix, John Levon <=