]> xenbits.xensource.com Git - xen.git/commitdiff
x86_emulate: Remove the CPL and IOPL check in the I/O handling code.
authorKeir Fraser <keir.fraser@citrix.com>
Wed, 19 Mar 2008 14:08:02 +0000 (14:08 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Wed, 19 Mar 2008 14:08:02 +0000 (14:08 +0000)
The check is already carried out by the processor during VMEXIT, where
that is required.

Signed-off-by: Xu Dongxiao <dongxiao.xu@intel.com>
xen/arch/x86/x86_emulate.c

index 6981f9b52dfa79cdab3b1536a2ffc5af6e74051b..a3e71c2780995cabe0ab6614e2ac93c556ff57fc 100644 (file)
@@ -2265,7 +2265,6 @@ x86_emulate(
 
     case 0x6c ... 0x6d: /* ins %dx,%es:%edi */ {
         unsigned long nr_reps = get_rep_prefix();
-        generate_exception_if(!mode_iopl(), EXC_GP, 0);
         dst.bytes = !(b & 1) ? 1 : (op_bytes == 8) ? 4 : op_bytes;
         dst.mem.seg = x86_seg_es;
         dst.mem.off = truncate_ea(_regs.edi);
@@ -2295,7 +2294,6 @@ x86_emulate(
 
     case 0x6e ... 0x6f: /* outs %esi,%dx */ {
         unsigned long nr_reps = get_rep_prefix();
-        generate_exception_if(!mode_iopl(), EXC_GP, 0);
         dst.bytes = !(b & 1) ? 1 : (op_bytes == 8) ? 4 : op_bytes;
         if ( (nr_reps > 1) && (ops->rep_outs != NULL) &&
              ((rc = ops->rep_outs(ea.mem.seg, truncate_ea(_regs.esi),
@@ -2832,7 +2830,6 @@ x86_emulate(
         unsigned int port = ((b < 0xe8)
                              ? insn_fetch_type(uint8_t)
                              : (uint16_t)_regs.edx);
-        generate_exception_if(!mode_iopl(), EXC_GP, 0);
         op_bytes = !(b & 1) ? 1 : (op_bytes == 8) ? 4 : op_bytes;
         if ( b & 2 )
         {