VOP_SEEK

NAME
VOP_SEEK - seek to a given location in a file

SYNOPSIS
#include <sys/param.h>
#include <sys/vnode.h>
int
VOP_SEEK(struct vnode *vp, off_t oldoff, off_t newoff, struct ucred *cred);

DESCRIPTION
This seeks to a given location in a file, possibly extending the file. Most filesystems do not implement this entry point and automatically extend the file when it is written to. In fact, the only place in the entire kernel where this is called is from the union filesystem and then only to implement its own VOP_SEEK entry point.

Its arguments are:

vp  the vnode of the file

oldoff
    an offset

newoff
    another offset

cred
    the caller's credentials

PSEUDOCODE

    int
    vop_seek(struct vnode *vp, off_t oldoff, off_t newoff, struct ucred *cred)
    {
        return 0;
    }

SEE ALSO
vnode(9)

AUTHORS
This man page was written by Doug Rabson.