diff options
author | kaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk> | 2005-08-11 21:19:45 +0000 |
---|---|---|
committer | kaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk> | 2005-08-11 21:19:45 +0000 |
commit | 1873dc6b45122bd55441c956c5b06ab5dabe5e54 (patch) | |
tree | 697995b2fadd16154a8660ac3122f3852eeb005e | |
parent | 8e221d71dc696d4dc14fa9bac7bb0b3093a931bf (diff) | |
download | xen-1873dc6b45122bd55441c956c5b06ab5dabe5e54.tar.gz xen-1873dc6b45122bd55441c956c5b06ab5dabe5e54.tar.bz2 xen-1873dc6b45122bd55441c956c5b06ab5dabe5e54.zip |
Fix getdomaininfo for vmx guests.
Replaces Intel patch [14/15].
Signed-off-by: Keir Fraser <keir@xensource.com>
-rw-r--r-- | xen/arch/x86/dom0_ops.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/xen/arch/x86/dom0_ops.c b/xen/arch/x86/dom0_ops.c index b933cbdfaa..01ea09b74e 100644 --- a/xen/arch/x86/dom0_ops.c +++ b/xen/arch/x86/dom0_ops.c @@ -404,16 +404,18 @@ void arch_getdomaininfo_ctxt( memcpy(c, &v->arch.guest_context, sizeof(*c)); - /* IOPL privileges are virtualised -- merge back into returned eflags. */ - BUG_ON((c->user_regs.eflags & EF_IOPL) != 0); - c->user_regs.eflags |= v->arch.iopl << 12; - if ( VMX_DOMAIN(v) ) { save_vmx_cpu_user_regs(&c->user_regs); __vmread(CR0_READ_SHADOW, &c->ctrlreg[0]); __vmread(CR4_READ_SHADOW, &c->ctrlreg[4]); } + else + { + /* IOPL privileges are virtualised: merge back into returned eflags. */ + BUG_ON((c->user_regs.eflags & EF_IOPL) != 0); + c->user_regs.eflags |= v->arch.iopl << 12; + } c->flags = 0; if ( test_bit(_VCPUF_fpu_initialised, &v->vcpu_flags) ) |