svn commit: r189313 - head/sys/kern
Dmitry Chagin
dchagin at FreeBSD.org
Tue Mar 3 09:34:11 PST 2009
Author: dchagin
Date: Tue Mar 3 17:34:09 2009
New Revision: 189313
URL: http://svn.freebsd.org/changeset/base/189313
Log:
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
Modified:
head/sys/kern/subr_smp.c
Modified: head/sys/kern/subr_smp.c
==============================================================================
--- head/sys/kern/subr_smp.c Tue Mar 3 17:16:26 2009 (r189312)
+++ head/sys/kern/subr_smp.c Tue Mar 3 17:34:09 2009 (r189313)
@@ -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);
More information about the svn-src-all
mailing list