summaryrefslogtreecommitdiffstats
path: root/sys/kern
diff options
context:
space:
mode:
authorvangyzen <vangyzen@FreeBSD.org>2016-10-19 00:14:22 +0000
committervangyzen <vangyzen@FreeBSD.org>2016-10-19 00:14:22 +0000
commit8b46a087e8d44313485a6aa6c4c8becd4cafa3ad (patch)
tree18fb20cc3b4b1382c31bce143b4271bc87822115 /sys/kern
parent9060d7f44c15143ed176a3845065b95ed23fec4d (diff)
downloadFreeBSD-src-8b46a087e8d44313485a6aa6c4c8becd4cafa3ad.zip
FreeBSD-src-8b46a087e8d44313485a6aa6c4c8becd4cafa3ad.tar.gz
MFC r306346
Make no assertions about mutex state when the scheduler is stopped. This changes the assert path to match the lock and unlock paths. Sponsored by: Dell EMC
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/kern_mutex.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c
index c847afc..8d19f2e 100644
--- a/sys/kern/kern_mutex.c
+++ b/sys/kern/kern_mutex.c
@@ -848,7 +848,7 @@ __mtx_assert(const volatile uintptr_t *c, int what, const char *file, int line)
{
const struct mtx *m;
- if (panicstr != NULL || dumping)
+ if (panicstr != NULL || dumping || SCHEDULER_STOPPED())
return;
m = mtxlock2mtx(c);
OpenPOWER on IntegriCloud