tail head cat sleep
QR code linking to this page

Manual Pages  — VFS_GETVFS

NAME

vfs_getvfs – returns a mount point given its file system identifier

CONTENTS

SYNOPSIS

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

struct mount *
vfs_getvfs(fsid_t *fsid);

DESCRIPTION

The vfs_getvfs() function returns the mount point structure for a file system given its file system identifier. The file system ID should have been allocated by calling vfs_getnewfsid(9); otherwise, it will not be found.

A major user of vfs_getvfs() is NFS, which uses the fsid as part of file handles in order to determine the file system a given RPC is for. If vfs_getvfs() fails to find the mount point related to fsid, the file system is considered stale.

RETURN VALUES

If fsid is found, the mount point for the ID is returned; otherwise, NULL is returned.

PSEUDOCODE

if ((mp = vfs_getvfs(&fhp->fh_fsid)) == NULL) {
        error = ESTALE;
        goto out;
}

SEE ALSO

vfs_getnewfsid(9)

AUTHORS

This manual page was written by Chad David <Mt davidc@acns.ab.ca>.

VFS_GETVFS (9) November 21, 2001

tail head cat sleep
QR code linking to this page


Please direct any comments about this manual page service to Ben Bullock. Privacy policy.

Our grievance is not just against Unix itself, but against the cult of Unix zealots who defend and nurture it. They take the heat, disease, and pestilence as givens, and, as ancient shamans did, display their wounds, some self-inflicted, as proof of their power and wizardry. We aim, through bluntness and humor, to show them that they pray to a tin god, and that science, not religion, is the path to useful and friendly technology.
— The Unix Haters' handbook