aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authoraurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162>2008-10-01 22:01:28 +0000
committeraurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162>2008-10-01 22:01:28 +0000
commit3003b8bbf9a044e3f5f1c95c0fb1c35ff09f8385 (patch)
tree6bb0b27bcba51ece4bbd6f5205787cc8ae1b0b24 /hw
parentede46085c272f0358c175b557bb18375ed2af061 (diff)
Reset CPU on INIT IPI
INIT IPI should reset CPU. Also non boot CPU should be halted. It will be un-halted by SIPI. Signed-off-by: Gleb Natapov <gleb@redhat.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5390 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'hw')
-rw-r--r--hw/apic.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/hw/apic.c b/hw/apic.c
index 74e3a71615..0f661b61fe 100644
--- a/hw/apic.c
+++ b/hw/apic.c
@@ -458,6 +458,11 @@ static void apic_init_ipi(APICState *s)
s->initial_count = 0;
s->initial_count_load_time = 0;
s->next_time = 0;
+
+ cpu_reset(s->cpu_env);
+
+ if (!(s->apicbase & MSR_IA32_APICBASE_BSP))
+ s->cpu_env->halted = 1;
}
/* send a SIPI message to the CPU to start it */