git: 5673462af533 - main - namei.9: sort operational modifiers in numerical order
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 18 May 2025 21:38:29 UTC
The branch main has been updated by kib:
URL: https://cgit.FreeBSD.org/src/commit/?id=5673462af5330df20733008beae48a24da9cdf63
commit 5673462af5330df20733008beae48a24da9cdf63
Author: Konstantin Belousov <kib@FreeBSD.org>
AuthorDate: 2025-05-18 21:30:55 +0000
Commit: Konstantin Belousov <kib@FreeBSD.org>
CommitDate: 2025-05-18 21:37:29 +0000
namei.9: sort operational modifiers in numerical order
Note that NC_NOMAKEENTRY is an alias of NOCACHE.
Suggested by: mckusick
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
---
share/man/man9/namei.9 | 109 ++++++++++++++++++++++++++-----------------------
1 file changed, 59 insertions(+), 50 deletions(-)
diff --git a/share/man/man9/namei.9 b/share/man/man9/namei.9
index fc0826cc7206..63e1a5de02ea 100644
--- a/share/man/man9/namei.9
+++ b/share/man/man9/namei.9
@@ -148,7 +148,26 @@ The
function takes the following set of
.Dq "operation flags"
that influence its operation:
-.Bl -tag -width ".Dv WANTPARENT"
+.Bl -tag -width NC_KEEPPOSENTRY
+.It Dv NC_NOMAKEENTRY
+An alias for
+.Dv NOCACHE .
+.It Dv NC_KEEPPOSENTRY
+Keep the positive-caching entry in cache.
+This flag is typically combined with
+.Dv NOCACHE
+to not cache a new entry,
+but keep existing one, or with
+.Dv MAKEENTRY .
+.It Dv NOCACHE
+Avoid
+.Fn namei
+creating this entry in the namecache if it is not
+already present.
+Normally,
+.Fn namei
+will add entries to the name cache
+if they are not already there.
.It Dv LOCKLEAF
Lock vnode on return with
.Dv LK_EXCLUSIVE
@@ -181,6 +200,45 @@ or
.Xr VOP_UNLOCK 9
and
.Xr vrele 9 .
+.It Dv WANTPARENT
+This flag allows the
+.Fn namei
+function to return the parent (directory) vnode in an unlocked state.
+The parent vnode must be released separately by using
+.Xr vrele 9 .
+.It Dv WANTPARENT
+This flag allows the
+.Fn namei
+function to return the parent (directory) vnode in an unlocked state.
+The parent vnode must be released separately by using
+.Xr vrele 9 .
+.It Dv FAILIFEXISTS
+Makes the
+.Nm
+operation fail if the target exists.
+It requires that the
+.Dv LOCKPARENT
+flag is set and
+.Dv LOCKLEAF
+is not.
+.It Dv FOLLOW
+With this flag,
+.Fn namei
+will follow the symbolic link if the last part
+of the path supplied is a symbolic link (i.e., it will return a vnode
+for whatever the link points at, instead for the link itself).
+.It Dv EMPTYPATH
+For
+.Nm
+call initialized with
+.Fn NDINIT_AT ,
+allow the
+.Fa namep
+path to be empty.
+In this case, the
+.Fa dirfd
+file descriptor may reference a file of arbitrary type, not
+necessary a directory, and lookup returns the vnode for this file.
.It Dv LOCKSHARED
Lock vnode on return with
.Dv LK_SHARED ,
@@ -206,27 +264,6 @@ which is equivalent to calling
followed by
.Xr vrele 9 ,
all in one).
-.It Dv WANTPARENT
-This flag allows the
-.Fn namei
-function to return the parent (directory) vnode in an unlocked state.
-The parent vnode must be released separately by using
-.Xr vrele 9 .
-.It Dv NOCACHE
-Avoid
-.Fn namei
-creating this entry in the namecache if it is not
-already present.
-Normally,
-.Fn namei
-will add entries to the name cache
-if they are not already there.
-.It Dv FOLLOW
-With this flag,
-.Fn namei
-will follow the symbolic link if the last part
-of the path supplied is a symbolic link (i.e., it will return a vnode
-for whatever the link points at, instead for the link itself).
.It Dv NOFOLLOW
Do not follow symbolic links (pseudo).
This flag is not looked for by the actual code, which looks for
@@ -234,34 +271,6 @@ This flag is not looked for by the actual code, which looks for
.Dv NOFOLLOW
is used to indicate to the source code reader that symlinks
are intentionally not followed.
-.It Dv NC_KEEPPOSENTRY
-Keep the positive-caching entry in cache.
-This flag is typically combined with
-.Dv NOCACHE
-to not cache a new entry,
-but keep existing one, or with
-.Dv MAKEENTRY .
-.It Dv FAILIFEXISTS
-Makes the
-.Nm
-operation fail if the target exists.
-It requires that the
-.Dv LOCKPARENT
-flag is set and
-.Dv LOCKLEAF
-is not.
-.It Dv EMPTYPATH
-For
-.Nm
-call initialized with
-.Fn NDINIT_AT ,
-allow the
-.Fa namep
-path to be empty.
-In this case, the
-.Fa dirfd
-file descriptor may reference a file of arbitrary type, not
-necessary a directory, and lookup returns the vnode for this file.
.It Dv RBENEATH
Requires that
.Nm