Home | History | Annotate | Line # | Download | only in kern
vnode_if.src revision 1.42.2.1
      1  1.42.2.1      kent #	$NetBSD: vnode_if.src,v 1.42.2.1 2005/04/29 11:29:25 kent Exp $
      2       1.1   mycroft #
      3       1.1   mycroft # Copyright (c) 1992, 1993
      4       1.1   mycroft #	The Regents of the University of California.  All rights reserved.
      5       1.1   mycroft #
      6       1.1   mycroft # Redistribution and use in source and binary forms, with or without
      7       1.1   mycroft # modification, are permitted provided that the following conditions
      8       1.1   mycroft # are met:
      9       1.1   mycroft # 1. Redistributions of source code must retain the above copyright
     10       1.1   mycroft #    notice, this list of conditions and the following disclaimer.
     11       1.1   mycroft # 2. Redistributions in binary form must reproduce the above copyright
     12       1.1   mycroft #    notice, this list of conditions and the following disclaimer in the
     13       1.1   mycroft #    documentation and/or other materials provided with the distribution.
     14       1.1   mycroft # 3. All advertising materials mentioning features or use of this software
     15       1.1   mycroft #    must display the following acknowledgement:
     16       1.1   mycroft #	This product includes software developed by the University of
     17       1.1   mycroft #	California, Berkeley and its contributors.
     18       1.1   mycroft # 4. Neither the name of the University nor the names of its contributors
     19       1.1   mycroft #    may be used to endorse or promote products derived from this software
     20       1.1   mycroft #    without specific prior written permission.
     21       1.1   mycroft #
     22       1.1   mycroft # THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
     23       1.1   mycroft # ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
     24       1.1   mycroft # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
     25       1.1   mycroft # ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
     26       1.1   mycroft # FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
     27       1.1   mycroft # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
     28       1.1   mycroft # OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
     29       1.1   mycroft # HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
     30       1.1   mycroft # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
     31       1.1   mycroft # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
     32       1.1   mycroft # SUCH DAMAGE.
     33       1.1   mycroft #
     34      1.13      fvdl #	@(#)vnode_if.src	8.14 (Berkeley) 8/6/95
     35      1.13      fvdl #
     36      1.13      fvdl #
     37      1.13      fvdl 
     38      1.13      fvdl # 
     39      1.13      fvdl # Above each of the vop descriptors is a specification of the locking
     40      1.13      fvdl # protocol used by each vop call.  The first column is the name of
     41      1.13      fvdl # the variable, the remaining three columns are in, out and error
     42      1.13      fvdl # respectively.  The "in" column defines the lock state on input,
     43      1.36       wiz # the "out" column defines the state on successful return, and the
     44      1.13      fvdl # "error" column defines the locking state on error exit.
     45      1.13      fvdl #     
     46      1.13      fvdl # The locking value can take the following values:
     47      1.13      fvdl # L: locked.
     48      1.30       chs # U: unlocked.
     49      1.13      fvdl # -: not applicable.  vnode does not yet (or no longer) exists.
     50      1.13      fvdl # =: the same on input and output, may be either L or U.
     51      1.13      fvdl # X: locked if not nil.
     52      1.22  wrstuden #
     53      1.22  wrstuden # For operations other than VOP_LOOKUP which require a component name
     54      1.22  wrstuden # parameter, the flags required for the initial namei() call are listed.
     55      1.22  wrstuden # Additional flags may be added to the namei() call, but these are required.
     56      1.13      fvdl #     
     57      1.13      fvdl  
     58      1.13      fvdl #
     59      1.13      fvdl #% lookup     dvp     L ? ?
     60      1.13      fvdl #% lookup     vpp     - L -
     61      1.13      fvdl #
     62      1.13      fvdl # XXX - the lookup locking protocol defies simple description and depends
     63      1.13      fvdl #     on the flags and operation fields in the (cnp) structure.  Note
     64      1.13      fvdl #     especially that *vpp may equal dvp and both may be locked.
     65      1.16  sommerfe #
     66      1.16  sommerfe #    More details:
     67      1.20  wrstuden #     There are three types of lookups: ".", ".." (ISDOTDOT), and other.
     68      1.20  wrstuden #     On successful lookup of ".", a reference is added to dvp, and it
     69      1.20  wrstuden #          is returned in *vpp.
     70      1.20  wrstuden #     To look up ISDOTDOT, dvp is unlocked, the ".." node is locked, and
     71      1.20  wrstuden #          then dvp is relocked iff LOCKPARENT is set and this is the last
     72      1.20  wrstuden #          component name (ISLASTCN set). This preserves the
     73      1.20  wrstuden #          protocol of always locking nodes from root ("/") downward and
     74      1.20  wrstuden #          prevents deadlock.
     75      1.20  wrstuden #     Other lookups find the named node (creating the vnode if needed) and
     76      1.20  wrstuden #          return it, locked, in *vpp.
     77      1.20  wrstuden #     For non-"." lookups, if LOCKPARENT is not set or this was not the
     78      1.20  wrstuden #          last component name, dvp is returned unlocked on a successful
     79      1.20  wrstuden #          lookup.
     80      1.20  wrstuden #     On failure, *vpp is NULL, and *dvp is left locked. If there was
     81      1.22  wrstuden #          an error re-locking dvp (for instance in the ISDOTDOT case),
     82      1.22  wrstuden #          the error is returned with PDIRUNLOCK set.
     83      1.16  sommerfe #	
     84      1.16  sommerfe #     *vpp is always locked on return if the operation succeeds.
     85      1.16  sommerfe #     typically, if *vpp == dvp, you need to release twice, but unlock once.
     86      1.16  sommerfe #
     87      1.20  wrstuden #     The PDIRUNLOCK flag is set when dvp is unlocked in the lookup routine.
     88      1.20  wrstuden #          It signals the caller that dvp's lock state changed. It will
     89      1.20  wrstuden #          be set on exit if either a successful lookup unlocked the
     90      1.20  wrstuden #          parrent, or there was an error re-locking dvp in the ISDOTDOT case.
     91       1.1   mycroft #
     92      1.22  wrstuden #     See sys/sys/namei.h for a description of the SAVENAME and SAVESTART
     93      1.22  wrstuden #          flags.
     94      1.22  wrstuden #
     95       1.1   mycroft vop_lookup {
     96       1.1   mycroft 	IN struct vnode *dvp;
     97       1.1   mycroft 	INOUT struct vnode **vpp;
     98       1.1   mycroft 	IN struct componentname *cnp;
     99       1.1   mycroft };
    100       1.1   mycroft 
    101      1.13      fvdl #
    102      1.13      fvdl #% create     dvp     L U U
    103      1.13      fvdl #% create     vpp     - L -
    104      1.13      fvdl #
    105      1.22  wrstuden #! create cnp	CREATE, LOCKPARENT
    106      1.22  wrstuden #
    107       1.1   mycroft vop_create {
    108      1.41   thorpej 	IN LOCKED=YES WILLPUT struct vnode *dvp;
    109       1.1   mycroft 	OUT struct vnode **vpp;
    110       1.1   mycroft 	IN struct componentname *cnp;
    111       1.1   mycroft 	IN struct vattr *vap;
    112       1.1   mycroft };
    113       1.1   mycroft 
    114      1.13      fvdl #
    115      1.13      fvdl #% mknod      dvp     L U U
    116      1.29     assar #% mknod      vpp     - L -
    117      1.13      fvdl #
    118      1.22  wrstuden #! mknod cnp	CREATE, LOCKPARENT
    119      1.22  wrstuden #
    120       1.1   mycroft vop_mknod {
    121      1.41   thorpej 	IN LOCKED=YES WILLPUT struct vnode *dvp;
    122      1.29     assar 	OUT struct vnode **vpp;
    123       1.1   mycroft 	IN struct componentname *cnp;
    124       1.1   mycroft 	IN struct vattr *vap;
    125       1.1   mycroft };
    126       1.1   mycroft 
    127      1.13      fvdl #
    128      1.13      fvdl #% open               vp      L L L
    129      1.13      fvdl #
    130       1.1   mycroft vop_open {
    131      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    132       1.1   mycroft 	IN int mode;
    133       1.1   mycroft 	IN struct ucred *cred;
    134      1.35      fvdl 	IN struct proc *p;
    135       1.1   mycroft };
    136       1.1   mycroft 
    137      1.13      fvdl #
    138      1.15  wrstuden #% close      vp      L L L
    139      1.13      fvdl #
    140       1.1   mycroft vop_close {
    141      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    142       1.1   mycroft 	IN int fflag;
    143       1.1   mycroft 	IN struct ucred *cred;
    144      1.35      fvdl 	IN struct proc *p;
    145       1.1   mycroft };
    146       1.1   mycroft 
    147      1.13      fvdl #
    148      1.13      fvdl #% access     vp      L L L
    149      1.13      fvdl #
    150       1.1   mycroft vop_access {
    151      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    152       1.1   mycroft 	IN int mode;
    153       1.1   mycroft 	IN struct ucred *cred;
    154      1.35      fvdl 	IN struct proc *p;
    155       1.1   mycroft };
    156       1.1   mycroft 
    157      1.13      fvdl #
    158      1.13      fvdl #% getattr    vp      = = =
    159      1.13      fvdl #
    160       1.1   mycroft vop_getattr {
    161       1.1   mycroft 	IN struct vnode *vp;
    162       1.1   mycroft 	IN struct vattr *vap;
    163       1.1   mycroft 	IN struct ucred *cred;
    164      1.35      fvdl 	IN struct proc *p;
    165       1.1   mycroft };
    166       1.1   mycroft 
    167      1.13      fvdl #
    168      1.13      fvdl #% setattr    vp      L L L
    169      1.13      fvdl #
    170       1.1   mycroft vop_setattr {
    171      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    172       1.1   mycroft 	IN struct vattr *vap;
    173       1.1   mycroft 	IN struct ucred *cred;
    174      1.35      fvdl 	IN struct proc *p;
    175       1.1   mycroft };
    176       1.1   mycroft 
    177      1.13      fvdl #
    178      1.13      fvdl #% read               vp      L L L
    179      1.13      fvdl #
    180       1.1   mycroft vop_read {
    181      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    182       1.1   mycroft 	INOUT struct uio *uio;
    183       1.1   mycroft 	IN int ioflag;
    184       1.1   mycroft 	IN struct ucred *cred;
    185       1.1   mycroft };
    186       1.1   mycroft 
    187      1.13      fvdl #
    188      1.13      fvdl #% write      vp      L L L
    189      1.13      fvdl #
    190       1.1   mycroft vop_write {
    191      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    192       1.1   mycroft 	INOUT struct uio *uio;
    193       1.1   mycroft 	IN int ioflag;
    194       1.1   mycroft 	IN struct ucred *cred;
    195       1.1   mycroft };
    196       1.1   mycroft 
    197      1.13      fvdl #
    198      1.13      fvdl #% ioctl      vp      U U U
    199      1.13      fvdl #
    200       1.1   mycroft vop_ioctl {
    201      1.41   thorpej 	IN LOCKED=NO struct vnode *vp;
    202       1.4       cgd 	IN u_long command;
    203      1.32  jdolecek 	IN void *data;
    204      1.19  wrstuden 	IN int fflag;
    205      1.19  wrstuden 	IN struct ucred *cred;
    206      1.35      fvdl 	IN struct proc *p;
    207      1.19  wrstuden };
    208      1.19  wrstuden 
    209      1.19  wrstuden #
    210      1.19  wrstuden #% fcntl      vp      L L L
    211      1.19  wrstuden #
    212      1.19  wrstuden vop_fcntl {
    213      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    214      1.19  wrstuden 	IN u_int command;
    215      1.32  jdolecek 	IN void *data;
    216       1.1   mycroft 	IN int fflag;
    217       1.1   mycroft 	IN struct ucred *cred;
    218      1.35      fvdl 	IN struct proc *p;
    219       1.1   mycroft };
    220       1.1   mycroft 
    221      1.13      fvdl #
    222      1.13      fvdl #% poll     vp      U U U
    223      1.13      fvdl #
    224      1.11   mycroft vop_poll {
    225      1.41   thorpej 	IN LOCKED=NO struct vnode *vp;
    226      1.11   mycroft 	IN int events;
    227      1.35      fvdl 	IN struct proc *p;
    228      1.31  jdolecek };
    229      1.31  jdolecek 
    230      1.31  jdolecek #
    231      1.31  jdolecek #% kqfilter     vp      U U U
    232      1.31  jdolecek #
    233      1.31  jdolecek vop_kqfilter {
    234      1.41   thorpej 	IN LOCKED=NO struct vnode *vp;
    235      1.31  jdolecek 	IN struct knote *kn;
    236       1.1   mycroft };
    237       1.1   mycroft 
    238      1.13      fvdl #
    239      1.13      fvdl #% revoke     vp      U U U
    240      1.13      fvdl #
    241      1.13      fvdl vop_revoke {
    242      1.41   thorpej 	IN LOCKED=NO struct vnode *vp;
    243      1.13      fvdl 	IN int flags;
    244      1.13      fvdl };
    245      1.13      fvdl 
    246      1.13      fvdl #     
    247      1.30       chs #% mmap      vp      = = =
    248      1.13      fvdl #
    249       1.1   mycroft vop_mmap {
    250       1.1   mycroft 	IN struct vnode *vp;
    251       1.1   mycroft 	IN int fflags;
    252       1.1   mycroft 	IN struct ucred *cred;
    253      1.35      fvdl 	IN struct proc *p;
    254       1.1   mycroft };
    255       1.1   mycroft 
    256      1.13      fvdl #
    257      1.13      fvdl #% fsync      vp      L L L
    258      1.13      fvdl #
    259       1.1   mycroft vop_fsync {
    260      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    261       1.1   mycroft 	IN struct ucred *cred;
    262      1.14    kleink 	IN int flags;
    263      1.37       wiz 	IN off_t offlo;
    264      1.37       wiz 	IN off_t offhi;
    265      1.35      fvdl 	IN struct proc *p;
    266       1.1   mycroft };
    267       1.1   mycroft 
    268      1.13      fvdl #
    269      1.13      fvdl # Needs work: Is newoff right?  What's it mean?
    270      1.41   thorpej # XXX Locking prototocl?
    271      1.13      fvdl #
    272       1.1   mycroft vop_seek {
    273       1.1   mycroft 	IN struct vnode *vp;
    274       1.1   mycroft 	IN off_t oldoff;
    275       1.1   mycroft 	IN off_t newoff;
    276       1.1   mycroft 	IN struct ucred *cred;
    277       1.1   mycroft };
    278       1.1   mycroft 
    279      1.13      fvdl #
    280      1.13      fvdl #% remove     dvp     L U U
    281      1.13      fvdl #% remove     vp      L U U
    282      1.13      fvdl #
    283      1.22  wrstuden #! remove cnp	DELETE, LOCKPARENT | LOCKLEAF
    284      1.22  wrstuden #
    285       1.1   mycroft vop_remove {
    286      1.41   thorpej 	IN LOCKED=YES WILLPUT struct vnode *dvp;
    287      1.41   thorpej 	IN LOCKED=YES WILLPUT struct vnode *vp;
    288       1.1   mycroft 	IN struct componentname *cnp;
    289       1.1   mycroft };
    290       1.1   mycroft 
    291      1.13      fvdl #
    292      1.13      fvdl #% link               vp      U U U
    293      1.41   thorpej #% link               dvp     L U U
    294      1.13      fvdl #
    295      1.22  wrstuden #! link	 cnp	CREATE, LOCKPARENT
    296      1.22  wrstuden #
    297       1.1   mycroft vop_link {
    298      1.41   thorpej 	IN LOCKED=YES WILLPUT struct vnode *dvp;
    299      1.41   thorpej 	IN LOCKED=NO struct vnode *vp;
    300       1.1   mycroft 	IN struct componentname *cnp;
    301       1.1   mycroft };
    302       1.1   mycroft 
    303      1.13      fvdl #
    304      1.13      fvdl #% rename     fdvp    U U U
    305      1.13      fvdl #% rename     fvp     U U U
    306      1.13      fvdl #% rename     tdvp    L U U
    307      1.13      fvdl #% rename     tvp     X U U
    308      1.13      fvdl #
    309      1.22  wrstuden #! rename fcnp	DELETE,	WANTPARENT | SAVESTART
    310      1.22  wrstuden #! rename tcnp	RENAME, LOCKPARENT | LOCKLEAF | NOCACHE | SAVESTART
    311      1.22  wrstuden #
    312      1.22  wrstuden # XXX the vop_rename routines should REALLY NOT be depending on SAVESTART!
    313      1.22  wrstuden #
    314       1.1   mycroft vop_rename {
    315      1.41   thorpej 	IN LOCKED=NO WILLRELE struct vnode *fdvp;
    316      1.41   thorpej 	IN LOCKED=NO WILLRELE struct vnode *fvp;
    317       1.1   mycroft 	IN struct componentname *fcnp;
    318      1.41   thorpej 	IN LOCKED=YES WILLPUT struct vnode *tdvp;
    319      1.33  jdolecek 	IN WILLPUT struct vnode *tvp;
    320       1.1   mycroft 	IN struct componentname *tcnp;
    321       1.1   mycroft };
    322       1.1   mycroft 
    323      1.13      fvdl #
    324      1.13      fvdl #% mkdir      dvp     L U U
    325      1.13      fvdl #% mkdir      vpp     - L - 
    326      1.13      fvdl #
    327      1.22  wrstuden #! mkdir cnp	CREATE, LOCKPARENT
    328      1.22  wrstuden #
    329       1.1   mycroft vop_mkdir {
    330      1.41   thorpej 	IN LOCKED=YES WILLPUT struct vnode *dvp;
    331       1.1   mycroft 	OUT struct vnode **vpp;
    332       1.1   mycroft 	IN struct componentname *cnp;
    333       1.1   mycroft 	IN struct vattr *vap;
    334       1.1   mycroft };
    335       1.1   mycroft 
    336      1.13      fvdl #
    337      1.13      fvdl #% rmdir      dvp     L U U
    338      1.13      fvdl #% rmdir      vp      L U U
    339      1.13      fvdl #
    340      1.22  wrstuden #! rmdir cnp	DELETE, LOCKPARENT | LOCKLEAF
    341      1.22  wrstuden #
    342       1.1   mycroft vop_rmdir {
    343      1.41   thorpej 	IN LOCKED=YES WILLPUT struct vnode *dvp;
    344      1.41   thorpej 	IN LOCKED=YES WILLPUT struct vnode *vp;
    345       1.1   mycroft 	IN struct componentname *cnp;
    346       1.1   mycroft };
    347       1.1   mycroft 
    348      1.13      fvdl #
    349      1.13      fvdl #% symlink    dvp     L U U
    350      1.29     assar #% symlink    vpp     - L -
    351      1.13      fvdl #
    352      1.22  wrstuden #! symlink cnp	CREATE, LOCKPARENT
    353      1.22  wrstuden #
    354       1.1   mycroft vop_symlink {
    355      1.41   thorpej 	IN LOCKED=YES WILLPUT struct vnode *dvp;
    356      1.29     assar 	OUT struct vnode **vpp;
    357       1.1   mycroft 	IN struct componentname *cnp;
    358       1.1   mycroft 	IN struct vattr *vap;
    359       1.1   mycroft 	IN char *target;
    360       1.1   mycroft };
    361       1.1   mycroft 
    362      1.13      fvdl #
    363      1.13      fvdl #% readdir    vp      L L L   
    364      1.13      fvdl #
    365       1.1   mycroft vop_readdir {
    366      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    367       1.1   mycroft 	INOUT struct uio *uio;
    368       1.1   mycroft 	IN struct ucred *cred;
    369       1.1   mycroft 	OUT int *eofflag;
    370      1.13      fvdl 	OUT off_t **cookies;
    371      1.13      fvdl 	IN int *ncookies;
    372       1.1   mycroft };
    373       1.1   mycroft 
    374      1.13      fvdl #
    375      1.13      fvdl #% readlink   vp      L L L
    376      1.13      fvdl #
    377       1.1   mycroft vop_readlink {
    378      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    379       1.1   mycroft 	INOUT struct uio *uio;
    380       1.1   mycroft 	IN struct ucred *cred;
    381       1.1   mycroft };
    382       1.1   mycroft 
    383      1.13      fvdl #
    384      1.13      fvdl #% abortop    dvp     = = =
    385      1.13      fvdl #
    386      1.22  wrstuden #! abortop cnp	as appropriate.
    387      1.22  wrstuden #
    388       1.1   mycroft vop_abortop {
    389       1.1   mycroft 	IN struct vnode *dvp;
    390       1.1   mycroft 	IN struct componentname *cnp;
    391       1.1   mycroft };
    392       1.1   mycroft 
    393      1.13      fvdl #
    394      1.13      fvdl #% inactive   vp      L U U  
    395      1.13      fvdl #
    396       1.1   mycroft vop_inactive {
    397      1.41   thorpej 	IN LOCKED=YES WILLUNLOCK struct vnode *vp;
    398      1.35      fvdl 	IN struct proc *p;
    399       1.1   mycroft };
    400       1.1   mycroft 
    401      1.13      fvdl #
    402      1.13      fvdl #% reclaim    vp      U U U
    403      1.13      fvdl #
    404       1.1   mycroft vop_reclaim {
    405      1.41   thorpej 	IN LOCKED=NO struct vnode *vp;
    406      1.35      fvdl 	IN struct proc *p;
    407       1.1   mycroft };
    408       1.1   mycroft 
    409      1.13      fvdl #
    410      1.13      fvdl #% lock               vp      U L U
    411      1.13      fvdl #
    412       1.1   mycroft vop_lock {
    413      1.41   thorpej 	IN LOCKED=NO struct vnode *vp;
    414      1.13      fvdl 	IN int flags;
    415       1.1   mycroft };
    416       1.1   mycroft 
    417      1.13      fvdl #
    418      1.13      fvdl #% unlock     vp      L U L
    419      1.13      fvdl #
    420       1.1   mycroft vop_unlock {
    421      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    422      1.13      fvdl 	IN int flags;
    423       1.1   mycroft };
    424       1.1   mycroft 
    425      1.13      fvdl #
    426      1.40      yamt #% bmap               vp      = = =
    427      1.13      fvdl #% bmap               vpp     - U -
    428      1.13      fvdl #
    429       1.1   mycroft vop_bmap {
    430      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    431       1.1   mycroft 	IN daddr_t bn;
    432       1.1   mycroft 	OUT struct vnode **vpp;
    433       1.1   mycroft 	IN daddr_t *bnp;
    434       1.1   mycroft 	OUT int *runp;
    435       1.1   mycroft };
    436       1.1   mycroft 
    437      1.13      fvdl #
    438      1.38   hannken #% strategy   vp      = = =
    439      1.13      fvdl #
    440      1.38   hannken vop_strategy {
    441      1.38   hannken 	IN struct vnode *vp;
    442      1.38   hannken 	IN struct buf *bp;
    443      1.38   hannken };
    444       1.1   mycroft 
    445      1.13      fvdl #
    446      1.13      fvdl #% print      vp      = = =
    447      1.13      fvdl #
    448       1.1   mycroft vop_print {
    449       1.1   mycroft 	IN struct vnode *vp;
    450       1.1   mycroft };
    451       1.1   mycroft 
    452      1.13      fvdl #
    453      1.13      fvdl #% islocked   vp      = = =
    454      1.13      fvdl #
    455       1.1   mycroft vop_islocked {
    456       1.1   mycroft 	IN struct vnode *vp;
    457       1.1   mycroft };
    458       1.1   mycroft 
    459      1.13      fvdl #
    460      1.13      fvdl #% pathconf   vp      L L L
    461      1.13      fvdl #
    462       1.1   mycroft vop_pathconf {
    463      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    464       1.1   mycroft 	IN int name;
    465       1.3       cgd 	OUT register_t *retval;
    466       1.1   mycroft };
    467       1.1   mycroft 
    468      1.13      fvdl #
    469      1.13      fvdl #% advlock    vp      U U U
    470      1.13      fvdl #
    471       1.1   mycroft vop_advlock {
    472      1.41   thorpej 	IN LOCKED=NO struct vnode *vp;
    473      1.32  jdolecek 	IN void *id;
    474       1.1   mycroft 	IN int op;
    475       1.1   mycroft 	IN struct flock *fl;
    476       1.1   mycroft 	IN int flags;
    477       1.1   mycroft };
    478       1.1   mycroft 
    479      1.13      fvdl #
    480      1.13      fvdl #% blkatoff   vp      L L L
    481      1.13      fvdl #
    482       1.1   mycroft vop_blkatoff {
    483      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    484       1.1   mycroft 	IN off_t offset;
    485       1.1   mycroft 	OUT char **res;
    486       1.1   mycroft 	OUT struct buf **bpp;
    487       1.1   mycroft };
    488       1.1   mycroft 
    489      1.13      fvdl #
    490      1.13      fvdl #% valloc     pvp     L L L
    491      1.13      fvdl #
    492       1.1   mycroft vop_valloc {
    493      1.41   thorpej 	IN LOCKED=YES struct vnode *pvp;
    494       1.1   mycroft 	IN int mode;
    495       1.1   mycroft 	IN struct ucred *cred;
    496       1.1   mycroft 	OUT struct vnode **vpp;
    497       1.1   mycroft };
    498       1.1   mycroft 
    499      1.13      fvdl #
    500      1.21      fvdl #% balloc     vp      L L L
    501      1.21      fvdl #
    502      1.21      fvdl vop_balloc {
    503      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    504      1.21      fvdl 	IN off_t startoffset;
    505      1.21      fvdl 	IN int size;
    506      1.21      fvdl 	IN struct ucred *cred;	
    507      1.21      fvdl 	IN int flags;
    508      1.21      fvdl 	OUT struct buf **bpp;
    509      1.21      fvdl };
    510      1.21      fvdl 
    511      1.21      fvdl #
    512      1.13      fvdl #% reallocblks        vp      L L L
    513      1.13      fvdl #
    514       1.1   mycroft vop_reallocblks {
    515      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    516       1.1   mycroft 	IN struct cluster_save *buflist;
    517       1.1   mycroft };
    518       1.1   mycroft 
    519      1.13      fvdl #
    520      1.13      fvdl #% vfree      pvp     L L L
    521      1.13      fvdl #
    522       1.1   mycroft vop_vfree {
    523      1.41   thorpej 	IN LOCKED=YES struct vnode *pvp;
    524       1.1   mycroft 	IN ino_t ino;
    525       1.1   mycroft 	IN int mode;
    526       1.1   mycroft };
    527       1.1   mycroft 
    528      1.13      fvdl #
    529      1.13      fvdl #% truncate   vp      L L L
    530      1.13      fvdl #
    531       1.1   mycroft vop_truncate {
    532      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    533       1.1   mycroft 	IN off_t length;
    534       1.1   mycroft 	IN int flags;
    535       1.1   mycroft 	IN struct ucred *cred;
    536      1.35      fvdl 	IN struct proc *p;
    537       1.1   mycroft };
    538       1.1   mycroft 
    539      1.13      fvdl #
    540      1.13      fvdl #% update     vp      L L L
    541      1.13      fvdl #
    542       1.1   mycroft vop_update {
    543      1.41   thorpej 	IN LOCKED=YES struct vnode *vp;
    544      1.10   mycroft 	IN struct timespec *access;
    545      1.10   mycroft 	IN struct timespec *modify;
    546      1.24  perseant 	IN int flags;
    547       1.6   mycroft };
    548       1.6   mycroft 
    549      1.13      fvdl # 
    550      1.13      fvdl #% lease      vp      = = =
    551      1.13      fvdl # 
    552       1.6   mycroft vop_lease {
    553       1.6   mycroft 	IN struct vnode *vp;
    554      1.35      fvdl 	IN struct proc *p;
    555       1.6   mycroft 	IN struct ucred *cred;
    556       1.6   mycroft 	IN int flag;
    557       1.7   mycroft };
    558       1.7   mycroft 
    559      1.13      fvdl #
    560      1.13      fvdl #% whiteout   dvp     L L L
    561      1.13      fvdl #% whiteout   cnp     - - -
    562      1.13      fvdl #% whiteout   flag    - - -
    563      1.22  wrstuden #
    564      1.22  wrstuden #! whiteout cnp	CREATE, LOCKPARENT
    565      1.13      fvdl # 
    566       1.7   mycroft vop_whiteout {
    567      1.41   thorpej 	IN LOCKED=YES struct vnode *dvp;
    568       1.7   mycroft 	IN struct componentname *cnp;
    569       1.7   mycroft 	IN int flags;
    570       1.1   mycroft };
    571       1.1   mycroft 
    572      1.13      fvdl #
    573       1.1   mycroft # Needs work: no vp?
    574      1.13      fvdl #
    575       1.1   mycroft #vop_bwrite {
    576       1.1   mycroft #	IN struct buf *bp;
    577       1.1   mycroft #};
    578      1.26       chs 
    579      1.26       chs #
    580      1.39      yamt #% getpages	vp = = =
    581      1.26       chs #
    582      1.26       chs vop_getpages {
    583      1.26       chs 	IN struct vnode *vp;
    584      1.26       chs 	IN voff_t offset;
    585      1.27       chs 	IN struct vm_page **m;
    586      1.26       chs 	IN int *count;
    587      1.26       chs 	IN int centeridx;
    588      1.26       chs 	IN vm_prot_t access_type;
    589      1.26       chs 	IN int advice;
    590      1.26       chs 	IN int flags;
    591      1.26       chs };
    592      1.26       chs 
    593      1.26       chs #
    594      1.30       chs #% putpages	vp = = =
    595      1.26       chs #
    596      1.26       chs vop_putpages {
    597      1.26       chs 	IN struct vnode *vp;
    598      1.30       chs 	IN voff_t offlo;
    599      1.30       chs 	IN voff_t offhi;
    600      1.26       chs 	IN int flags;
    601      1.26       chs };
    602      1.42   thorpej 
    603      1.42   thorpej #
    604      1.42   thorpej #% closeextattr	vp L L L
    605      1.42   thorpej #
    606      1.42   thorpej vop_closeextattr {
    607      1.42   thorpej 	IN LOCKED=YES struct vnode *vp;
    608      1.42   thorpej 	IN int commit;
    609      1.42   thorpej 	IN struct ucred *cred;
    610      1.42   thorpej 	IN struct proc *p;
    611      1.42   thorpej };
    612      1.42   thorpej 
    613      1.42   thorpej #
    614      1.42   thorpej #% getextattr	vp L L L
    615      1.42   thorpej #
    616      1.42   thorpej vop_getextattr {
    617      1.42   thorpej 	IN LOCKED=YES struct vnode *vp;
    618      1.42   thorpej 	IN int attrnamespace;
    619      1.42   thorpej 	IN const char *name;
    620      1.42   thorpej 	INOUT struct uio *uio;
    621      1.42   thorpej 	OUT size_t *size;
    622      1.42   thorpej 	IN struct ucred *cred;
    623      1.42   thorpej 	IN struct proc *p;
    624      1.42   thorpej };
    625      1.42   thorpej 
    626      1.42   thorpej #
    627      1.42   thorpej #% listextattr	vp L L L
    628      1.42   thorpej #
    629      1.42   thorpej vop_listextattr {
    630      1.42   thorpej 	IN LOCKED=YES struct vnode *vp;
    631      1.42   thorpej 	IN int attrnamespace;
    632      1.42   thorpej 	INOUT struct uio *uio;
    633      1.42   thorpej 	OUT size_t *size;
    634      1.42   thorpej 	IN struct ucred *cred;
    635      1.42   thorpej 	IN struct proc *p;
    636      1.42   thorpej };
    637      1.42   thorpej 
    638      1.42   thorpej #
    639      1.42   thorpej #% openextattr	vp L L L
    640      1.42   thorpej #
    641      1.42   thorpej vop_openextattr {
    642      1.42   thorpej 	IN LOCKED=YES struct vnode *vp;
    643      1.42   thorpej 	IN struct ucred *cred;
    644      1.42   thorpej 	IN struct proc *p;
    645      1.42   thorpej };
    646      1.42   thorpej 
    647      1.42   thorpej #
    648      1.42   thorpej #% deleteextattr vp L L L
    649      1.42   thorpej #
    650      1.42   thorpej vop_deleteextattr {
    651      1.42   thorpej 	IN LOCKED=YES struct vnode *vp;
    652      1.42   thorpej 	IN int attrnamespace;
    653      1.42   thorpej 	IN const char *name;
    654      1.42   thorpej 	IN struct ucred *cred;
    655      1.42   thorpej 	IN struct proc *p;
    656      1.42   thorpej };
    657      1.42   thorpej 
    658      1.42   thorpej #
    659      1.42   thorpej #% setextattr	vp L L L
    660      1.42   thorpej #
    661      1.42   thorpej vop_setextattr {
    662      1.42   thorpej 	IN LOCKED=YES struct vnode *vp;
    663      1.42   thorpej 	IN int attrnamespace;
    664      1.42   thorpej 	IN const char *name;
    665      1.42   thorpej 	INOUT struct uio *uio;
    666      1.42   thorpej 	IN struct ucred *cred;
    667      1.42   thorpej 	IN struct proc *p;
    668      1.42   thorpej };
    669