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

Commit 34698d8c authored by Mohammed Gamal's avatar Mohammed Gamal Committed by Avi Kivity
Browse files

KVM: x86 emulator: Fix nop emulation



If a nop instruction is encountered, we jump directly to the done label.
This skip updating rip. Break from the switch case instead

Signed-off-by: default avatarMohammed Gamal <m.gamal005@gmail.com>
Signed-off-by: default avatarAvi Kivity <avi@redhat.com>
parent 2dbd0dd7
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2912,7 +2912,7 @@ x86_emulate_insn(struct x86_emulate_ctxt *ctxt)
		break;
	case 0x90 ... 0x97: /* nop / xchg reg, rax */
		if (c->dst.addr.reg == &c->regs[VCPU_REGS_RAX])
			goto done;
			break;
		goto xchg;
	case 0x9c: /* pushf */
		c->src.val =  (unsigned long) ctxt->eflags;