aboutsummaryrefslogtreecommitdiff
path: root/kvm-all.c
diff options
context:
space:
mode:
authorJan Kiszka <jan.kiszka@siemens.com>2010-05-20 00:28:45 +0200
committerMarcelo Tosatti <mtosatti@redhat.com>2010-06-28 13:06:03 -0300
commitbe41cbe0368b5becac02a1bf885341ba25ba9a9e (patch)
tree1160efd7a9c322f74ce6b81e8009aa01dcda121f /kvm-all.c
parent4972d592113c627d4b6ea1be5c94a85b56099afd (diff)
downloadqemu-be41cbe0368b5becac02a1bf885341ba25ba9a9e.zip
qemu-be41cbe0368b5becac02a1bf885341ba25ba9a9e.tar.gz
qemu-be41cbe0368b5becac02a1bf885341ba25ba9a9e.tar.bz2
kvm: Switch kvm_update_guest_debug to run_on_cpu
Guest debugging under KVM is currently broken once io-threads are enabled. Easily fixable by switching the fake on_vcpu to the real run_on_cpu implementation. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'kvm-all.c')
-rw-r--r--kvm-all.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/kvm-all.c b/kvm-all.c
index c238f54..5684e51 100644
--- a/kvm-all.c
+++ b/kvm-all.c
@@ -1033,16 +1033,6 @@ void kvm_setup_guest_memory(void *start, size_t size)
}
#ifdef KVM_CAP_SET_GUEST_DEBUG
-static void on_vcpu(CPUState *env, void (*func)(void *data), void *data)
-{
-#ifdef CONFIG_IOTHREAD
- if (env != cpu_single_env) {
- abort();
- }
-#endif
- func(data);
-}
-
struct kvm_sw_breakpoint *kvm_find_sw_breakpoint(CPUState *env,
target_ulong pc)
{
@@ -1086,7 +1076,7 @@ int kvm_update_guest_debug(CPUState *env, unsigned long reinject_trap)
kvm_arch_update_guest_debug(env, &data.dbg);
data.env = env;
- on_vcpu(env, kvm_invoke_set_guest_debug, &data);
+ run_on_cpu(env, kvm_invoke_set_guest_debug, &data);
return data.err;
}