nameToXfid() Kernel Service
Purpose
Obtains the xfid value and attributes for a specific file name.
Syntax
#include <sys/xfops.h>
#include <sys/vattr.h>
int nameToXfid(char *pathname,
struct xfid *xfp,
struct vattr *vap,
long flags);
Description
A kernel extension might need to convert a path name to an xfid_t structure. The
nameToXfid() kernel service returns the xfid value for a specific
path name.
Parameters
- pathname
- Full path name of the file for which an
xfidvalue is needed. - xfp
- Pointer to an
xfid_tstructure to hold thexfidvalue that is set by this routine. - vap
- Pointer to a
vattrstructure to be entered by this routine. No attributes are set if the pointer is null. - flags
- Operation modifiers. This parameter must be set to zero.
Return values
- 0
- Indicates success. The
xfidvalue and the optionalvattrstructure are returned. - ENOENT
- Name not found.
- EPERM
- No permission for lookup.
- EINVAL
- Invalid parameter is specified.