Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3ccb8827 authored by Aurelien Jarno's avatar Aurelien Jarno Committed by Avi Kivity
Browse files

KVM: Remove dead code in the cmpxchg instruction emulation



The writeback fixes (02c03a32) let
some dead code in the cmpxchg instruction emulation. Remove it.

Signed-off-by: default avatarAurelien Jarno <aurelien@aurel32.net>
Signed-off-by: default avatarAvi Kivity <avi@qumranet.com>
parent 62b3ffb8
Loading
Loading
Loading
Loading
+0 −2
Original line number Original line Diff line number Diff line
@@ -1278,8 +1278,6 @@ x86_emulate_memop(struct x86_emulate_ctxt *ctxt, struct x86_emulate_ops *ops)
		src.orig_val = src.val;
		src.orig_val = src.val;
		src.val = _regs[VCPU_REGS_RAX];
		src.val = _regs[VCPU_REGS_RAX];
		emulate_2op_SrcV("cmp", src, dst, _eflags);
		emulate_2op_SrcV("cmp", src, dst, _eflags);
		/* Always write back. The question is: where to? */
		d |= Mov;
		if (_eflags & EFLG_ZF) {
		if (_eflags & EFLG_ZF) {
			/* Success: write back to memory. */
			/* Success: write back to memory. */
			dst.val = src.orig_val;
			dst.val = src.orig_val;