mtx_lock_recurse/mtx_unlock_recurse functions (proof-of-concept).

Pawel Jakub Dawidek pjd at FreeBSD.org
Thu Apr 8 14:59:52 PDT 2004


On Thu, Apr 08, 2004 at 11:40:07PM +0200, Poul-Henning Kamp wrote:
+> >As was discussed, it will be helpful to have functions, that are able
+> >to acquire lock recursively, even if lock itself isn't recursable.
+> 
+> Sounds evil to me...

Why? I don't think that better is to just use MTX_RECURSE if we don't need
it in 90% of cases. And sometimes it is really hard to pass information if
lock is held or not, just like for that rwatson's kqueue thing.

+> Does your patch also make witness aware of this ?

Nope, it is just a proof-of-concept and as jhb@ pointed out, we want
to keep our interface simple, so it probably will never reach the tree.

-- 
Pawel Jakub Dawidek                       http://www.FreeBSD.org
pjd at FreeBSD.org                           http://garage.freebsd.pl
FreeBSD committer                         Am I Evil? Yes, I Am!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-arch/attachments/20040408/a1e0a355/attachment.bin


More information about the freebsd-arch mailing list