From 7e4b46c64efa1219b000e0f25aca95483045ee99 Mon Sep 17 00:00:00 2001 From: jeff Date: Sun, 26 Jan 2003 04:00:39 +0000 Subject: - Call sched_sleep() instead of rolling our own in cv_waitq_add(). --- sys/kern/kern_condvar.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys') diff --git a/sys/kern/kern_condvar.c b/sys/kern/kern_condvar.c index d36b0c1..e943e3d 100644 --- a/sys/kern/kern_condvar.c +++ b/sys/kern/kern_condvar.c @@ -36,6 +36,7 @@ #include #include #include +#include #include #include #ifdef KTRACE @@ -173,11 +174,10 @@ cv_waitq_add(struct cv *cvp, struct thread *td) TD_SET_ON_SLEEPQ(td); td->td_wchan = cvp; td->td_wmesg = cvp->cv_description; - td->td_ksegrp->kg_slptime = 0; /* XXXKSE */ - td->td_base_pri = td->td_priority; CTR3(KTR_PROC, "cv_waitq_add: thread %p (pid %d, %s)", td, td->td_proc->p_pid, td->td_proc->p_comm); TAILQ_INSERT_TAIL(&cvp->cv_waitq, td, td_slpq); + sched_sleep(td, td->td_priority); } /* -- cgit v1.1