GNU.WIKI: The GNU/Linux Knowledge Base

  [HOME] [PHP Manual] [HowTo] [ABS] [MAN1] [MAN2] [MAN3] [MAN4] [MAN5] [MAN6] [MAN7] [MAN8] [MAN9]

  [0-9] [Aa] [Bb] [Cc] [Dd] [Ee] [Ff] [Gg] [Hh] [Ii] [Jj] [Kk] [Ll] [Mm] [Nn] [Oo] [Pp] [Qq] [Rr] [Ss] [Tt] [Uu] [Vv] [Ww] [Xx] [Yy] [Zz]


NAME

     VOP_VPTOCNP — translate a vnode to its component name

SYNOPSIS

     #include <sys/param.h>
     #include <sys/vnode.h>

     int
     VOP_VPTOCNP(struct vnode *vp, struct vnode **dvp, char *buf,
         int *buflen);

DESCRIPTION

     This translates a vnode into its component name, and writes that name to
     the head of the buffer specified by buf.

     vp      The vnode to translate.

     dvp     The vnode of the parent directory of vp.

     buf     The buffer into which to prepend the component name.

     buflen  The remaining size of the buffer.

     The default implementation of VOP_VPTOCNP scans through vp's parent
     directory looking for a dirent with a matching file number.  If vp is not
     a directory, then VOP_VPTOCNP returns ENOENT.

LOCKS

     The vnode should be locked on entry and will still be locked on exit.
     The parent directory vnode will be unlocked on a successful exit.
     However, it will have its use count incremented.

RETURN VALUES

     Zero is returned on success, otherwise an error code is returned.

ERRORS

     [ENOMEM]           The buffer was not large enough to hold the vnode's
                        component name.

     [ENOENT]           The vnode was not found on the file system.

SEE ALSO

     VOP_LOOKUP(9), vnode(9)

NOTES

     This interface is a work in progress.

HISTORY

     The function VOP_VPTOCNP appeared in FreeBSD 8.0.

AUTHORS

     This manual page was written by Joe Marcus Clarke.



  All copyrights belong to their respective owners. Other content (c) 2014-2018, GNU.WIKI. Please report site errors to webmaster@gnu.wiki.
Page load time: 0.150 seconds. Last modified: November 04 2018 12:49:43.