Subject: Re: Addition to force open to open only regular files
To: Wolfgang Solfrank <ws@tools.de>
From: Warner Losh <imp@village.org>
List: tech-kern
Date: 11/29/2000 10:38:26
In message <200011291348.OAA01566@kurt.tools.de> Wolfgang Solfrank writes:
: getfh() certainly doesn't lock the leaf.  After all, what should unlock it?

Maybe I misunderstand what:
	NDINIT(&nd, LOOKUP, FOLLOW | LOCKLEAF, UIO_USERSPACE,
	    SCARG(uap, fname), p);
in the getfh code does.

: So there didn't exist any possibility to unlock the leaf after the call
: to getfh().  And locking it wouldn't have made any sense in the first
: place (NFS is stateless!).

I know it doesn't make sense, I was just looking at the code and
noticed that most of the other NDINIT calls didn't have LOCKLEAF in
them.

Warner