Module Name: src
Committed By: wiz
Date: Mon Feb 13 12:49:35 UTC 2012
Modified Files:
src/share/man/man9: vnodeops.9
Log Message:
Add locking description to some functions.
Add FILES section referencing source code.
>From Julian Fagir in PR 45988.
To generate a diff of this commit:
cvs rdiff -u -r1.83 -r1.84 src/share/man/man9/vnodeops.9
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/share/man/man9/vnodeops.9
diff -u src/share/man/man9/vnodeops.9:1.83 src/share/man/man9/vnodeops.9:1.84
--- src/share/man/man9/vnodeops.9:1.83 Mon Jul 18 04:39:28 2011
+++ src/share/man/man9/vnodeops.9 Mon Feb 13 12:49:35 2012
@@ -1,4 +1,4 @@
-.\" $NetBSD: vnodeops.9,v 1.83 2011/07/18 04:39:28 dholland Exp $
+.\" $NetBSD: vnodeops.9,v 1.84 2012/02/13 12:49:35 wiz Exp $
.\"
.\" Copyright (c) 2001, 2005, 2006 The NetBSD Foundation, Inc.
.\" All rights reserved.
@@ -27,7 +27,7 @@
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
.\" POSSIBILITY OF SUCH DAMAGE.
.\"
-.Dd July 11, 2011
+.Dd February 13, 2012
.Dt VNODEOPS 9
.Os
.Sh NAME
@@ -567,6 +567,10 @@ Attributes which are not available are s
.Pp
For more information on vnode attributes see
.Xr vattr 9 .
+.Pp
+The vnode
+.Fa vp
+will be locked on entry and should remain locked on return.
.It Fn VOP_SETATTR "vp" "vap" "cred"
Set specific vnode attributes on a file.
The argument
@@ -711,6 +715,10 @@ The argument
.Fa events
is a set of flags as specified by
.Xr poll 2 .
+.Pp
+The vnode
+.Fa vp
+remains unlocked throughout the whole operation.
.It Fn VOP_KQFILTER "vp" "kn"
Register a knote
.Fa kn
@@ -718,6 +726,10 @@ with the vnode
.Fa vn .
If the operation is successful zero is returned, otherwise an
appropriate error code is returned.
+.Pp
+The vnode
+.Fa vp
+remains unlocked throughout the whole operation.
.It Fn VOP_REVOKE "vp" "flags"
Eliminate all activity associated with the vnode
.Fa vp .
@@ -731,6 +743,10 @@ all vnodes aliased to the vnode
are also eliminated.
If the operation is successful zero is returned, otherwise an
appropriate error is returned.
+.Pp
+The vnode
+.Fa vp
+remains unlocked throughout the whole operation.
.It Fn VOP_MMAP "vp" "prot" "cred"
Inform file system that
.Fa vp
@@ -1232,6 +1248,10 @@ Whiteout pathname component in directory
The argument
.Fa cnp
specifies the pathname component to whiteout.
+.Pp
+The vnode
+.Fa dvp
+should be locked on entry and will remain locked on return.
.It Fn VOP_GETPAGES "vp" "offset" "m" "count" "centeridx" "access_type" "advice" "flags"
Read VM pages from file.
The argument
@@ -1407,7 +1427,15 @@ If full removal is not supported, the fi
.Er EOPNOTSUPP
to allow the caller to zero out the value with
.Fn VOP_SETEXTATTR .
+.Pp
+The vnode
+.Fa vp
+should be locked on entry and will remain locked on return.
.El
+.Sh FILES
+.Pa src/sys/kern/vnode_if.src
+contains the list of vnode functions, their definitions and an exact locking
+protocol.
.Sh ERRORS
.Bl -tag -width Er
.It Bq Er EACCES