Subject: Re: nfsd: locking botch in op %d
To: None <tech-kern@netbsd.org>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: tech-kern
Date: 03/12/2001 11:28:27
>> It appears that the lock ufs_hashins() took on the vnode gets lost
>> somewhere in the checkalias() shuffle.

> In the case of an aliased device node, ufs_vinit calls vput() on the
> old vnode just before initializing the new one.  vput() means
> unlock+deref.  This one doesn't seem to show up in your trace output,
> but the lockmgr() call 2 lines below (still in ufs_vinit()) does.

This is because ufs_vinit, before it vput()s the old vnode, bashes the
vnodeops field to specfs's vnodeops.  And specfs's unlock routine is
genfs_nounlock, which doesn't actually do anything.  This means that
the VOP_UNLOCK in vput() is a no-op.

					der Mouse

			       mouse@rodents.montreal.qc.ca
		     7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B