KVM: x86: MOV CR/DR emulation should ignore mod
authorNadav Amit <namit@cs.technion.ac.il>
Sun, 25 May 2014 20:05:21 +0000 (23:05 +0300)
committerPaolo Bonzini <pbonzini@redhat.com>
Tue, 27 May 2014 08:22:56 +0000 (10:22 +0200)
commit9b88ae99d2fe11e359b3b3992aff953e28b0b43a
tree11e43ca7db20ad0583755642b384939101938914
parentfc57ac2c9ca8109ea97fcc594f4be436944230cc
KVM: x86: MOV CR/DR emulation should ignore mod

MOV CR/DR instructions ignore the mod field (in the ModR/M byte). As the SDM
states: "The 2 bits in the mod field are ignored".  Accordingly, the second
operand of these instructions is always a general purpose register.

The current emulator implementation does not do so. If the mod bits do not
equal 3, it expects the second operand to be in memory.

Signed-off-by: Nadav Amit <namit@cs.technion.ac.il>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/emulate.c
This page took 0.027691 seconds and 5 git commands to generate.