From 84d8d047ba855b0e24f1009141363b9d5e1dcf29 Mon Sep 17 00:00:00 2001 From: kib Date: Thu, 20 Nov 2014 11:33:38 +0000 Subject: [PATCH] MFC r274478: Fix assertion, &uc->uc_busy is never zero, the intent is to test the uc_busy value, and not its address. --- sys/kern/kern_umtx.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sys/kern/kern_umtx.c b/sys/kern/kern_umtx.c index 921769033b81..f064197500d5 100644 --- a/sys/kern/kern_umtx.c +++ b/sys/kern/kern_umtx.c @@ -169,7 +169,6 @@ struct umtxq_chain { }; #define UMTXQ_LOCKED_ASSERT(uc) mtx_assert(&(uc)->uc_lock, MA_OWNED) -#define UMTXQ_BUSY_ASSERT(uc) KASSERT(&(uc)->uc_busy, ("umtx chain is not busy")) /* * Don't propagate time-sharing priority, there is a security reason, @@ -1843,7 +1842,7 @@ umtxq_sleep_pi(struct umtx_q *uq, struct umtx_pi *pi, KASSERT(td == curthread, ("inconsistent uq_thread")); uc = umtxq_getchain(&uq->uq_key); UMTXQ_LOCKED_ASSERT(uc); - UMTXQ_BUSY_ASSERT(uc); + KASSERT(uc->uc_busy != 0, ("umtx chain is not busy")); umtxq_insert(uq); mtx_lock_spin(&umtx_lock); if (pi->pi_owner == NULL) {