Date: Sat, 25 Nov 2000 12:11:42 -0800 From: Jake Burkholder <jburkhol@home.com> To: Alfred Perlstein <bright@wintelcom.net> Cc: John Baldwin <jhb@FreeBSD.ORG>, smp@FreeBSD.ORG Subject: Re: uidinfo patches, review please. Message-ID: <20001125201142.D6886BA7A@io.yi.org> In-Reply-To: Message from Jake Burkholder <jburkhol@home.com> of "Sat, 25 Nov 2000 12:07:54 PST." <20001125200754.CC0B8BA7A@io.yi.org>
next in thread | previous in thread | raw e-mail | index | archive | help
> > > @@ -735,9 +744,13 @@ > > > printf("freeing uidinfo: uid = %d, proccnt = %ld\n", > > > uip->ui_uid, uip->ui_proccnt); > > > LIST_REMOVE(uip, ui_hash); > > > + mtx_destroy(&uip->ui_mtx); > > > + mtx_exit(&uidhash_mtx, MTX_DEF); > > > > You should mtx_exit(&uip->ui_mtx) before destroying it here. > > This isn't strictly necessary, mtx_destroy handles destroying a > held mutex. I suppose it saves a locked bus op. > No, I take this back. You should exit the mutex, it could screw up witness because the lock will still be in the p_heldmtx list. > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-smp" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-smp" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20001125201142.D6886BA7A>