Commit 3003b8bbf9a044e3f5f1c95c0fb1c35ff09f8385

Authored by aurel32
1 parent ede46085

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
Showing 1 changed file with 5 additions and 0 deletions
hw/apic.c
... ... @@ -458,6 +458,11 @@ static void apic_init_ipi(APICState *s)
458 458 s->initial_count = 0;
459 459 s->initial_count_load_time = 0;
460 460 s->next_time = 0;
  461 +
  462 + cpu_reset(s->cpu_env);
  463 +
  464 + if (!(s->apicbase & MSR_IA32_APICBASE_BSP))
  465 + s->cpu_env->halted = 1;
461 466 }
462 467  
463 468 /* send a SIPI message to the CPU to start it */
... ...