3 * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
5 * @APPLE_LICENSE_HEADER_START@
7 * The contents of this file constitute Original Code as defined in and
8 * are subject to the Apple Public Source License Version 1.1 (the
9 * "License"). You may not use this file except in compliance with the
10 * License. Please obtain a copy of the License at
11 * http://www.apple.com/publicsource and read it before using this file.
13 * This Original Code and all software distributed under the License are
14 * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
15 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
16 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
18 * License for the specific language governing rights and limitations
21 * @APPLE_LICENSE_HEADER_END@
24 * Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved
25 * Copyright (c) 1992, 1993, 1994, 1995
26 * The Regents of the University of California. All rights reserved.
28 * Redistribution and use in source and binary forms, with or without
29 * modification, are permitted provided that the following conditions
31 * 1. Redistributions of source code must retain the above copyright
32 * notice, this list of conditions and the following disclaimer.
33 * 2. Redistributions in binary form must reproduce the above copyright
34 * notice, this list of conditions and the following disclaimer in the
35 * documentation and/or other materials provided with the distribution.
36 * 3. All advertising materials mentioning features or use of this software
37 * must display the following acknowledgement:
38 * This product includes software developed by the University of
39 * California, Berkeley and its contributors.
40 * 4. Neither the name of the University nor the names of its contributors
41 * may be used to endorse or promote products derived from this software
42 * without specific prior written permission.
44 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS AND
45 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
46 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
47 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
48 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
49 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
50 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
51 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
52 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
53 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
59 * Warning: This file is generated automatically.
60 * (Modifications made here may easily be lost!)
62 * Created by the script:
63 * @(#)vnode_if.sh 8.7 (Berkeley) 5/11/95
70 extern struct vnodeop_desc vop_default_desc
;
73 struct vop_lookup_args
{
74 struct vnodeop_desc
*a_desc
;
77 struct componentname
*a_cnp
;
79 extern struct vnodeop_desc vop_lookup_desc
;
80 #define VOP_LOOKUP(dvp, vpp, cnp) _VOP_LOOKUP(dvp, vpp, cnp)
81 static __inline
int _VOP_LOOKUP(struct vnode
*dvp
, struct vnode
**vpp
, struct componentname
*cnp
)
83 struct vop_lookup_args a
;
84 a
.a_desc
= VDESC(vop_lookup
);
88 return (VCALL(dvp
, VOFFSET(vop_lookup
), &a
));
91 struct vop_cachedlookup_args
{
92 struct vnodeop_desc
*a_desc
;
95 struct componentname
*a_cnp
;
97 extern struct vnodeop_desc vop_cachedlookup_desc
;
98 #define VOP_CACHEDLOOKUP(dvp, vpp, cnp) _VOP_CACHEDLOOKUP(dvp, vpp, cnp)
99 static __inline
int _VOP_CACHEDLOOKUP(struct vnode
*dvp
, struct vnode
**vpp
, struct componentname
*cnp
)
101 struct vop_cachedlookup_args a
;
102 a
.a_desc
= VDESC(vop_cachedlookup
);
106 return (VCALL(dvp
, VOFFSET(vop_cachedlookup
), &a
));
109 struct vop_create_args
{
110 struct vnodeop_desc
*a_desc
;
112 struct vnode
**a_vpp
;
113 struct componentname
*a_cnp
;
116 extern struct vnodeop_desc vop_create_desc
;
117 #define VOP_CREATE(dvp, vpp, cnp, vap) _VOP_CREATE(dvp, vpp, cnp, vap)
118 static __inline
int _VOP_CREATE(struct vnode
*dvp
, struct vnode
**vpp
, struct componentname
*cnp
, struct vattr
*vap
)
120 struct vop_create_args a
;
121 a
.a_desc
= VDESC(vop_create
);
126 return (VCALL(dvp
, VOFFSET(vop_create
), &a
));
129 struct vop_whiteout_args
{
130 struct vnodeop_desc
*a_desc
;
132 struct componentname
*a_cnp
;
135 extern struct vnodeop_desc vop_whiteout_desc
;
136 #define VOP_WHITEOUT(dvp, cnp, flags) _VOP_WHITEOUT(dvp, cnp, flags)
137 static __inline
int _VOP_WHITEOUT(struct vnode
*dvp
, struct componentname
*cnp
, int flags
)
139 struct vop_whiteout_args a
;
140 a
.a_desc
= VDESC(vop_whiteout
);
144 return (VCALL(dvp
, VOFFSET(vop_whiteout
), &a
));
147 struct vop_mknod_args
{
148 struct vnodeop_desc
*a_desc
;
150 struct vnode
**a_vpp
;
151 struct componentname
*a_cnp
;
154 extern struct vnodeop_desc vop_mknod_desc
;
155 #define VOP_MKNOD(dvp, vpp, cnp, vap) _VOP_MKNOD(dvp, vpp, cnp, vap)
156 static __inline
int _VOP_MKNOD(struct vnode
*dvp
, struct vnode
**vpp
, struct componentname
*cnp
, struct vattr
*vap
)
158 struct vop_mknod_args a
;
159 a
.a_desc
= VDESC(vop_mknod
);
164 return (VCALL(dvp
, VOFFSET(vop_mknod
), &a
));
167 struct vop_mkcomplex_args
{
168 struct vnodeop_desc
*a_desc
;
170 struct vnode
**a_vpp
;
171 struct componentname
*a_cnp
;
175 extern struct vnodeop_desc vop_mkcomplex_desc
;
176 #define VOP_MKCOMPLEX(dvp, vpp, cnp, vap, type) _VOP_MKCOMPLEX(dvp, vpp, cnp, vap, type)
177 static __inline
int _VOP_MKCOMPLEX(struct vnode
*dvp
, struct vnode
**vpp
, struct componentname
*cnp
, struct vattr
*vap
, u_long type
)
179 struct vop_mkcomplex_args a
;
180 a
.a_desc
= VDESC(vop_mkcomplex
);
186 return (VCALL(dvp
, VOFFSET(vop_mkcomplex
), &a
));
189 struct vop_open_args
{
190 struct vnodeop_desc
*a_desc
;
193 struct ucred
*a_cred
;
196 extern struct vnodeop_desc vop_open_desc
;
197 #define VOP_OPEN(vp, mode, cred, p) _VOP_OPEN(vp, mode, cred, p)
198 static __inline
int _VOP_OPEN(struct vnode
*vp
, int mode
, struct ucred
*cred
, struct proc
*p
)
200 struct vop_open_args a
;
201 a
.a_desc
= VDESC(vop_open
);
206 return (VCALL(vp
, VOFFSET(vop_open
), &a
));
209 struct vop_close_args
{
210 struct vnodeop_desc
*a_desc
;
213 struct ucred
*a_cred
;
216 extern struct vnodeop_desc vop_close_desc
;
217 #define VOP_CLOSE(vp, fflag, cred, p) _VOP_CLOSE(vp, fflag, cred, p)
218 static __inline
int _VOP_CLOSE(struct vnode
*vp
, int fflag
, struct ucred
*cred
, struct proc
*p
)
220 struct vop_close_args a
;
221 a
.a_desc
= VDESC(vop_close
);
226 return (VCALL(vp
, VOFFSET(vop_close
), &a
));
229 struct vop_access_args
{
230 struct vnodeop_desc
*a_desc
;
233 struct ucred
*a_cred
;
236 extern struct vnodeop_desc vop_access_desc
;
237 #define VOP_ACCESS(vp, mode, cred, p) _VOP_ACCESS(vp, mode, cred, p)
238 static __inline
int _VOP_ACCESS(struct vnode
*vp
, int mode
, struct ucred
*cred
, struct proc
*p
)
240 struct vop_access_args a
;
241 a
.a_desc
= VDESC(vop_access
);
246 return (VCALL(vp
, VOFFSET(vop_access
), &a
));
249 struct vop_getattr_args
{
250 struct vnodeop_desc
*a_desc
;
253 struct ucred
*a_cred
;
256 extern struct vnodeop_desc vop_getattr_desc
;
257 #define VOP_GETATTR(vp, vap, cred, p) _VOP_GETATTR(vp, vap, cred, p)
258 static __inline
int _VOP_GETATTR(struct vnode
*vp
, struct vattr
*vap
, struct ucred
*cred
, struct proc
*p
)
260 struct vop_getattr_args a
;
261 a
.a_desc
= VDESC(vop_getattr
);
266 return (VCALL(vp
, VOFFSET(vop_getattr
), &a
));
269 struct vop_setattr_args
{
270 struct vnodeop_desc
*a_desc
;
273 struct ucred
*a_cred
;
276 extern struct vnodeop_desc vop_setattr_desc
;
277 #define VOP_SETATTR(vp, vap, cred, p) _VOP_SETATTR(vp, vap, cred, p)
278 static __inline
int _VOP_SETATTR(struct vnode
*vp
, struct vattr
*vap
, struct ucred
*cred
, struct proc
*p
)
280 struct vop_setattr_args a
;
281 a
.a_desc
= VDESC(vop_setattr
);
286 return (VCALL(vp
, VOFFSET(vop_setattr
), &a
));
289 struct vop_getattrlist_args
{
290 struct vnodeop_desc
*a_desc
;
292 struct attrlist
*a_alist
;
294 struct ucred
*a_cred
;
297 extern struct vnodeop_desc vop_getattrlist_desc
;
298 #define VOP_GETATTRLIST(vp, alist, uio, cred, p) _VOP_GETATTRLIST(vp, alist, uio, cred, p)
299 static __inline
int _VOP_GETATTRLIST(struct vnode
*vp
, struct attrlist
*alist
, struct uio
*uio
, struct ucred
*cred
, struct proc
*p
)
301 struct vop_getattrlist_args a
;
302 a
.a_desc
= VDESC(vop_getattrlist
);
308 return (VCALL(vp
, VOFFSET(vop_getattrlist
), &a
));
311 struct vop_setattrlist_args
{
312 struct vnodeop_desc
*a_desc
;
314 struct attrlist
*a_alist
;
316 struct ucred
*a_cred
;
319 extern struct vnodeop_desc vop_setattrlist_desc
;
320 #define VOP_SETATTRLIST(vp, alist, uio, cred, p) _VOP_SETATTRLIST(vp, alist, uio, cred, p)
321 static __inline
int _VOP_SETATTRLIST(struct vnode
*vp
, struct attrlist
*alist
, struct uio
*uio
, struct ucred
*cred
, struct proc
*p
)
323 struct vop_setattrlist_args a
;
324 a
.a_desc
= VDESC(vop_setattrlist
);
330 return (VCALL(vp
, VOFFSET(vop_setattrlist
), &a
));
333 struct vop_read_args
{
334 struct vnodeop_desc
*a_desc
;
338 struct ucred
*a_cred
;
340 extern struct vnodeop_desc vop_read_desc
;
341 #define VOP_READ(vp, uio, ioflag, cred) _VOP_READ(vp, uio, ioflag, cred)
342 static __inline
int _VOP_READ(struct vnode
*vp
, struct uio
*uio
, int ioflag
, struct ucred
*cred
)
344 struct vop_read_args a
;
345 a
.a_desc
= VDESC(vop_read
);
352 extern int ubc_hold();
353 extern void ubc_rele();
354 int _didhold
= ubc_hold(vp
);
355 _err
= VCALL(vp
, VOFFSET(vop_read
), &a
);
362 struct vop_write_args
{
363 struct vnodeop_desc
*a_desc
;
367 struct ucred
*a_cred
;
369 extern struct vnodeop_desc vop_write_desc
;
370 #define VOP_WRITE(vp, uio, ioflag, cred) _VOP_WRITE(vp, uio, ioflag, cred)
371 static __inline
int _VOP_WRITE(struct vnode
*vp
, struct uio
*uio
, int ioflag
, struct ucred
*cred
)
373 struct vop_write_args a
;
374 a
.a_desc
= VDESC(vop_write
);
381 extern int ubc_hold();
382 extern void ubc_rele();
383 int _didhold
= ubc_hold(vp
);
384 _err
= VCALL(vp
, VOFFSET(vop_write
), &a
);
391 struct vop_lease_args
{
392 struct vnodeop_desc
*a_desc
;
395 struct ucred
*a_cred
;
398 extern struct vnodeop_desc vop_lease_desc
;
399 #define VOP_LEASE(vp, p, cred, flag) _VOP_LEASE(vp, p, cred, flag)
400 static __inline
int _VOP_LEASE(struct vnode
*vp
, struct proc
*p
, struct ucred
*cred
, int flag
)
402 struct vop_lease_args a
;
403 a
.a_desc
= VDESC(vop_lease
);
408 return (VCALL(vp
, VOFFSET(vop_lease
), &a
));
411 struct vop_ioctl_args
{
412 struct vnodeop_desc
*a_desc
;
417 struct ucred
*a_cred
;
420 extern struct vnodeop_desc vop_ioctl_desc
;
421 #define VOP_IOCTL(vp, command, data, fflag, cred, p) _VOP_IOCTL(vp, command, data, fflag, cred, p)
422 static __inline
int _VOP_IOCTL(struct vnode
*vp
, u_long command
, caddr_t data
, int fflag
, struct ucred
*cred
, struct proc
*p
)
424 struct vop_ioctl_args a
;
425 a
.a_desc
= VDESC(vop_ioctl
);
427 a
.a_command
= command
;
432 return (VCALL(vp
, VOFFSET(vop_ioctl
), &a
));
435 struct vop_select_args
{
436 struct vnodeop_desc
*a_desc
;
440 struct ucred
*a_cred
;
444 extern struct vnodeop_desc vop_select_desc
;
445 #define VOP_SELECT(vp, which, fflags, cred, wql, p) _VOP_SELECT(vp, which, fflags, cred, wql, p)
446 static __inline
int _VOP_SELECT(struct vnode
*vp
, int which
, int fflags
, struct ucred
*cred
, void * wql
, struct proc
*p
)
448 struct vop_select_args a
;
449 a
.a_desc
= VDESC(vop_select
);
456 return (VCALL(vp
, VOFFSET(vop_select
), &a
));
459 struct vop_exchange_args
{
460 struct vnodeop_desc
*a_desc
;
463 struct ucred
*a_cred
;
466 extern struct vnodeop_desc vop_exchange_desc
;
467 #define VOP_EXCHANGE(fvp, tvp, cred, p) _VOP_EXCHANGE(fvp, tvp, cred, p)
468 static __inline
int _VOP_EXCHANGE(struct vnode
*fvp
, struct vnode
*tvp
, struct ucred
*cred
, struct proc
*p
)
470 struct vop_exchange_args a
;
471 a
.a_desc
= VDESC(vop_exchange
);
476 return (VCALL(fvp
, VOFFSET(vop_exchange
), &a
));
479 struct vop_revoke_args
{
480 struct vnodeop_desc
*a_desc
;
484 extern struct vnodeop_desc vop_revoke_desc
;
485 #define VOP_REVOKE(vp, flags) _VOP_REVOKE(vp, flags)
486 static __inline
int _VOP_REVOKE(struct vnode
*vp
, int flags
)
488 struct vop_revoke_args a
;
489 a
.a_desc
= VDESC(vop_revoke
);
492 return (VCALL(vp
, VOFFSET(vop_revoke
), &a
));
495 struct vop_mmap_args
{
496 struct vnodeop_desc
*a_desc
;
499 struct ucred
*a_cred
;
502 extern struct vnodeop_desc vop_mmap_desc
;
503 #define VOP_MMAP(vp, fflags, cred, p) _VOP_MMAP(vp, fflags, cred, p)
504 static __inline
int _VOP_MMAP(struct vnode
*vp
, int fflags
, struct ucred
*cred
, struct proc
*p
)
506 struct vop_mmap_args a
;
507 a
.a_desc
= VDESC(vop_mmap
);
512 return (VCALL(vp
, VOFFSET(vop_mmap
), &a
));
515 struct vop_fsync_args
{
516 struct vnodeop_desc
*a_desc
;
518 struct ucred
*a_cred
;
522 extern struct vnodeop_desc vop_fsync_desc
;
523 #define VOP_FSYNC(vp, cred, waitfor, p) _VOP_FSYNC(vp, cred, waitfor, p)
524 static __inline
int _VOP_FSYNC(struct vnode
*vp
, struct ucred
*cred
, int waitfor
, struct proc
*p
)
526 struct vop_fsync_args a
;
527 a
.a_desc
= VDESC(vop_fsync
);
530 a
.a_waitfor
= waitfor
;
534 extern int ubc_hold();
535 extern void ubc_rele();
536 int _didhold
= ubc_hold(vp
);
537 _err
= VCALL(vp
, VOFFSET(vop_fsync
), &a
);
544 struct vop_seek_args
{
545 struct vnodeop_desc
*a_desc
;
549 struct ucred
*a_cred
;
551 extern struct vnodeop_desc vop_seek_desc
;
552 #define VOP_SEEK(vp, oldoff, newoff, cred) _VOP_SEEK(vp, oldoff, newoff, cred)
553 static __inline
int _VOP_SEEK(struct vnode
*vp
, off_t oldoff
, off_t newoff
, struct ucred
*cred
)
555 struct vop_seek_args a
;
556 a
.a_desc
= VDESC(vop_seek
);
561 return (VCALL(vp
, VOFFSET(vop_seek
), &a
));
564 struct vop_remove_args
{
565 struct vnodeop_desc
*a_desc
;
568 struct componentname
*a_cnp
;
570 extern struct vnodeop_desc vop_remove_desc
;
571 #define VOP_REMOVE(dvp, vp, cnp) _VOP_REMOVE(dvp, vp, cnp)
572 static __inline
int _VOP_REMOVE(struct vnode
*dvp
, struct vnode
*vp
, struct componentname
*cnp
)
574 struct vop_remove_args a
;
575 a
.a_desc
= VDESC(vop_remove
);
579 return (VCALL(dvp
, VOFFSET(vop_remove
), &a
));
582 struct vop_link_args
{
583 struct vnodeop_desc
*a_desc
;
585 struct vnode
*a_tdvp
;
586 struct componentname
*a_cnp
;
588 extern struct vnodeop_desc vop_link_desc
;
589 #define VOP_LINK(vp, tdvp, cnp) _VOP_LINK(vp, tdvp, cnp)
590 static __inline
int _VOP_LINK(struct vnode
*vp
, struct vnode
*tdvp
, struct componentname
*cnp
)
592 struct vop_link_args a
;
593 a
.a_desc
= VDESC(vop_link
);
597 return (VCALL(vp
, VOFFSET(vop_link
), &a
));
600 struct vop_rename_args
{
601 struct vnodeop_desc
*a_desc
;
602 struct vnode
*a_fdvp
;
604 struct componentname
*a_fcnp
;
605 struct vnode
*a_tdvp
;
607 struct componentname
*a_tcnp
;
609 extern struct vnodeop_desc vop_rename_desc
;
610 #define VOP_RENAME(fdvp, fvp, fcnp, tdvp, tvp, tcnp) _VOP_RENAME(fdvp, fvp, fcnp, tdvp, tvp, tcnp)
611 static __inline
int _VOP_RENAME(struct vnode
*fdvp
, struct vnode
*fvp
, struct componentname
*fcnp
, struct vnode
*tdvp
, struct vnode
*tvp
, struct componentname
*tcnp
)
613 struct vop_rename_args a
;
614 a
.a_desc
= VDESC(vop_rename
);
621 return (VCALL(fdvp
, VOFFSET(vop_rename
), &a
));
624 struct vop_mkdir_args
{
625 struct vnodeop_desc
*a_desc
;
627 struct vnode
**a_vpp
;
628 struct componentname
*a_cnp
;
631 extern struct vnodeop_desc vop_mkdir_desc
;
632 #define VOP_MKDIR(dvp, vpp, cnp, vap) _VOP_MKDIR(dvp, vpp, cnp, vap)
633 static __inline
int _VOP_MKDIR(struct vnode
*dvp
, struct vnode
**vpp
, struct componentname
*cnp
, struct vattr
*vap
)
635 struct vop_mkdir_args a
;
636 a
.a_desc
= VDESC(vop_mkdir
);
641 return (VCALL(dvp
, VOFFSET(vop_mkdir
), &a
));
644 struct vop_rmdir_args
{
645 struct vnodeop_desc
*a_desc
;
648 struct componentname
*a_cnp
;
650 extern struct vnodeop_desc vop_rmdir_desc
;
651 #define VOP_RMDIR(dvp, vp, cnp) _VOP_RMDIR(dvp, vp, cnp)
652 static __inline
int _VOP_RMDIR(struct vnode
*dvp
, struct vnode
*vp
, struct componentname
*cnp
)
654 struct vop_rmdir_args a
;
655 a
.a_desc
= VDESC(vop_rmdir
);
659 return (VCALL(dvp
, VOFFSET(vop_rmdir
), &a
));
662 struct vop_symlink_args
{
663 struct vnodeop_desc
*a_desc
;
665 struct vnode
**a_vpp
;
666 struct componentname
*a_cnp
;
670 extern struct vnodeop_desc vop_symlink_desc
;
671 #define VOP_SYMLINK(dvp, vpp, cnp, vap, target) _VOP_SYMLINK(dvp, vpp, cnp, vap, target)
672 static __inline
int _VOP_SYMLINK(struct vnode
*dvp
, struct vnode
**vpp
, struct componentname
*cnp
, struct vattr
*vap
, char *target
)
674 struct vop_symlink_args a
;
675 a
.a_desc
= VDESC(vop_symlink
);
681 return (VCALL(dvp
, VOFFSET(vop_symlink
), &a
));
684 struct vop_readdir_args
{
685 struct vnodeop_desc
*a_desc
;
688 struct ucred
*a_cred
;
693 extern struct vnodeop_desc vop_readdir_desc
;
694 #define VOP_READDIR(vp, uio, cred, eofflag, ncookies, cookies) _VOP_READDIR(vp, uio, cred, eofflag, ncookies, cookies)
695 static __inline
int _VOP_READDIR(struct vnode
*vp
, struct uio
*uio
, struct ucred
*cred
, int *eofflag
, int *ncookies
, u_long
**cookies
)
697 struct vop_readdir_args a
;
698 a
.a_desc
= VDESC(vop_readdir
);
702 a
.a_eofflag
= eofflag
;
703 a
.a_ncookies
= ncookies
;
704 a
.a_cookies
= cookies
;
705 return (VCALL(vp
, VOFFSET(vop_readdir
), &a
));
708 struct vop_readdirattr_args
{
709 struct vnodeop_desc
*a_desc
;
711 struct attrlist
*a_alist
;
717 u_long
*a_actualcount
;
719 struct ucred
*a_cred
;
721 extern struct vnodeop_desc vop_readdirattr_desc
;
722 #define VOP_READDIRATTR(vp, alist, uio, maxcount, options, newstate, eofflag, actualcount, cookies, cred) _VOP_READDIRATTR(vp, alist, uio, maxcount, options, newstate, eofflag, actualcount, cookies, cred)
723 static __inline
int _VOP_READDIRATTR(struct vnode
*vp
, struct attrlist
*alist
, struct uio
*uio
, u_long maxcount
, u_long options
, u_long
*newstate
, int *eofflag
, u_long
*actualcount
, u_long
**cookies
, struct ucred
*cred
)
725 struct vop_readdirattr_args a
;
726 a
.a_desc
= VDESC(vop_readdirattr
);
730 a
.a_maxcount
= maxcount
;
731 a
.a_options
= options
;
732 a
.a_newstate
= newstate
;
733 a
.a_eofflag
= eofflag
;
734 a
.a_actualcount
= actualcount
;
735 a
.a_cookies
= cookies
;
737 return (VCALL(vp
, VOFFSET(vop_readdirattr
), &a
));
740 struct vop_readlink_args
{
741 struct vnodeop_desc
*a_desc
;
744 struct ucred
*a_cred
;
746 extern struct vnodeop_desc vop_readlink_desc
;
747 #define VOP_READLINK(vp, uio, cred) _VOP_READLINK(vp, uio, cred)
748 static __inline
int _VOP_READLINK(struct vnode
*vp
, struct uio
*uio
, struct ucred
*cred
)
750 struct vop_readlink_args a
;
751 a
.a_desc
= VDESC(vop_readlink
);
755 return (VCALL(vp
, VOFFSET(vop_readlink
), &a
));
758 struct vop_abortop_args
{
759 struct vnodeop_desc
*a_desc
;
761 struct componentname
*a_cnp
;
763 extern struct vnodeop_desc vop_abortop_desc
;
764 #define VOP_ABORTOP(dvp, cnp) _VOP_ABORTOP(dvp, cnp)
765 static __inline
int _VOP_ABORTOP(struct vnode
*dvp
, struct componentname
*cnp
)
767 struct vop_abortop_args a
;
768 a
.a_desc
= VDESC(vop_abortop
);
771 return (VCALL(dvp
, VOFFSET(vop_abortop
), &a
));
774 struct vop_inactive_args
{
775 struct vnodeop_desc
*a_desc
;
779 extern struct vnodeop_desc vop_inactive_desc
;
780 #define VOP_INACTIVE(vp, p) _VOP_INACTIVE(vp, p)
781 static __inline
int _VOP_INACTIVE(struct vnode
*vp
, struct proc
*p
)
783 struct vop_inactive_args a
;
784 a
.a_desc
= VDESC(vop_inactive
);
787 return (VCALL(vp
, VOFFSET(vop_inactive
), &a
));
790 struct vop_reclaim_args
{
791 struct vnodeop_desc
*a_desc
;
795 extern struct vnodeop_desc vop_reclaim_desc
;
796 #define VOP_RECLAIM(vp, p) _VOP_RECLAIM(vp, p)
797 static __inline
int _VOP_RECLAIM(struct vnode
*vp
, struct proc
*p
)
799 struct vop_reclaim_args a
;
800 a
.a_desc
= VDESC(vop_reclaim
);
803 return (VCALL(vp
, VOFFSET(vop_reclaim
), &a
));
806 struct vop_lock_args
{
807 struct vnodeop_desc
*a_desc
;
812 extern struct vnodeop_desc vop_lock_desc
;
813 #define VOP_LOCK(vp, flags, p) _VOP_LOCK(vp, flags, p)
814 static __inline
int _VOP_LOCK(struct vnode
*vp
, int flags
, struct proc
*p
)
816 struct vop_lock_args a
;
817 a
.a_desc
= VDESC(vop_lock
);
821 return (VCALL(vp
, VOFFSET(vop_lock
), &a
));
824 struct vop_unlock_args
{
825 struct vnodeop_desc
*a_desc
;
830 extern struct vnodeop_desc vop_unlock_desc
;
831 #define VOP_UNLOCK(vp, flags, p) _VOP_UNLOCK(vp, flags, p)
832 static __inline
int _VOP_UNLOCK(struct vnode
*vp
, int flags
, struct proc
*p
)
834 struct vop_unlock_args a
;
835 a
.a_desc
= VDESC(vop_unlock
);
839 return (VCALL(vp
, VOFFSET(vop_unlock
), &a
));
842 struct vop_bmap_args
{
843 struct vnodeop_desc
*a_desc
;
846 struct vnode
**a_vpp
;
850 extern struct vnodeop_desc vop_bmap_desc
;
851 #define VOP_BMAP(vp, bn, vpp, bnp, runp) _VOP_BMAP(vp, bn, vpp, bnp, runp)
852 static __inline
int _VOP_BMAP(struct vnode
*vp
, daddr_t bn
, struct vnode
**vpp
, daddr_t
*bnp
, int *runp
)
854 struct vop_bmap_args a
;
855 a
.a_desc
= VDESC(vop_bmap
);
861 return (VCALL(vp
, VOFFSET(vop_bmap
), &a
));
864 struct vop_print_args
{
865 struct vnodeop_desc
*a_desc
;
868 extern struct vnodeop_desc vop_print_desc
;
869 #define VOP_PRINT(vp) _VOP_PRINT(vp)
870 static __inline
int _VOP_PRINT(struct vnode
*vp
)
872 struct vop_print_args a
;
873 a
.a_desc
= VDESC(vop_print
);
875 return (VCALL(vp
, VOFFSET(vop_print
), &a
));
878 struct vop_islocked_args
{
879 struct vnodeop_desc
*a_desc
;
882 extern struct vnodeop_desc vop_islocked_desc
;
883 #define VOP_ISLOCKED(vp) _VOP_ISLOCKED(vp)
884 static __inline
int _VOP_ISLOCKED(struct vnode
*vp
)
886 struct vop_islocked_args a
;
887 a
.a_desc
= VDESC(vop_islocked
);
889 return (VCALL(vp
, VOFFSET(vop_islocked
), &a
));
892 struct vop_pathconf_args
{
893 struct vnodeop_desc
*a_desc
;
896 register_t
*a_retval
;
898 extern struct vnodeop_desc vop_pathconf_desc
;
899 #define VOP_PATHCONF(vp, name, retval) _VOP_PATHCONF(vp, name, retval)
900 static __inline
int _VOP_PATHCONF(struct vnode
*vp
, int name
, register_t
*retval
)
902 struct vop_pathconf_args a
;
903 a
.a_desc
= VDESC(vop_pathconf
);
907 return (VCALL(vp
, VOFFSET(vop_pathconf
), &a
));
910 struct vop_advlock_args
{
911 struct vnodeop_desc
*a_desc
;
918 extern struct vnodeop_desc vop_advlock_desc
;
919 #define VOP_ADVLOCK(vp, id, op, fl, flags) _VOP_ADVLOCK(vp, id, op, fl, flags)
920 static __inline
int _VOP_ADVLOCK(struct vnode
*vp
, caddr_t id
, int op
, struct flock
*fl
, int flags
)
922 struct vop_advlock_args a
;
923 a
.a_desc
= VDESC(vop_advlock
);
929 return (VCALL(vp
, VOFFSET(vop_advlock
), &a
));
932 struct vop_blkatoff_args
{
933 struct vnodeop_desc
*a_desc
;
939 extern struct vnodeop_desc vop_blkatoff_desc
;
940 #define VOP_BLKATOFF(vp, offset, res, bpp) _VOP_BLKATOFF(vp, offset, res, bpp)
941 static __inline
int _VOP_BLKATOFF(struct vnode
*vp
, off_t offset
, char **res
, struct buf
**bpp
)
943 struct vop_blkatoff_args a
;
944 a
.a_desc
= VDESC(vop_blkatoff
);
949 return (VCALL(vp
, VOFFSET(vop_blkatoff
), &a
));
952 struct vop_valloc_args
{
953 struct vnodeop_desc
*a_desc
;
956 struct ucred
*a_cred
;
957 struct vnode
**a_vpp
;
959 extern struct vnodeop_desc vop_valloc_desc
;
960 #define VOP_VALLOC(pvp, mode, cred, vpp) _VOP_VALLOC(pvp, mode, cred, vpp)
961 static __inline
int _VOP_VALLOC(struct vnode
*pvp
, int mode
, struct ucred
*cred
, struct vnode
**vpp
)
963 struct vop_valloc_args a
;
964 a
.a_desc
= VDESC(vop_valloc
);
969 return (VCALL(pvp
, VOFFSET(vop_valloc
), &a
));
972 struct vop_reallocblks_args
{
973 struct vnodeop_desc
*a_desc
;
975 struct cluster_save
*a_buflist
;
977 extern struct vnodeop_desc vop_reallocblks_desc
;
978 #define VOP_REALLOCBLKS(vp, buflist) _VOP_REALLOCBLKS(vp, buflist)
979 static __inline
int _VOP_REALLOCBLKS(struct vnode
*vp
, struct cluster_save
*buflist
)
981 struct vop_reallocblks_args a
;
982 a
.a_desc
= VDESC(vop_reallocblks
);
984 a
.a_buflist
= buflist
;
985 return (VCALL(vp
, VOFFSET(vop_reallocblks
), &a
));
988 struct vop_vfree_args
{
989 struct vnodeop_desc
*a_desc
;
994 extern struct vnodeop_desc vop_vfree_desc
;
995 #define VOP_VFREE(pvp, ino, mode) _VOP_VFREE(pvp, ino, mode)
996 static __inline
int _VOP_VFREE(struct vnode
*pvp
, ino_t ino
, int mode
)
998 struct vop_vfree_args a
;
999 a
.a_desc
= VDESC(vop_vfree
);
1003 return (VCALL(pvp
, VOFFSET(vop_vfree
), &a
));
1006 struct vop_truncate_args
{
1007 struct vnodeop_desc
*a_desc
;
1011 struct ucred
*a_cred
;
1014 extern struct vnodeop_desc vop_truncate_desc
;
1015 #define VOP_TRUNCATE(vp, length, flags, cred, p) _VOP_TRUNCATE(vp, length, flags, cred, p)
1016 static __inline
int _VOP_TRUNCATE(struct vnode
*vp
, off_t length
, int flags
, struct ucred
*cred
, struct proc
*p
)
1018 struct vop_truncate_args a
;
1019 a
.a_desc
= VDESC(vop_truncate
);
1021 a
.a_length
= length
;
1027 extern int ubc_hold();
1028 extern void ubc_rele();
1029 int _didhold
= ubc_hold(vp
);
1030 _err
= VCALL(vp
, VOFFSET(vop_truncate
), &a
);
1037 struct vop_allocate_args
{
1038 struct vnodeop_desc
*a_desc
;
1042 off_t
*a_bytesallocated
;
1044 struct ucred
*a_cred
;
1047 extern struct vnodeop_desc vop_allocate_desc
;
1048 #define VOP_ALLOCATE(vp, length, flags, bytesallocated, offset, cred, p) _VOP_ALLOCATE(vp, length, flags, bytesallocated, offset, cred, p)
1049 static __inline
int _VOP_ALLOCATE(struct vnode
*vp
, off_t length
, u_int32_t flags
, off_t
*bytesallocated
, off_t offset
, struct ucred
*cred
, struct proc
*p
)
1051 struct vop_allocate_args a
;
1052 a
.a_desc
= VDESC(vop_allocate
);
1054 a
.a_length
= length
;
1056 a
.a_bytesallocated
= bytesallocated
;
1057 a
.a_offset
= offset
;
1060 return (VCALL(vp
, VOFFSET(vop_allocate
), &a
));
1063 struct vop_update_args
{
1064 struct vnodeop_desc
*a_desc
;
1066 struct timeval
*a_access
;
1067 struct timeval
*a_modify
;
1070 extern struct vnodeop_desc vop_update_desc
;
1071 #define VOP_UPDATE(vp, access, modify, waitfor) _VOP_UPDATE(vp, access, modify, waitfor)
1072 static __inline
int _VOP_UPDATE(struct vnode
*vp
, struct timeval
*access
, struct timeval
*modify
, int waitfor
)
1074 struct vop_update_args a
;
1075 a
.a_desc
= VDESC(vop_update
);
1077 a
.a_access
= access
;
1078 a
.a_modify
= modify
;
1079 a
.a_waitfor
= waitfor
;
1080 return (VCALL(vp
, VOFFSET(vop_update
), &a
));
1083 struct vop_pgrd_args
{
1084 struct vnodeop_desc
*a_desc
;
1087 struct ucred
*a_cred
;
1089 extern struct vnodeop_desc vop_pgrd_desc
;
1090 #define VOP_PGRD(vp, uio, cred) _VOP_PGRD(vp, uio, cred)
1091 static __inline
int _VOP_PGRD(struct vnode
*vp
, struct uio
*uio
, struct ucred
*cred
)
1093 struct vop_pgrd_args a
;
1094 a
.a_desc
= VDESC(vop_pgrd
);
1098 return (VCALL(vp
, VOFFSET(vop_pgrd
), &a
));
1101 struct vop_pgwr_args
{
1102 struct vnodeop_desc
*a_desc
;
1105 struct ucred
*a_cred
;
1106 vm_offset_t a_offset
;
1108 extern struct vnodeop_desc vop_pgwr_desc
;
1109 #define VOP_PGWR(vp, uio, cred, offset) _VOP_PGWR(vp, uio, cred, offset)
1110 static __inline
int _VOP_PGWR(struct vnode
*vp
, struct uio
*uio
, struct ucred
*cred
, vm_offset_t offset
)
1112 struct vop_pgwr_args a
;
1113 a
.a_desc
= VDESC(vop_pgwr
);
1117 a
.a_offset
= offset
;
1118 return (VCALL(vp
, VOFFSET(vop_pgwr
), &a
));
1121 struct vop_pagein_args
{
1122 struct vnodeop_desc
*a_desc
;
1125 vm_offset_t a_pl_offset
;
1128 struct ucred
*a_cred
;
1131 extern struct vnodeop_desc vop_pagein_desc
;
1132 #define VOP_PAGEIN(vp, pl, pl_offset, f_offset, size, cred, flags) _VOP_PAGEIN(vp, pl, pl_offset, f_offset, size, cred, flags)
1133 static __inline
int _VOP_PAGEIN(struct vnode
*vp
, upl_t pl
, vm_offset_t pl_offset
, off_t f_offset
, size_t size
, struct ucred
*cred
, int flags
)
1135 struct vop_pagein_args a
;
1136 a
.a_desc
= VDESC(vop_pagein
);
1139 a
.a_pl_offset
= pl_offset
;
1140 a
.a_f_offset
= f_offset
;
1144 return (VCALL(vp
, VOFFSET(vop_pagein
), &a
));
1147 struct vop_pageout_args
{
1148 struct vnodeop_desc
*a_desc
;
1151 vm_offset_t a_pl_offset
;
1154 struct ucred
*a_cred
;
1157 extern struct vnodeop_desc vop_pageout_desc
;
1158 #define VOP_PAGEOUT(vp, pl, pl_offset, f_offset, size, cred, flags) _VOP_PAGEOUT(vp, pl, pl_offset, f_offset, size, cred, flags)
1159 static __inline
int _VOP_PAGEOUT(struct vnode
*vp
, upl_t pl
, vm_offset_t pl_offset
, off_t f_offset
, size_t size
, struct ucred
*cred
, int flags
)
1161 struct vop_pageout_args a
;
1162 a
.a_desc
= VDESC(vop_pageout
);
1165 a
.a_pl_offset
= pl_offset
;
1166 a
.a_f_offset
= f_offset
;
1170 return (VCALL(vp
, VOFFSET(vop_pageout
), &a
));
1173 struct vop_devblocksize_args
{
1174 struct vnodeop_desc
*a_desc
;
1176 register_t
*a_retval
;
1178 extern struct vnodeop_desc vop_devblocksize_desc
;
1179 #define VOP_DEVBLOCKSIZE(vp, retval) _VOP_DEVBLOCKSIZE(vp, retval)
1180 static __inline
int _VOP_DEVBLOCKSIZE(struct vnode
*vp
, register_t
*retval
)
1182 struct vop_devblocksize_args a
;
1183 a
.a_desc
= VDESC(vop_devblocksize
);
1185 a
.a_retval
= retval
;
1186 return (VCALL(vp
, VOFFSET(vop_devblocksize
), &a
));
1189 struct vop_searchfs_args
{
1190 struct vnodeop_desc
*a_desc
;
1192 void *a_searchparams1
;
1193 void *a_searchparams2
;
1194 struct attrlist
*a_searchattrs
;
1195 u_long a_maxmatches
;
1196 struct timeval
*a_timelimit
;
1197 struct attrlist
*a_returnattrs
;
1198 u_long
*a_nummatches
;
1199 u_long a_scriptcode
;
1202 struct searchstate
*a_searchstate
;
1204 extern struct vnodeop_desc vop_searchfs_desc
;
1205 #define VOP_SEARCHFS(vp, searchparams1, searchparams2, searchattrs, maxmatches, timelimit, returnattrs, nummatches, scriptcode, options, uio, searchstate) _VOP_SEARCHFS(vp, searchparams1, searchparams2, searchattrs, maxmatches, timelimit, returnattrs, nummatches, scriptcode, options, uio, searchstate)
1206 static __inline
int _VOP_SEARCHFS(struct vnode
*vp
, void *searchparams1
, void *searchparams2
, struct attrlist
*searchattrs
, u_long maxmatches
, struct timeval
*timelimit
, struct attrlist
*returnattrs
, u_long
*nummatches
, u_long scriptcode
, u_long options
, struct uio
*uio
, struct searchstate
*searchstate
)
1208 struct vop_searchfs_args a
;
1209 a
.a_desc
= VDESC(vop_searchfs
);
1211 a
.a_searchparams1
= searchparams1
;
1212 a
.a_searchparams2
= searchparams2
;
1213 a
.a_searchattrs
= searchattrs
;
1214 a
.a_maxmatches
= maxmatches
;
1215 a
.a_timelimit
= timelimit
;
1216 a
.a_returnattrs
= returnattrs
;
1217 a
.a_nummatches
= nummatches
;
1218 a
.a_scriptcode
= scriptcode
;
1219 a
.a_options
= options
;
1221 a
.a_searchstate
= searchstate
;
1222 return (VCALL(vp
, VOFFSET(vop_searchfs
), &a
));
1225 struct vop_copyfile_args
{
1226 struct vnodeop_desc
*a_desc
;
1227 struct vnode
*a_fvp
;
1228 struct vnode
*a_tdvp
;
1229 struct vnode
*a_tvp
;
1230 struct componentname
*a_tcnp
;
1234 extern struct vnodeop_desc vop_copyfile_desc
;
1235 #define VOP_COPYFILE(fvp, tdvp, tvp, tcnp, mode, flags) _VOP_COPYFILE(fvp, tdvp, tvp, tcnp, mode, flags)
1236 static __inline
int _VOP_COPYFILE(struct vnode
*fvp
, struct vnode
*tdvp
, struct vnode
*tvp
, struct componentname
*tcnp
, int mode
, int flags
)
1238 struct vop_copyfile_args a
;
1239 a
.a_desc
= VDESC(vop_copyfile
);
1246 return (VCALL(fvp
, VOFFSET(vop_copyfile
), &a
));
1249 struct vop_blktooff_args
{
1250 struct vnodeop_desc
*a_desc
;
1255 extern struct vnodeop_desc vop_blktooff_desc
;
1256 #define VOP_BLKTOOFF(vp, lblkno, offset) _VOP_BLKTOOFF(vp, lblkno, offset)
1257 static __inline
int _VOP_BLKTOOFF(struct vnode
*vp
, daddr_t lblkno
, off_t
*offset
)
1259 struct vop_blktooff_args a
;
1260 a
.a_desc
= VDESC(vop_blktooff
);
1262 a
.a_lblkno
= lblkno
;
1263 a
.a_offset
= offset
;
1264 return (VCALL(vp
, VOFFSET(vop_blktooff
), &a
));
1267 struct vop_offtoblk_args
{
1268 struct vnodeop_desc
*a_desc
;
1273 extern struct vnodeop_desc vop_offtoblk_desc
;
1274 #define VOP_OFFTOBLK(vp, offset, lblkno) _VOP_OFFTOBLK(vp, offset, lblkno)
1275 static __inline
int _VOP_OFFTOBLK(struct vnode
*vp
, off_t offset
, daddr_t
*lblkno
)
1277 struct vop_offtoblk_args a
;
1278 a
.a_desc
= VDESC(vop_offtoblk
);
1280 a
.a_offset
= offset
;
1281 a
.a_lblkno
= lblkno
;
1282 return (VCALL(vp
, VOFFSET(vop_offtoblk
), &a
));
1285 struct vop_cmap_args
{
1286 struct vnodeop_desc
*a_desc
;
1294 extern struct vnodeop_desc vop_cmap_desc
;
1295 #define VOP_CMAP(vp, foffset, size, bpn, run, poff) _VOP_CMAP(vp, foffset, size, bpn, run, poff)
1296 static __inline
int _VOP_CMAP(struct vnode
*vp
, off_t foffset
, size_t size
, daddr_t
*bpn
, size_t *run
, void *poff
)
1298 struct vop_cmap_args a
;
1299 a
.a_desc
= VDESC(vop_cmap
);
1301 a
.a_foffset
= foffset
;
1306 return (VCALL(vp
, VOFFSET(vop_cmap
), &a
));
1309 /* Special cases: */
1310 #include <sys/buf.h>
1313 struct vop_strategy_args
{
1314 struct vnodeop_desc
*a_desc
;
1317 extern struct vnodeop_desc vop_strategy_desc
;
1318 #define VOP_STRATEGY(bp) _VOP_STRATEGY(bp)
1319 static __inline
int _VOP_STRATEGY(struct buf
*bp
)
1321 struct vop_strategy_args a
;
1322 a
.a_desc
= VDESC(vop_strategy
);
1324 return (VCALL(bp
->b_vp
, VOFFSET(vop_strategy
), &a
));
1327 struct vop_bwrite_args
{
1328 struct vnodeop_desc
*a_desc
;
1331 extern struct vnodeop_desc vop_bwrite_desc
;
1332 #define VOP_BWRITE(bp) _VOP_BWRITE(bp)
1333 static __inline
int _VOP_BWRITE(struct buf
*bp
)
1335 struct vop_bwrite_args a
;
1336 a
.a_desc
= VDESC(vop_bwrite
);
1338 return (VCALL(bp
->b_vp
, VOFFSET(vop_bwrite
), &a
));
1341 /* End of special cases. */
1343 #endif /* !_VNODE_IF_H_ */