]> git.saurik.com Git - apple/xnu.git/blob - bsd/sys/vnode_if.h
xnu-792.22.5.tar.gz
[apple/xnu.git] / bsd / sys / vnode_if.h
1
2 /*
3 * Copyright (c) 2000-2002 Apple Computer, Inc. All rights reserved.
4 *
5 * @APPLE_OSREFERENCE_LICENSE_HEADER_START@
6 *
7 * This file contains Original Code and/or Modifications of Original Code
8 * as defined in and that are subject to the Apple Public Source License
9 * Version 2.0 (the 'License'). You may not use this file except in
10 * compliance with the License. The rights granted to you under the License
11 * may not be used to create, or enable the creation or redistribution of,
12 * unlawful or unlicensed copies of an Apple operating system, or to
13 * circumvent, violate, or enable the circumvention or violation of, any
14 * terms of an Apple operating system software license agreement.
15 *
16 * Please obtain a copy of the License at
17 * http://www.opensource.apple.com/apsl/ and read it before using this file.
18 *
19 * The Original Code and all software distributed under the License are
20 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
21 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
22 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
23 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
24 * Please see the License for the specific language governing rights and
25 * limitations under the License.
26 *
27 * @APPLE_OSREFERENCE_LICENSE_HEADER_END@
28 */
29 /*
30 * Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved
31 * Copyright (c) 1992, 1993, 1994, 1995
32 * The Regents of the University of California. All rights reserved.
33 *
34 * Redistribution and use in source and binary forms, with or without
35 * modification, are permitted provided that the following conditions
36 * are met:
37 * 1. Redistributions of source code must retain the above copyright
38 * notice, this list of conditions and the following disclaimer.
39 * 2. Redistributions in binary form must reproduce the above copyright
40 * notice, this list of conditions and the following disclaimer in the
41 * documentation and/or other materials provided with the distribution.
42 * 3. All advertising materials mentioning features or use of this software
43 * must display the following acknowledgement:
44 * This product includes software developed by the University of
45 * California, Berkeley and its contributors.
46 * 4. Neither the name of the University nor the names of its contributors
47 * may be used to endorse or promote products derived from this software
48 * without specific prior written permission.
49 *
50 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS AND
51 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
52 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
53 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
54 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
55 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
56 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
57 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
58 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
59 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
60 * SUCH DAMAGE.
61 */
62
63
64 /*
65 * Warning: This file is generated automatically.
66 * (Modifications made here may easily be lost!)
67 *
68 * Created by the script:
69 * @(#)vnode_if.sh 8.7 (Berkeley) 5/11/95
70 */
71
72
73 #ifndef _SYS_VNODE_IF_H_
74 #define _SYS_VNODE_IF_H_
75
76 #include <sys/appleapiopts.h>
77 #include <sys/cdefs.h>
78 #include <sys/kernel_types.h>
79 #include <sys/buf.h>
80 #ifdef BSD_KERNEL_PRIVATE
81 #include <sys/vm.h>
82 #endif
83 #include <mach/memory_object_types.h>
84
85
86 #ifdef KERNEL
87
88 extern struct vnodeop_desc vnop_default_desc;
89 extern struct vnodeop_desc vnop_lookup_desc;
90 extern struct vnodeop_desc vnop_create_desc;
91 extern struct vnodeop_desc vnop_whiteout_desc;
92 extern struct vnodeop_desc vnop_mknod_desc;
93 extern struct vnodeop_desc vnop_open_desc;
94 extern struct vnodeop_desc vnop_close_desc;
95 extern struct vnodeop_desc vnop_access_desc;
96 extern struct vnodeop_desc vnop_getattr_desc;
97 extern struct vnodeop_desc vnop_setattr_desc;
98 extern struct vnodeop_desc vnop_getattrlist_desc;
99 extern struct vnodeop_desc vnop_setattrlist_desc;
100 extern struct vnodeop_desc vnop_read_desc;
101 extern struct vnodeop_desc vnop_write_desc;
102 extern struct vnodeop_desc vnop_ioctl_desc;
103 extern struct vnodeop_desc vnop_select_desc;
104 extern struct vnodeop_desc vnop_exchange_desc;
105 extern struct vnodeop_desc vnop_revoke_desc;
106 extern struct vnodeop_desc vnop_mmap_desc;
107 extern struct vnodeop_desc vnop_mnomap_desc;
108 extern struct vnodeop_desc vnop_fsync_desc;
109 extern struct vnodeop_desc vnop_remove_desc;
110 extern struct vnodeop_desc vnop_link_desc;
111 extern struct vnodeop_desc vnop_rename_desc;
112 extern struct vnodeop_desc vnop_mkdir_desc;
113 extern struct vnodeop_desc vnop_rmdir_desc;
114 extern struct vnodeop_desc vnop_symlink_desc;
115 extern struct vnodeop_desc vnop_readdir_desc;
116 extern struct vnodeop_desc vnop_readdirattr_desc;
117 extern struct vnodeop_desc vnop_readlink_desc;
118 extern struct vnodeop_desc vnop_inactive_desc;
119 extern struct vnodeop_desc vnop_reclaim_desc;
120 extern struct vnodeop_desc vnop_print_desc;
121 extern struct vnodeop_desc vnop_pathconf_desc;
122 extern struct vnodeop_desc vnop_advlock_desc;
123 extern struct vnodeop_desc vnop_truncate_desc;
124 extern struct vnodeop_desc vnop_allocate_desc;
125 extern struct vnodeop_desc vnop_pagein_desc;
126 extern struct vnodeop_desc vnop_pageout_desc;
127 extern struct vnodeop_desc vnop_searchfs_desc;
128 extern struct vnodeop_desc vnop_copyfile_desc;
129 extern struct vnodeop_desc vnop_blktooff_desc;
130 extern struct vnodeop_desc vnop_offtoblk_desc;
131 extern struct vnodeop_desc vnop_blockmap_desc;
132 extern struct vnodeop_desc vnop_strategy_desc;
133 extern struct vnodeop_desc vnop_bwrite_desc;
134
135 __BEGIN_DECLS
136 /*
137 *#
138 *#% lookup dvp L ? ?
139 *#% lookup vpp - L -
140 */
141 struct vnop_lookup_args {
142 struct vnodeop_desc *a_desc;
143 vnode_t a_dvp;
144 vnode_t *a_vpp;
145 struct componentname *a_cnp;
146 vfs_context_t a_context;
147 };
148 extern errno_t VNOP_LOOKUP(vnode_t, vnode_t *, struct componentname *, vfs_context_t);
149
150
151 /*
152 *#
153 *#% create dvp L L L
154 *#% create vpp - L -
155 *#
156 */
157
158 struct vnop_create_args {
159 struct vnodeop_desc *a_desc;
160 vnode_t a_dvp;
161 vnode_t *a_vpp;
162 struct componentname *a_cnp;
163 struct vnode_attr *a_vap;
164 vfs_context_t a_context;
165 };
166 extern errno_t VNOP_CREATE(vnode_t, vnode_t *, struct componentname *, struct vnode_attr *, vfs_context_t);
167
168 /*
169 *#
170 *#% whiteout dvp L L L
171 *#% whiteout cnp - - -
172 *#% whiteout flag - - -
173 *#
174 */
175 struct vnop_whiteout_args {
176 struct vnodeop_desc *a_desc;
177 vnode_t a_dvp;
178 struct componentname *a_cnp;
179 int a_flags;
180 vfs_context_t a_context;
181 };
182 extern errno_t VNOP_WHITEOUT(vnode_t, struct componentname *, int, vfs_context_t);
183
184 /*
185 *#
186 *#% mknod dvp L U U
187 *#% mknod vpp - X -
188 *#
189 */
190 struct vnop_mknod_args {
191 struct vnodeop_desc *a_desc;
192 vnode_t a_dvp;
193 vnode_t *a_vpp;
194 struct componentname *a_cnp;
195 struct vnode_attr *a_vap;
196 vfs_context_t a_context;
197 };
198 extern errno_t VNOP_MKNOD(vnode_t, vnode_t *, struct componentname *, struct vnode_attr *, vfs_context_t);
199
200 /*
201 *#
202 *#% open vp L L L
203 *#
204 */
205 struct vnop_open_args {
206 struct vnodeop_desc *a_desc;
207 vnode_t a_vp;
208 int a_mode;
209 vfs_context_t a_context;
210 };
211 extern errno_t VNOP_OPEN(vnode_t, int, vfs_context_t);
212
213 /*
214 *#
215 *#% close vp U U U
216 *#
217 */
218 struct vnop_close_args {
219 struct vnodeop_desc *a_desc;
220 vnode_t a_vp;
221 int a_fflag;
222 vfs_context_t a_context;
223 };
224 extern errno_t VNOP_CLOSE(vnode_t, int, vfs_context_t);
225
226 /*
227 *#
228 *#% access vp L L L
229 *#
230 */
231 struct vnop_access_args {
232 struct vnodeop_desc *a_desc;
233 vnode_t a_vp;
234 int a_action;
235 vfs_context_t a_context;
236 };
237 extern errno_t VNOP_ACCESS(vnode_t, int, vfs_context_t);
238
239
240 /*
241 *#
242 *#% getattr vp = = =
243 *#
244 */
245 struct vnop_getattr_args {
246 struct vnodeop_desc *a_desc;
247 vnode_t a_vp;
248 struct vnode_attr *a_vap;
249 vfs_context_t a_context;
250 };
251 extern errno_t VNOP_GETATTR(vnode_t, struct vnode_attr *, vfs_context_t);
252
253 /*
254 *#
255 *#% setattr vp L L L
256 *#
257 */
258 struct vnop_setattr_args {
259 struct vnodeop_desc *a_desc;
260 vnode_t a_vp;
261 struct vnode_attr *a_vap;
262 vfs_context_t a_context;
263 };
264 extern errno_t VNOP_SETATTR(vnode_t, struct vnode_attr *, vfs_context_t);
265
266 /*
267 *#
268 *#% getattrlist vp = = =
269 *#
270 */
271 struct vnop_getattrlist_args {
272 struct vnodeop_desc *a_desc;
273 vnode_t a_vp;
274 struct attrlist *a_alist;
275 struct uio *a_uio;
276 int a_options;
277 vfs_context_t a_context;
278 };
279 extern errno_t VNOP_GETATTRLIST(vnode_t, struct attrlist *, struct uio *, int, vfs_context_t);
280
281
282 /*
283 *#
284 *#% setattrlist vp L L L
285 *#
286 */
287 struct vnop_setattrlist_args {
288 struct vnodeop_desc *a_desc;
289 vnode_t a_vp;
290 struct attrlist *a_alist;
291 struct uio *a_uio;
292 int a_options;
293 vfs_context_t a_context;
294 };
295 extern errno_t VNOP_SETATTRLIST(vnode_t, struct attrlist *, struct uio *, int, vfs_context_t);
296
297
298 /*
299 *#
300 *#% read vp L L L
301 *#
302 */
303 struct vnop_read_args {
304 struct vnodeop_desc *a_desc;
305 vnode_t a_vp;
306 struct uio *a_uio;
307 int a_ioflag;
308 vfs_context_t a_context;
309 };
310 extern errno_t VNOP_READ(vnode_t, struct uio *, int, vfs_context_t);
311
312
313 /*
314 *#
315 *#% write vp L L L
316 *#
317 */
318 struct vnop_write_args {
319 struct vnodeop_desc *a_desc;
320 vnode_t a_vp;
321 struct uio *a_uio;
322 int a_ioflag;
323 vfs_context_t a_context;
324 };
325 extern errno_t VNOP_WRITE(vnode_t, struct uio *, int, vfs_context_t);
326
327
328 /*
329 *#
330 *#% ioctl vp U U U
331 *#
332 */
333 struct vnop_ioctl_args {
334 struct vnodeop_desc *a_desc;
335 vnode_t a_vp;
336 u_long a_command;
337 caddr_t a_data;
338 int a_fflag;
339 vfs_context_t a_context;
340 };
341 extern errno_t VNOP_IOCTL(vnode_t, u_long, caddr_t, int, vfs_context_t);
342
343
344 /*
345 *#
346 *#% select vp U U U
347 *#
348 */
349 struct vnop_select_args {
350 struct vnodeop_desc *a_desc;
351 vnode_t a_vp;
352 int a_which;
353 int a_fflags;
354 void *a_wql;
355 vfs_context_t a_context;
356 };
357 extern errno_t VNOP_SELECT(vnode_t, int, int, void *, vfs_context_t);
358
359
360 /*
361 *#
362 *#% exchange fvp L L L
363 *#% exchange tvp L L L
364 *#
365 */
366 struct vnop_exchange_args {
367 struct vnodeop_desc *a_desc;
368 vnode_t a_fvp;
369 vnode_t a_tvp;
370 int a_options;
371 vfs_context_t a_context;
372 };
373 extern errno_t VNOP_EXCHANGE(vnode_t, vnode_t, int, vfs_context_t);
374
375
376 /*
377 *#
378 *#% revoke vp U U U
379 *#
380 */
381 struct vnop_revoke_args {
382 struct vnodeop_desc *a_desc;
383 vnode_t a_vp;
384 int a_flags;
385 vfs_context_t a_context;
386 };
387 extern errno_t VNOP_REVOKE(vnode_t, int, vfs_context_t);
388
389
390 /*
391 *#
392 *# mmap - vp U U U
393 *#
394 */
395 struct vnop_mmap_args {
396 struct vnodeop_desc *a_desc;
397 vnode_t a_vp;
398 int a_fflags;
399 vfs_context_t a_context;
400 };
401 extern errno_t VNOP_MMAP(vnode_t, int, vfs_context_t);
402
403 /*
404 *#
405 *# mnomap - vp U U U
406 *#
407 */
408 struct vnop_mnomap_args {
409 struct vnodeop_desc *a_desc;
410 vnode_t a_vp;
411 vfs_context_t a_context;
412 };
413 extern errno_t VNOP_MNOMAP(vnode_t, vfs_context_t);
414
415
416 /*
417 *#
418 *#% fsync vp L L L
419 *#
420 */
421 struct vnop_fsync_args {
422 struct vnodeop_desc *a_desc;
423 vnode_t a_vp;
424 int a_waitfor;
425 vfs_context_t a_context;
426 };
427 extern errno_t VNOP_FSYNC(vnode_t, int, vfs_context_t);
428
429
430 /*
431 *#
432 *#% remove dvp L U U
433 *#% remove vp L U U
434 *#
435 */
436 struct vnop_remove_args {
437 struct vnodeop_desc *a_desc;
438 vnode_t a_dvp;
439 vnode_t a_vp;
440 struct componentname *a_cnp;
441 int a_flags;
442 vfs_context_t a_context;
443 };
444 extern errno_t VNOP_REMOVE(vnode_t, vnode_t, struct componentname *, int, vfs_context_t);
445
446
447 /*
448 *#
449 *#% link vp U U U
450 *#% link tdvp L U U
451 *#
452 */
453 struct vnop_link_args {
454 struct vnodeop_desc *a_desc;
455 vnode_t a_vp;
456 vnode_t a_tdvp;
457 struct componentname *a_cnp;
458 vfs_context_t a_context;
459 };
460 extern errno_t VNOP_LINK(vnode_t, vnode_t, struct componentname *, vfs_context_t);
461
462
463 /*
464 *#
465 *#% rename fdvp U U U
466 *#% rename fvp U U U
467 *#% rename tdvp L U U
468 *#% rename tvp X U U
469 *#
470 */
471 struct vnop_rename_args {
472 struct vnodeop_desc *a_desc;
473 vnode_t a_fdvp;
474 vnode_t a_fvp;
475 struct componentname *a_fcnp;
476 vnode_t a_tdvp;
477 vnode_t a_tvp;
478 struct componentname *a_tcnp;
479 vfs_context_t a_context;
480 };
481 extern errno_t VNOP_RENAME(vnode_t, vnode_t, struct componentname *, vnode_t, vnode_t, struct componentname *, vfs_context_t);
482
483
484 /*
485 *#
486 *#% mkdir dvp L U U
487 *#% mkdir vpp - L -
488 *#
489 */
490 struct vnop_mkdir_args {
491 struct vnodeop_desc *a_desc;
492 vnode_t a_dvp;
493 vnode_t *a_vpp;
494 struct componentname *a_cnp;
495 struct vnode_attr *a_vap;
496 vfs_context_t a_context;
497 };
498 extern errno_t VNOP_MKDIR(vnode_t, vnode_t *, struct componentname *, struct vnode_attr *, vfs_context_t);
499
500
501 /*
502 *#
503 *#% rmdir dvp L U U
504 *#% rmdir vp L U U
505 *#
506 */
507 struct vnop_rmdir_args {
508 struct vnodeop_desc *a_desc;
509 vnode_t a_dvp;
510 vnode_t a_vp;
511 struct componentname *a_cnp;
512 vfs_context_t a_context;
513 };
514 extern errno_t VNOP_RMDIR(vnode_t, vnode_t, struct componentname *, vfs_context_t);
515
516
517 /*
518 *#
519 *#% symlink dvp L U U
520 *#% symlink vpp - U -
521 *#
522 */
523 struct vnop_symlink_args {
524 struct vnodeop_desc *a_desc;
525 vnode_t a_dvp;
526 vnode_t *a_vpp;
527 struct componentname *a_cnp;
528 struct vnode_attr *a_vap;
529 char *a_target;
530 vfs_context_t a_context;
531 };
532 extern errno_t VNOP_SYMLINK(vnode_t, vnode_t *, struct componentname *, struct vnode_attr *, char *, vfs_context_t);
533
534
535 /*
536 *#
537 *#% readdir vp L L L
538 *#
539 *
540 * When VNOP_READDIR is called from the NFS Server, the nfs_data
541 * argument is non-NULL.
542 *
543 * The value of nfs_eofflag should be set to TRUE if the end of
544 * the directory was reached while reading.
545 *
546 * The directory seek offset (cookies) are returned to the NFS client and
547 * may be used later to restart a directory read part way through
548 * the directory. There is one cookie returned for each directory
549 * entry returned and its size is determince from nfs_sizeofcookie.
550 * The value of the cookie should be the logical offset within the
551 * directory where the on-disc version of the appropriate directory
552 * entry starts. Memory for the cookies is allocated from M_TEMP
553 * and it is freed by the caller of VNOP_READDIR.
554 *
555 */
556
557 struct vnop_readdir_args {
558 struct vnodeop_desc *a_desc;
559 vnode_t a_vp;
560 struct uio *a_uio;
561 int a_flags;
562 int *a_eofflag;
563 int *a_numdirent;
564 vfs_context_t a_context;
565 };
566 extern errno_t VNOP_READDIR(vnode_t, struct uio *, int, int *, int *, vfs_context_t);
567
568
569 /*
570 *#
571 *#% readdirattr vp L L L
572 *#
573 */
574 struct vnop_readdirattr_args {
575 struct vnodeop_desc *a_desc;
576 vnode_t a_vp;
577 struct attrlist *a_alist;
578 struct uio *a_uio;
579 u_long a_maxcount;
580 u_long a_options;
581 u_long *a_newstate;
582 int *a_eofflag;
583 u_long *a_actualcount;
584 vfs_context_t a_context;
585 };
586 extern errno_t VNOP_READDIRATTR(vnode_t, struct attrlist *, struct uio *, u_long, u_long, u_long *, int *, u_long *, vfs_context_t);
587
588
589 /*
590 *#
591 *#% readlink vp L L L
592 *#
593 */
594 struct vnop_readlink_args {
595 struct vnodeop_desc *a_desc;
596 vnode_t a_vp;
597 struct uio *a_uio;
598 vfs_context_t a_context;
599 };
600 extern errno_t VNOP_READLINK(vnode_t, struct uio *, vfs_context_t);
601
602
603 /*
604 *#
605 *#% inactive vp L U U
606 *#
607 */
608 struct vnop_inactive_args {
609 struct vnodeop_desc *a_desc;
610 vnode_t a_vp;
611 vfs_context_t a_context;
612 };
613 extern errno_t VNOP_INACTIVE(vnode_t, vfs_context_t);
614
615
616 /*
617 *#
618 *#% reclaim vp U U U
619 *#
620 */
621 struct vnop_reclaim_args {
622 struct vnodeop_desc *a_desc;
623 vnode_t a_vp;
624 vfs_context_t a_context;
625 };
626 extern errno_t VNOP_RECLAIM(vnode_t, vfs_context_t);
627
628
629 /*
630 *#
631 *#% pathconf vp L L L
632 *#
633 */
634 struct vnop_pathconf_args {
635 struct vnodeop_desc *a_desc;
636 vnode_t a_vp;
637 int a_name;
638 register_t *a_retval;
639 vfs_context_t a_context;
640 };
641 extern errno_t VNOP_PATHCONF(vnode_t, int, register_t *, vfs_context_t); /* register_t??????? */
642
643
644 /*
645 *#
646 *#% advlock vp U U U
647 *#
648 */
649 struct vnop_advlock_args {
650 struct vnodeop_desc *a_desc;
651 vnode_t a_vp;
652 caddr_t a_id;
653 int a_op;
654 struct flock *a_fl;
655 int a_flags;
656 vfs_context_t a_context;
657 };
658 extern errno_t VNOP_ADVLOCK(vnode_t, caddr_t, int, struct flock *, int, vfs_context_t);
659
660 /*
661 *#
662 *#% allocate vp L L L
663 *#
664 */
665 struct vnop_allocate_args {
666 struct vnodeop_desc *a_desc;
667 vnode_t a_vp;
668 off_t a_length;
669 u_int32_t a_flags;
670 off_t *a_bytesallocated;
671 off_t a_offset;
672 vfs_context_t a_context;
673 };
674 extern errno_t VNOP_ALLOCATE(vnode_t, off_t, u_int32_t, off_t *, off_t, vfs_context_t);
675
676 /*
677 *#
678 *#% pagein vp = = =
679 *#
680 */
681 struct vnop_pagein_args {
682 struct vnodeop_desc *a_desc;
683 vnode_t a_vp;
684 upl_t a_pl;
685 vm_offset_t a_pl_offset;
686 off_t a_f_offset;
687 size_t a_size;
688 int a_flags;
689 vfs_context_t a_context;
690 };
691 extern errno_t VNOP_PAGEIN(vnode_t, upl_t, vm_offset_t, off_t, size_t, int, vfs_context_t); /* vm_offset_t ? */
692
693
694 /*
695 *#
696 *#% pageout vp = = =
697 *#
698 */
699 struct vnop_pageout_args {
700 struct vnodeop_desc *a_desc;
701 vnode_t a_vp;
702 upl_t a_pl;
703 vm_offset_t a_pl_offset;
704 off_t a_f_offset;
705 size_t a_size;
706 int a_flags;
707 vfs_context_t a_context;
708 };
709 extern errno_t VNOP_PAGEOUT(vnode_t, upl_t, vm_offset_t, off_t, size_t, int, vfs_context_t);
710
711
712 /*
713 *#
714 *#% searchfs vp L L L
715 *#
716 */
717 struct vnop_searchfs_args {
718 struct vnodeop_desc *a_desc;
719 vnode_t a_vp;
720 void *a_searchparams1;
721 void *a_searchparams2;
722 struct attrlist *a_searchattrs;
723 u_long a_maxmatches;
724 struct timeval *a_timelimit;
725 struct attrlist *a_returnattrs;
726 u_long *a_nummatches;
727 u_long a_scriptcode;
728 u_long a_options;
729 struct uio *a_uio;
730 struct searchstate *a_searchstate;
731 vfs_context_t a_context;
732 };
733 extern errno_t VNOP_SEARCHFS(vnode_t, void *, void *, struct attrlist *, u_long, struct timeval *, struct attrlist *, u_long *, u_long, u_long, struct uio *, struct searchstate *, vfs_context_t);
734
735
736 /*
737 *#
738 *#% copyfile fvp U U U
739 *#% copyfile tdvp L U U
740 *#% copyfile tvp X U U
741 *#
742 */
743 struct vnop_copyfile_args {
744 struct vnodeop_desc *a_desc;
745 vnode_t a_fvp;
746 vnode_t a_tdvp;
747 vnode_t a_tvp;
748 struct componentname *a_tcnp;
749 int a_mode;
750 int a_flags;
751 vfs_context_t a_context;
752 };
753 extern errno_t VNOP_COPYFILE(vnode_t, vnode_t, vnode_t, struct componentname *, int, int, vfs_context_t);
754
755
756 struct vnop_getxattr_args {
757 struct vnodeop_desc *a_desc;
758 vnode_t a_vp;
759 char * a_name;
760 uio_t a_uio;
761 size_t *a_size;
762 int a_options;
763 vfs_context_t a_context;
764 };
765 extern struct vnodeop_desc vnop_getxattr_desc;
766 extern errno_t VNOP_GETXATTR(vnode_t, const char *, uio_t, size_t *, int, vfs_context_t);
767
768 struct vnop_setxattr_args {
769 struct vnodeop_desc *a_desc;
770 vnode_t a_vp;
771 char * a_name;
772 uio_t a_uio;
773 int a_options;
774 vfs_context_t a_context;
775 };
776 extern struct vnodeop_desc vnop_setxattr_desc;
777 extern errno_t VNOP_SETXATTR(vnode_t, const char *, uio_t, int, vfs_context_t);
778
779 struct vnop_removexattr_args {
780 struct vnodeop_desc *a_desc;
781 vnode_t a_vp;
782 char * a_name;
783 int a_options;
784 vfs_context_t a_context;
785 };
786 extern struct vnodeop_desc vnop_removexattr_desc;
787 extern errno_t VNOP_REMOVEXATTR(vnode_t, const char *, int, vfs_context_t);
788
789 struct vnop_listxattr_args {
790 struct vnodeop_desc *a_desc;
791 vnode_t a_vp;
792 uio_t a_uio;
793 size_t *a_size;
794 int a_options;
795 vfs_context_t a_context;
796 };
797 extern struct vnodeop_desc vnop_listxattr_desc;
798 extern errno_t VNOP_LISTXATTR(vnode_t, uio_t, size_t *, int, vfs_context_t);
799
800
801 /*
802 *#
803 *#% blktooff vp = = =
804 *#
805 */
806 struct vnop_blktooff_args {
807 struct vnodeop_desc *a_desc;
808 vnode_t a_vp;
809 daddr64_t a_lblkno;
810 off_t *a_offset;
811 };
812 extern errno_t VNOP_BLKTOOFF(vnode_t, daddr64_t, off_t *);
813
814
815 /*
816 *#
817 *#% offtoblk vp = = =
818 *#
819 */
820 struct vnop_offtoblk_args {
821 struct vnodeop_desc *a_desc;
822 vnode_t a_vp;
823 off_t a_offset;
824 daddr64_t *a_lblkno;
825 };
826 extern errno_t VNOP_OFFTOBLK(vnode_t, off_t, daddr64_t *);
827
828
829 /*
830 *#
831 *#% blockmap vp L L L
832 *#
833 */
834 struct vnop_blockmap_args {
835 struct vnodeop_desc *a_desc;
836 vnode_t a_vp;
837 off_t a_foffset;
838 size_t a_size;
839 daddr64_t *a_bpn;
840 size_t *a_run;
841 void *a_poff;
842 int a_flags;
843 vfs_context_t a_context;
844 };
845 extern errno_t VNOP_BLOCKMAP(vnode_t, off_t, size_t, daddr64_t *, size_t *, void *,
846 int, vfs_context_t);
847
848 struct vnop_strategy_args {
849 struct vnodeop_desc *a_desc;
850 struct buf *a_bp;
851 };
852 extern errno_t VNOP_STRATEGY(struct buf *bp);
853
854 struct vnop_bwrite_args {
855 struct vnodeop_desc *a_desc;
856 buf_t a_bp;
857 };
858 extern errno_t VNOP_BWRITE(buf_t);
859
860
861 struct vnop_kqfilt_add_args {
862 struct vnodeop_desc *a_desc;
863 struct vnode *a_vp;
864 struct knote *a_kn;
865 vfs_context_t a_context;
866 };
867 extern struct vnodeop_desc vnop_kqfilt_add_desc;
868 extern errno_t VNOP_KQFILT_ADD(vnode_t , struct knote *, vfs_context_t);
869
870 struct vnop_kqfilt_remove_args {
871 struct vnodeop_desc *a_desc;
872 struct vnode *a_vp;
873 uintptr_t a_ident;
874 vfs_context_t a_context;
875 };
876 extern struct vnodeop_desc vnop_kqfilt_remove_desc;
877 errno_t VNOP_KQFILT_REMOVE(vnode_t , uintptr_t , vfs_context_t);
878
879 __END_DECLS
880
881 #endif /* KERNEL */
882
883 #endif /* !_SYS_VNODE_IF_H_ */