ia64/xen-unstable

changeset 17269:ba3356c82317

x86_emulate: Remove the CPL and IOPL check in the I/O handling code.

The check is already carried out by the processor during VMEXIT, where
that is required.

Signed-off-by: Xu Dongxiao <dongxiao.xu@intel.com>
author Keir Fraser <keir.fraser@citrix.com>
date Wed Mar 19 14:08:02 2008 +0000 (2008-03-19)
parents f45aa9a14db4
children c30b12577d75
files xen/arch/x86/x86_emulate.c
line diff
     1.1 --- a/xen/arch/x86/x86_emulate.c	Wed Mar 19 14:06:18 2008 +0000
     1.2 +++ b/xen/arch/x86/x86_emulate.c	Wed Mar 19 14:08:02 2008 +0000
     1.3 @@ -2265,7 +2265,6 @@ x86_emulate(
     1.4  
     1.5      case 0x6c ... 0x6d: /* ins %dx,%es:%edi */ {
     1.6          unsigned long nr_reps = get_rep_prefix();
     1.7 -        generate_exception_if(!mode_iopl(), EXC_GP, 0);
     1.8          dst.bytes = !(b & 1) ? 1 : (op_bytes == 8) ? 4 : op_bytes;
     1.9          dst.mem.seg = x86_seg_es;
    1.10          dst.mem.off = truncate_ea(_regs.edi);
    1.11 @@ -2295,7 +2294,6 @@ x86_emulate(
    1.12  
    1.13      case 0x6e ... 0x6f: /* outs %esi,%dx */ {
    1.14          unsigned long nr_reps = get_rep_prefix();
    1.15 -        generate_exception_if(!mode_iopl(), EXC_GP, 0);
    1.16          dst.bytes = !(b & 1) ? 1 : (op_bytes == 8) ? 4 : op_bytes;
    1.17          if ( (nr_reps > 1) && (ops->rep_outs != NULL) &&
    1.18               ((rc = ops->rep_outs(ea.mem.seg, truncate_ea(_regs.esi),
    1.19 @@ -2832,7 +2830,6 @@ x86_emulate(
    1.20          unsigned int port = ((b < 0xe8)
    1.21                               ? insn_fetch_type(uint8_t)
    1.22                               : (uint16_t)_regs.edx);
    1.23 -        generate_exception_if(!mode_iopl(), EXC_GP, 0);
    1.24          op_bytes = !(b & 1) ? 1 : (op_bytes == 8) ? 4 : op_bytes;
    1.25          if ( b & 2 )
    1.26          {