Good point. Will fix.
On Mon, May 21, 2018 at 9:54 AM, Eric van Gyzen <e...@vangyzen.net> wrote: > On 05/19/2018 00:09, Matt Macy wrote: >> @@ -1663,16 +1655,18 @@ static int >> umtxq_sleep_pi(struct umtx_q *uq, struct umtx_pi *pi, uint32_t owner, >> const char *wmesg, struct abs_timeout *timo, bool shared) >> { >> - struct umtxq_chain *uc; >> struct thread *td, *td1; >> struct umtx_q *uq1; >> int error, pri; >> +#ifdef INVARIANTS >> + struct umtxq_chain *uc; >> >> + uc = umtxq_getchain(&pi->pi_key); >> +#endif >> error = 0; >> td = uq->uq_thread; >> KASSERT(td == curthread, ("inconsistent uq_thread")); >> - uc = umtxq_getchain(&uq->uq_key); >> - UMTXQ_LOCKED_ASSERT(uc); >> + UMTXQ_LOCKED_ASSERT(umtxq_getchain(&uq->uq_key)); > > Couldn't this line stay as it was? > > UMTXQ_LOCKED_ASSERT(uc); > > With the current code, we're calling umtxq_getchain() once more than > necessary. Also, the casual reader might be confused by calling it with > two different arguments. > > Eric _______________________________________________ svn-src-all@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"