summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_condvar.c
diff options
context:
space:
mode:
authordavidxu <davidxu@FreeBSD.org>2006-02-23 00:13:58 +0000
committerdavidxu <davidxu@FreeBSD.org>2006-02-23 00:13:58 +0000
commite29c8e080b595587aafe2e1d02c5eb9f9f322a51 (patch)
tree7e38ae2e71791b901f46413e77ea39d2b4ba7ae0 /sys/kern/kern_condvar.c
parentff94f53a5d7abb067a90f6013082aaa99474583d (diff)
downloadFreeBSD-src-e29c8e080b595587aafe2e1d02c5eb9f9f322a51.zip
FreeBSD-src-e29c8e080b595587aafe2e1d02c5eb9f9f322a51.tar.gz
Fix a sleep queue race for KSE thread.
Reviewed by: jhb
Diffstat (limited to 'sys/kern/kern_condvar.c')
-rw-r--r--sys/kern/kern_condvar.c24
1 files changed, 0 insertions, 24 deletions
diff --git a/sys/kern/kern_condvar.c b/sys/kern/kern_condvar.c
index f430ea8..7377981 100644
--- a/sys/kern/kern_condvar.c
+++ b/sys/kern/kern_condvar.c
@@ -192,18 +192,6 @@ cv_wait_sig(struct cv *cvp, struct mtx *mp)
sleepq_lock(cvp);
- /*
- * Don't bother sleeping if we are exiting and not the exiting
- * thread or if our thread is marked as interrupted.
- */
- mtx_lock_spin(&sched_lock);
- rval = thread_sleep_check(td);
- mtx_unlock_spin(&sched_lock);
- if (rval != 0) {
- sleepq_release(cvp);
- return (rval);
- }
-
cvp->cv_waiters++;
DROP_GIANT();
mtx_unlock(mp);
@@ -315,18 +303,6 @@ cv_timedwait_sig(struct cv *cvp, struct mtx *mp, int timo)
sleepq_lock(cvp);
- /*
- * Don't bother sleeping if we are exiting and not the exiting
- * thread or if our thread is marked as interrupted.
- */
- mtx_lock_spin(&sched_lock);
- rval = thread_sleep_check(td);
- mtx_unlock_spin(&sched_lock);
- if (rval != 0) {
- sleepq_release(cvp);
- return (rval);
- }
-
cvp->cv_waiters++;
DROP_GIANT();
mtx_unlock(mp);
OpenPOWER on IntegriCloud