diff options
| author | dholland <dholland@NetBSD.org> | 2021-06-29 22:34:05 +0000 |
|---|---|---|
| committer | dholland <dholland@NetBSD.org> | 2021-06-29 22:34:05 +0000 |
| commit | 18a3dc4f4b3b7e967284cf52c1a6bcd225fd2fe3 (patch) | |
| tree | 02bd073fdc142dc172abae3856777e4bd490fa41 /sys/kern/vnode_if.src | |
| parent | 0de14abf82c10da4ae8db9360ff2e004792a4148 (diff) | |
- Add a new vnode op: VOP_PARSEPATH.
- Move namei_getcomponent to genfs_vnops.c and call it genfs_parsepath.
- Add a parsepath entry to every vnode ops table.
VOP_PARSEPATH takes a directory vnode to be searched and a complete
following path and chooses how much of that path to consume. To begin
with, all parsepath calls are genfs_parsepath, which locates the first
'/' as always.
Note that the call doesn't take the whole struct componentname, only
the string. The other bits of struct componentname should not be
needed and there's no reason to cause potential complications by
exposing them.
Diffstat (limited to 'sys/kern/vnode_if.src')
| -rw-r--r-- | sys/kern/vnode_if.src | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/sys/kern/vnode_if.src b/sys/kern/vnode_if.src index 6f5799c4d6b..6c56c2f1950 100644 --- a/sys/kern/vnode_if.src +++ b/sys/kern/vnode_if.src @@ -1,4 +1,4 @@ -# $NetBSD: vnode_if.src,v 1.80 2020/05/18 08:29:34 hannken Exp $ +# $NetBSD: vnode_if.src,v 1.81 2021/06/29 22:34:08 dholland Exp $ # # Copyright (c) 1992, 1993 # The Regents of the University of California. All rights reserved. @@ -58,6 +58,15 @@ vop_bwrite { IN struct vnode *vp; IN struct buf *bp; }; + +# +#% parsepath dvp L L L +# +vop_parsepath { + IN struct vnode *dvp; + IN const char *name; + OUT size_t *retval; +}; # #% lookup dvp L L L |
