summaryrefslogtreecommitdiffstats
path: root/sys/sparc64
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2003-12-03 14:57:26 +0000
committerjhb <jhb@FreeBSD.org>2003-12-03 14:57:26 +0000
commit4b61439e79ae8fc81441be32c6579c2ccd4cf476 (patch)
treef8ffe15c95979d5e31c1ed4fa7544bebc5db3414 /sys/sparc64
parent907202ec1f57f255a3cb7245df54cf0e74dc5e43 (diff)
downloadFreeBSD-src-4b61439e79ae8fc81441be32c6579c2ccd4cf476.zip
FreeBSD-src-4b61439e79ae8fc81441be32c6579c2ccd4cf476.tar.gz
Fix all users of mp_maxid to use the same semantics, namely:
1) mp_maxid is a valid FreeBSD CPU ID in the range 0 .. MAXCPU - 1. 2) For all active CPUs in the system, PCPU_GET(cpuid) <= mp_maxid. Approved by: re (scottl) Tested on: i386, amd64, alpha
Diffstat (limited to 'sys/sparc64')
-rw-r--r--sys/sparc64/sparc64/mp_machdep.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/sparc64/sparc64/mp_machdep.c b/sys/sparc64/sparc64/mp_machdep.c
index c26f6f7..8625b43 100644
--- a/sys/sparc64/sparc64/mp_machdep.c
+++ b/sys/sparc64/sparc64/mp_machdep.c
@@ -159,14 +159,14 @@ cpu_mp_setmaxid(void)
strcmp(buf, "cpu") == 0)
cpus++;
}
- mp_maxid = cpus;
+ mp_maxid = cpus - 1;
}
int
cpu_mp_probe(void)
{
- return (mp_maxid > 1);
+ return (mp_maxid > 0);
}
static void
OpenPOWER on IntegriCloud