KVM: x86 emulator: fix debug reg mov instructions

More fallout from the writeback fixes: debug register transfer
instructions do their own writeback and thus need to disable the general
writeback mechanism.

This fixes oopses and some guest failures on AMD machines (the Intel
variant decodes the instruction in hardware and thus does not need
emulation).

Cc: Alistair John Strachan <alistair@devzero.co.uk>
Signed-off-by: Avi Kivity <avi@qumranet.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by Avi Kivity and committed by Linus Torvalds bac27d35 9e865f58

+2
+2
drivers/kvm/x86_emulate.c
··· 1217 } 1218 break; 1219 case 0x21: /* mov from dr to reg */ 1220 if (modrm_mod != 3) 1221 goto cannot_emulate; 1222 rc = emulator_get_dr(ctxt, modrm_reg, &_regs[modrm_rm]); 1223 break; 1224 case 0x23: /* mov from reg to dr */ 1225 if (modrm_mod != 3) 1226 goto cannot_emulate; 1227 rc = emulator_set_dr(ctxt, modrm_reg, _regs[modrm_rm]);
··· 1217 } 1218 break; 1219 case 0x21: /* mov from dr to reg */ 1220 + no_wb = 1; 1221 if (modrm_mod != 3) 1222 goto cannot_emulate; 1223 rc = emulator_get_dr(ctxt, modrm_reg, &_regs[modrm_rm]); 1224 break; 1225 case 0x23: /* mov from reg to dr */ 1226 + no_wb = 1; 1227 if (modrm_mod != 3) 1228 goto cannot_emulate; 1229 rc = emulator_set_dr(ctxt, modrm_reg, _regs[modrm_rm]);