|
|
|
|
|
|
|
|
|
|
xen-changelog
[Xen-changelog] [xen-unstable] [XEN] Fix EA calculation for POP <rm> whe
# HG changeset patch
# User kfraser@xxxxxxxxxxxxxxxxxxxxx
# Date 1168008298 0
# Node ID 16b0e0f250f49bd383f9cbe4a21155f8df1091cf
# Parent 58efd34d08375a13a33cf07f78af3cb8f094c322
[XEN] Fix EA calculation for POP <rm> when stack pointer is used as
base of the EA calculation. It should be used *post* increment.
Original patch from Jan Beulich <jbeulich@xxxxxxxxxx>
Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>
---
xen/arch/x86/x86_emulate.c | 5 +++++
1 files changed, 5 insertions(+)
diff -r 58efd34d0837 -r 16b0e0f250f4 xen/arch/x86/x86_emulate.c
--- a/xen/arch/x86/x86_emulate.c Fri Jan 05 12:33:23 2007 +0000
+++ b/xen/arch/x86/x86_emulate.c Fri Jan 05 14:44:58 2007 +0000
@@ -616,6 +616,11 @@ x86_emulate(
ea.mem.off <<= (sib >> 6) & 3;
if ( (modrm_mod == 0) && ((sib_base & 7) == 5) )
ea.mem.off += insn_fetch_type(int32_t);
+ else if ( (sib_base == 4) && !twobyte && (b == 0x8f) )
+ /* POP <rm> must have its EA calculated post increment. */
+ ea.mem.off += _regs.esp +
+ (((mode == X86EMUL_MODE_PROT64) && (op_bytes == 4))
+ ? 8 : op_bytes);
else
ea.mem.off += *(long*)decode_register(sib_base, &_regs, 0);
}
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-changelog] [xen-unstable] [XEN] Fix EA calculation for POP <rm> when stack pointer is used as,
Xen patchbot-unstable <=
|
|
|
|
|