diff options
author | Konstantin Belousov <kib@FreeBSD.org> | 2020-01-13 14:30:19 +0000 |
---|---|---|
committer | Konstantin Belousov <kib@FreeBSD.org> | 2020-01-13 14:30:19 +0000 |
commit | fedab1b4998d10f072d601bf3b0e1cb50a110095 (patch) | |
tree | 00fa2c82614c7d941611243dc7bf274835090126 /sys/kern/subr_epoch.c | |
parent | 5452c16c2138f6f68e7c447a80856a779e5eea6f (diff) | |
download | src-fedab1b4998d10f072d601bf3b0e1cb50a110095.tar.gz src-fedab1b4998d10f072d601bf3b0e1cb50a110095.zip |
Code must not unlock a mutex while owning the thread lock.
Reviewed by: hselasky, markj
Sponsored by: Mellanox Technologies
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D23150
Notes
Notes:
svn path=/head/; revision=356682
Diffstat (limited to 'sys/kern/subr_epoch.c')
-rw-r--r-- | sys/kern/subr_epoch.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/subr_epoch.c b/sys/kern/subr_epoch.c index a2b99d12a390..39fe3125395e 100644 --- a/sys/kern/subr_epoch.c +++ b/sys/kern/subr_epoch.c @@ -610,8 +610,8 @@ epoch_wait_preempt(epoch_t epoch) KASSERT(!in_epoch(epoch), ("epoch_wait_preempt() called in the middle " "of an epoch section of the same epoch")); #endif - thread_lock(td); DROP_GIANT(); + thread_lock(td); old_cpu = PCPU_GET(cpuid); old_pinned = td->td_pinned; |