* [PATCH RESEND] KVM: x86 emulator: fix debug reg mov instructions
@ 2007-08-05 7:16 Avi Kivity
0 siblings, 0 replies; only message in thread
From: Avi Kivity @ 2007-08-05 7:16 UTC (permalink / raw)
To: Linus Torvalds
Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f,
Alistair John Strachan, linux-kernel-u79uwXL29TY76Z2rM5mHXA
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-T7eSMZptz7IqdlJmJB21zg@public.gmane.org>
Signed-off-by: Avi Kivity <avi-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
diff --git a/drivers/kvm/x86_emulate.c b/drivers/kvm/x86_emulate.c
index 1f979cb..4b8a0cc 100644
--- a/drivers/kvm/x86_emulate.c
+++ b/drivers/kvm/x86_emulate.c
@@ -1217,11 +1217,13 @@ twobyte_insn:
}
break;
case 0x21: /* mov from dr to reg */
+ no_wb = 1;
if (modrm_mod != 3)
goto cannot_emulate;
rc = emulator_get_dr(ctxt, modrm_reg, &_regs[modrm_rm]);
break;
case 0x23: /* mov from reg to dr */
+ no_wb = 1;
if (modrm_mod != 3)
goto cannot_emulate;
rc = emulator_set_dr(ctxt, modrm_reg, _regs[modrm_rm]);
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2007-08-05 7:16 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-05 7:16 [PATCH RESEND] KVM: x86 emulator: fix debug reg mov instructions Avi Kivity
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox