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

[Xen-devel] [PATCH 1/9] x86/pvh: Don't test 64b-only vcpu_guest_context's fields



vcpu_guest_context's fs_base, gs_base_kernel and gs_base_user are not defined
for 32-bit guests.

Drop PVH 32bitfixme ASSERT.

Signed-off-by: Boris Ostrovsky <boris.ostrovsky@xxxxxxxxxx>
CC: Keir Fraser <keir@xxxxxxx>
CC: Jan Beulich <jbeulich@xxxxxxxx>
CC: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>

---
 xen/arch/x86/domain.c |    8 +++-----
 1 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/xen/arch/x86/domain.c b/xen/arch/x86/domain.c
index 0363650..e396c6c 100644
--- a/xen/arch/x86/domain.c
+++ b/xen/arch/x86/domain.c
@@ -769,16 +769,14 @@ int arch_set_info_guest(
     }
     else if ( is_pvh_domain(d) )
     {
-        /* PVH 32bitfixme */
-        ASSERT(!compat);
-
         if ( c(ctrlreg[0]) || c(ctrlreg[1]) || c(ctrlreg[2]) ||
              c(ctrlreg[4]) || c(ctrlreg[5]) || c(ctrlreg[6]) ||
              c(ctrlreg[7]) ||  c(ldt_base) || c(ldt_ents) ||
              c(user_regs.cs) || c(user_regs.ss) || c(user_regs.es) ||
              c(user_regs.ds) || c(user_regs.fs) || c(user_regs.gs) ||
-             c(kernel_ss) || c(kernel_sp) || c.nat->gs_base_kernel ||
-             c.nat->gdt_ents || c.nat->fs_base || c.nat->gs_base_user )
+             c(kernel_ss) || c(kernel_sp) || c(gdt_ents) ||
+             (!compat && (c.nat->gs_base_kernel ||
+              c.nat->fs_base || c.nat->gs_base_user)) )
             return -EINVAL;
     }
 
-- 
1.7.1


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

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