diff options
author | jhb <jhb@FreeBSD.org> | 2001-08-13 22:44:55 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2001-08-13 22:44:55 +0000 |
commit | fed209ef9568f5bb61756ccbcf03fd06aee65354 (patch) | |
tree | eed67b084a7274f3907f383d694b9d139513d9da | |
parent | a81e520c43e39fcc9ffb30fcee9efd713a4b9682 (diff) | |
download | FreeBSD-src-fed209ef9568f5bb61756ccbcf03fd06aee65354.zip FreeBSD-src-fed209ef9568f5bb61756ccbcf03fd06aee65354.tar.gz |
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.
-rw-r--r-- | sys/alpha/alpha/prom.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/alpha/alpha/prom.c b/sys/alpha/alpha/prom.c index b532346..887f991 100644 --- a/sys/alpha/alpha/prom.c +++ b/sys/alpha/alpha/prom.c @@ -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; |