From b2421c29f6f04b252b08ca131e25faebb7b33f7c Mon Sep 17 00:00:00 2001 From: Dmitry Chagin Date: Tue, 3 Mar 2009 17:34:09 +0000 Subject: 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 --- sys/kern/subr_smp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sys') 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); -- cgit v1.2.3