Date: Fri, 05 Aug 2005 23:59:58 -0700 From: Julian Elischer <julian@elischer.org> To: hselasky@c2i.net Cc: freebsd-hackers@freebsd.org Subject: Re: How to do proper locking Message-ID: <42F45FEE.6050601@elischer.org> In-Reply-To: <200508060139.57143.hselasky@c2i.net> References: <200508030023.04748.hselasky@c2i.net> <200508042253.34165.hselasky@c2i.net> <200508051329.14767.jhb@FreeBSD.org> <200508060139.57143.hselasky@c2i.net>
next in thread | previous in thread | raw e-mail | index | archive | help
Hans Petter Selasky wrote: > On Friday 05 August 2005 19:29, John Baldwin wrote: > > > Yes, you are right, but the problem is, that for most callback systems in the > kernel, there is no mechanism that will pre-lock some custom mutex before > calling the callback. Not generally applicable to this case but for example the netgraph callout wrappers handlle netgraph node locking so that teh called function can assume the node it is working on has been locked. It's not applicable because netgraph locking is "different" to locking elsewhere in the kernel due to the nature of netgraph. But havinng a specific callout wrapper for a subsystem does give the ability to do such things.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?42F45FEE.6050601>