From c14750e8ad4a9d8d7621e2594abda34df19a6eff Mon Sep 17 00:00:00 2001 From: Jan Kiszka Date: Fri, 21 Jan 2011 21:48:10 +0100 Subject: kvm: x86: Prepare kvm_get_mp_state for in-kernel irqchip This code path will not yet be taken as we still lack in-kernel irqchip support. But qemu-kvm can already make use of it and drop its own mp_state access services. Signed-off-by: Jan Kiszka Signed-off-by: Marcelo Tosatti --- target-i386/kvm.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'target-i386/kvm.c') diff --git a/target-i386/kvm.c b/target-i386/kvm.c index 9bb34abc5b..531b69e68a 100644 --- a/target-i386/kvm.c +++ b/target-i386/kvm.c @@ -1198,6 +1198,9 @@ static int kvm_get_mp_state(CPUState *env) return ret; } env->mp_state = mp_state.mp_state; + if (kvm_irqchip_in_kernel()) { + env->halted = (mp_state.mp_state == KVM_MP_STATE_HALTED); + } return 0; } -- cgit v1.2.3