diff options
author | Keir Fraser <keir.fraser@citrix.com> | 2007-11-25 11:45:02 +0000 |
---|---|---|
committer | Keir Fraser <keir.fraser@citrix.com> | 2007-11-25 11:45:02 +0000 |
commit | 3c7c7376b6fd4f871e0aa26ce282e0ee3a9f7e30 (patch) | |
tree | 5a958aa1abd647138410508661e6a5bccc74f4d1 /xen/arch/x86/x86_emulate.c | |
parent | a2b5673b0018f0184b4833f65a453538cf84f6f5 (diff) | |
download | xen-3c7c7376b6fd4f871e0aa26ce282e0ee3a9f7e30.tar.gz xen-3c7c7376b6fd4f871e0aa26ce282e0ee3a9f7e30.tar.bz2 xen-3c7c7376b6fd4f871e0aa26ce282e0ee3a9f7e30.zip |
vmx realmode: Support privileged EFLAGS updates in emulated realmode.
Also tweak debug tracing to be much less noisy. We can emulates tens
of thousands of instructions in rombios now.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Diffstat (limited to 'xen/arch/x86/x86_emulate.c')
-rw-r--r-- | xen/arch/x86/x86_emulate.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/xen/arch/x86/x86_emulate.c b/xen/arch/x86/x86_emulate.c index 3ff12f8112..e0db845cb6 100644 --- a/xen/arch/x86/x86_emulate.c +++ b/xen/arch/x86/x86_emulate.c @@ -2253,16 +2253,13 @@ x86_emulate( break; case 0xfa: /* cli */ - generate_exception_if(!mode_iopl(), EXC_GP); - fail_if(ops->write_rflags == NULL); - if ( (rc = ops->write_rflags(_regs.eflags & ~EFLG_IF, ctxt)) != 0 ) - goto done; - break; - case 0xfb: /* sti */ generate_exception_if(!mode_iopl(), EXC_GP); fail_if(ops->write_rflags == NULL); - if ( (rc = ops->write_rflags(_regs.eflags | EFLG_IF, ctxt)) != 0 ) + _regs.eflags &= ~EFLG_IF; + if ( b == 0xfb ) /* sti */ + _regs.eflags |= EFLG_IF; + if ( (rc = ops->write_rflags(_regs.eflags, ctxt)) != 0 ) goto done; break; |