From c739adbf423b4a7f9c12f178498da89f93939b3a Mon Sep 17 00:00:00 2001 From: John Baldwin Date: Wed, 28 Mar 2001 10:41:15 +0000 Subject: [PATCH] Pass in a pointer to the mutex's lock_object as the second argument to WITNESS_SLEEP() rather than the mutex itself. --- sys/kern/kern_condvar.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/kern/kern_condvar.c b/sys/kern/kern_condvar.c index d53e9e68f376..16007ecf68ba 100644 --- a/sys/kern/kern_condvar.c +++ b/sys/kern/kern_condvar.c @@ -196,7 +196,7 @@ cv_wait(struct cv *cvp, struct mtx *mp) ktrcsw(p->p_tracep, 1, 0); #endif CV_ASSERT(cvp, mp, p); - WITNESS_SLEEP(0, mp); + WITNESS_SLEEP(0, &mp->mtx_object); WITNESS_SAVE(&mp->mtx_object, mp); mtx_lock_spin(&sched_lock); @@ -249,7 +249,7 @@ cv_wait_sig(struct cv *cvp, struct mtx *mp) ktrcsw(p->p_tracep, 1, 0); #endif CV_ASSERT(cvp, mp, p); - WITNESS_SLEEP(0, mp); + WITNESS_SLEEP(0, &mp->mtx_object); WITNESS_SAVE(&mp->mtx_object, mp); mtx_lock_spin(&sched_lock); @@ -314,7 +314,7 @@ cv_timedwait(struct cv *cvp, struct mtx *mp, int timo) ktrcsw(p->p_tracep, 1, 0); #endif CV_ASSERT(cvp, mp, p); - WITNESS_SLEEP(0, mp); + WITNESS_SLEEP(0, &mp->mtx_object); WITNESS_SAVE(&mp->mtx_object, mp); mtx_lock_spin(&sched_lock); @@ -376,7 +376,7 @@ cv_timedwait_sig(struct cv *cvp, struct mtx *mp, int timo) ktrcsw(p->p_tracep, 1, 0); #endif CV_ASSERT(cvp, mp, p); - WITNESS_SLEEP(0, mp); + WITNESS_SLEEP(0, &mp->mtx_object); WITNESS_SAVE(&mp->mtx_object, mp); mtx_lock_spin(&sched_lock);