[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v2 16/16] x86emul: don't assume a memory operand
>>> On 29.09.16 at 23:12, <andrew.cooper3@xxxxxxxxxx> wrote: > On 28/09/16 09:19, Jan Beulich wrote: >> @@ -2216,7 +2217,7 @@ x86_decode( >> } >> } >> >> - if ( override_seg != -1 && ea.type == OP_MEM ) >> + if ( override_seg != x86_seg_none ) > > I don't see why the "ea.type == OP_MEM" should be dropped at this > point. We have already set ea.type appropriately for memory > instructions by this point, and it does open up the case where > instructions which would have triggered XSA-123 get incorrect > information reported if queried with x86_insn_operand_ea() The need to remove this actually became apparent with the testing I did for the priv-op handling, namely for OUTS with a segment override: When we had (before the patch here) ea.type start out as OP_MEM, the conditional above was true _unless_ ea.type got changed later on. With it now (properly imo) starting out as OP_NONE, instructions not changing it to OP_MEM (like all the string ones) would not get the segment override applied anymore. And no, x86_insn_operand_ea() returns x86_seg_none when ea.type is anything other than OP_MEM. Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |