Date: Sat, 24 May 1997 10:20:10 +0100 (BST) From: Doug Rabson <dfr@nlsystems.com> To: Peter Wemm <peter@spinner.dialix.com.au> Cc: Tor Egge <Tor.Egge@idi.ntnu.no>, freebsd-bugs@hub.freebsd.org Subject: Re: kern/3581: trap 12 in lockstatus() Message-ID: <Pine.BSF.3.95q.970524101730.331J-100000@herring.nlsystems.com> In-Reply-To: <199705240811.QAA20320@spinner.dialix.com.au>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 24 May 1997, Peter Wemm wrote: > Doug Rabson wrote: > > > > There is also the VOP_ISLOCKED race to deal with which, I think, is more > > common. I have seen it a couple of times. One solution would be to > > change *all* calls to VOP_ISLOCKED to vn_islocked which would check VXLOCK > > before calling the filesystem. Another would be to change all VFS' > > VOP_ISLOCKED to check VXLOCK. > > I'm up to my eyeballs in a sweep over the code to implement poll. One of > the things that I've noticed is that many of the fs _lock routines simply > call the vop_nolock or whatever routines. There are some seriously ugly and > /or evil bits of code in there. :-( The vop_nolock routine is supposed to be a simple shared lock for filesystems which don't need node locking. The shared lock is still needed because vclean needs a true exclusive lock to avoid races. Unfortunately most of the filesystems don't honour the locking protocol so vop_nolock is stubbed out. I fixed NFS to do locking properly and created vop_sharedlock (an un-stubbed version of vop_nolock) but I never got around to fixing the other filesystems. -- Doug Rabson Mail: dfr@nlsystems.com Nonlinear Systems Ltd. Phone: +44 181 951 1891 Fax: +44 181 381 1039
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.95q.970524101730.331J-100000>