]> www.infradead.org Git - users/dwmw2/linux.git/commitdiff
KVM: Remove dead code in the cmpxchg instruction emulation
authorAurelien Jarno <aurelien@aurel32.net>
Wed, 25 Jul 2007 09:41:57 +0000 (11:41 +0200)
committerAvi Kivity <avi@qumranet.com>
Wed, 25 Jul 2007 09:54:07 +0000 (12:54 +0300)
The writeback fixes (02c03a326a5df825cc01de426f72e160db2b9538) let
some dead code in the cmpxchg instruction emulation. Remove it.

Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Avi Kivity <avi@qumranet.com>
drivers/kvm/x86_emulate.c

index cbbb9c5cfc86fe3e84ea78d8bffff62861b2eb15..1a90ba0adb575d5bbc8d46cda3ea425c3c3097b5 100644 (file)
@@ -1276,8 +1276,6 @@ twobyte_insn:
                src.orig_val = src.val;
                src.val = _regs[VCPU_REGS_RAX];
                emulate_2op_SrcV("cmp", src, dst, _eflags);
-               /* Always write back. The question is: where to? */
-               d |= Mov;
                if (_eflags & EFLG_ZF) {
                        /* Success: write back to memory. */
                        dst.val = src.orig_val;