Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 215732
b: refs/heads/master
c: a13a63f
h: refs/heads/master
v: v3
  • Loading branch information
Wei Yongjun authored and Avi Kivity committed Oct 24, 2010
1 parent c040ba0 commit f610db5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 21 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 41167be544603e077b866a2922737556dc2294e8
refs/heads/master: a13a63faa6237001ed80d4f4051fc028dace10d9
24 changes: 4 additions & 20 deletions trunk/arch/x86/kvm/emulate.c
Original file line number Diff line number Diff line change
Expand Up @@ -2923,28 +2923,12 @@ x86_emulate_insn(struct x86_emulate_ctxt *ctxt)
break;
case 0x6c: /* insb */
case 0x6d: /* insw/insd */
c->dst.bytes = min(c->dst.bytes, 4u);
if (!emulator_io_permited(ctxt, ops, c->regs[VCPU_REGS_RDX],
c->dst.bytes)) {
emulate_gp(ctxt, 0);
goto done;
}
if (!pio_in_emulated(ctxt, ops, c->dst.bytes,
c->regs[VCPU_REGS_RDX], &c->dst.val))
goto done; /* IO is needed, skip writeback */
break;
c->src.val = c->regs[VCPU_REGS_RDX];
goto do_io_in;
case 0x6e: /* outsb */
case 0x6f: /* outsw/outsd */
c->src.bytes = min(c->src.bytes, 4u);
if (!emulator_io_permited(ctxt, ops, c->regs[VCPU_REGS_RDX],
c->src.bytes)) {
emulate_gp(ctxt, 0);
goto done;
}
ops->pio_out_emulated(c->src.bytes, c->regs[VCPU_REGS_RDX],
&c->src.val, 1, ctxt->vcpu);

c->dst.type = OP_NONE; /* nothing to writeback */
c->dst.val = c->regs[VCPU_REGS_RDX];
goto do_io_out;
break;
case 0x70 ... 0x7f: /* jcc (short) */
if (test_cc(c->b, ctxt->eflags))
Expand Down

0 comments on commit f610db5

Please sign in to comment.