Date: Thu, 30 Jan 2020 19:38:51 +0000 (UTC) From: Mateusz Guzik <mjg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r357308 - head/sys/kern Message-ID: <202001301938.00UJcpt1092189@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mjg Date: Thu Jan 30 19:38:51 2020 New Revision: 357308 URL: https://svnweb.freebsd.org/changeset/base/357308 Log: Assert that smp_rendezvous_cpus is called with interrupts enabled. Modified: head/sys/kern/subr_smp.c Modified: head/sys/kern/subr_smp.c ============================================================================== --- head/sys/kern/subr_smp.c Thu Jan 30 19:38:12 2020 (r357307) +++ head/sys/kern/subr_smp.c Thu Jan 30 19:38:51 2020 (r357308) @@ -563,6 +563,12 @@ smp_rendezvous_cpus(cpuset_t map, return; } + /* + * Make sure we come here with interrupts enabled. Otherwise we + * livelock if smp_ipi_mtx is owned by a thread which sent as an IPI. + */ + MPASS(curthread->td_md.md_spinlock_count == 0); + CPU_FOREACH(i) { if (CPU_ISSET(i, &map)) ncpus++;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202001301938.00UJcpt1092189>