In prom_halt(), set the halt restart flags on the current CPU, not the

boot CPU.  This was the reason reboots on SMP systems could result in
weird hangs.  Unlike the x86, we do not need to switch back to the boot
CPU in order to reboot the machine.  See Section 3.4.5 of Part III
(Console Interface Architecture) from the Alpha Architecture Reference
Manual (aka the Brown Book) for more info.
This commit is contained in:
John Baldwin 2001-08-13 22:44:55 +00:00
parent 6937ca29dc
commit 4f99f11257

View File

@ -278,8 +278,7 @@ prom_halt(halt)
* Set "boot request" part of the CPU state depending on what
* we want to happen when we halt.
*/
p = (struct pcs *)((char *)hwrpb + hwrpb->rpb_pcs_off +
(hwrpb->rpb_primary_cpu_id * hwrpb->rpb_pcs_size));
p = LOCATE_PCS(hwrpb, PCPU_GET(cpuid));
p->pcs_flags &= ~(PCS_RC | PCS_HALT_REQ);
if (halt)
p->pcs_flags |= PCS_HALT_STAY_HALTED;