diff options
author | Keir Fraser <keir.fraser@citrix.com> | 2007-12-04 11:23:05 +0000 |
---|---|---|
committer | Keir Fraser <keir.fraser@citrix.com> | 2007-12-04 11:23:05 +0000 |
commit | 5bef17da44e8e95e7037034b1f9bddb211a6f764 (patch) | |
tree | d8cd30d6df6657b5430a63849337ca48ecfb13e4 /xen/arch/x86/x86_emulate.c | |
parent | f2399a92310395a6c91dc5361bf3cea4c7a1d7dc (diff) | |
download | xen-5bef17da44e8e95e7037034b1f9bddb211a6f764.tar.gz xen-5bef17da44e8e95e7037034b1f9bddb211a6f764.tar.bz2 xen-5bef17da44e8e95e7037034b1f9bddb211a6f764.zip |
x86_emulate: Fix SHLD/SHRD emulation -- cannot rely on dst.orig_val
being already initialised.
From: Dexuan Cui <dexuan.cui@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Diffstat (limited to 'xen/arch/x86/x86_emulate.c')
-rw-r--r-- | xen/arch/x86/x86_emulate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/xen/arch/x86/x86_emulate.c b/xen/arch/x86/x86_emulate.c index f6b2215cfd..20f6cec5b5 100644 --- a/xen/arch/x86/x86_emulate.c +++ b/xen/arch/x86/x86_emulate.c @@ -2624,7 +2624,7 @@ x86_emulate( shift = (b & 1) ? (uint8_t)_regs.ecx : insn_fetch_type(uint8_t); if ( (shift &= width - 1) == 0 ) break; - dst.orig_val = truncate_word(dst.orig_val, dst.bytes); + dst.orig_val = truncate_word(dst.val, dst.bytes); dst.val = ((shift == width) ? src.val : (b & 8) ? /* shrd */ |