On 05/26/2011 09:55 AM, Gleb Natapov wrote:
> >
> >+ case SrcDX:
> >+ c->src.type = OP_REG;
> >+ c->src.bytes = c->op_bytes;
>
> Needs to be 2. Otherwise we'll see extra bits from edx, or lose
> bits from dx if it's a 1-byte instruction.
>
But those extra bits will be dropped by check_perm_in() anyway.
It isn't nice to depend on it.
btw, Marcelo, the patch should also make use of the decode during execution:
case 0xef: /* out dx,(e/r)ax */
c->dst.val = c->regs[VCPU_REGS_RDX];
^^ can drop
do_io_out:
ops->pio_out_emulated(ctxt, c->src.bytes, c->dst.val,
&c->src.val, 1);
c->dst.type = OP_NONE; /* Disable writeback. */
break;
Can
c->op_bytes ever be 1?
in %dx, %al
--
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html