aboutsummaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorDmitry Chagin <dchagin@FreeBSD.org>2009-03-03 17:34:09 +0000
committerDmitry Chagin <dchagin@FreeBSD.org>2009-03-03 17:34:09 +0000
commitb2421c29f6f04b252b08ca131e25faebb7b33f7c (patch)
tree52429eaebdc7081020b7d1a7d8a2b27149195139 /sys
parent73e416e35d2cceae0909f39bfa24748005dbb369 (diff)
downloadsrc-b2421c29f6f04b252b08ca131e25faebb7b33f7c.tar.gz
src-b2421c29f6f04b252b08ca131e25faebb7b33f7c.zip
as suggested by jhb@, panic in case the ncpus == 0.
it helps to catch bugs in the callers. Approved by: kib (mentor) MFC after: 5 days
Notes
Notes: svn path=/head/; revision=189313
Diffstat (limited to 'sys')
-rw-r--r--sys/kern/subr_smp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/subr_smp.c b/sys/kern/subr_smp.c
index c1bd50ea316f..e807e485cbcf 100644
--- a/sys/kern/subr_smp.c
+++ b/sys/kern/subr_smp.c
@@ -366,7 +366,7 @@ smp_rendezvous_cpus(cpumask_t map,
if (((1 << i) & map) != 0 && !CPU_ABSENT(i))
ncpus++;
if (ncpus == 0)
- return;
+ panic("ncpus is 0 with map=0x%x", map);
/* obtain rendezvous lock */
mtx_lock_spin(&smp_ipi_mtx);