GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
VOP_VPTOCNP(9) FreeBSD Kernel Developer's Manual VOP_VPTOCNP(9)

VOP_VPTOCNP
translate a vnode to its component name

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

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

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.
cred
The caller credentials.
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.

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.

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

[]
The buffer was not large enough to hold the vnode's component name.
[]
The vnode was not found on the file system.

vnode(9), VOP_LOOKUP(9)

This interface is a work in progress.

The function VOP_VPTOCNP appeared in FreeBSD 8.0.

This manual page was written by Joe Marcus Clarke.
March 8, 2015 FreeBSD 13.1-RELEASE

Search for    or go to Top of page |  Section 9 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.