1 /*
2  * Warning: This file is generated automatically.
3  * (Modifications made here may easily be lost!)
4  *
5  * Created from the file:
6  *	OpenBSD: vnode_if.src,v 1.29 2005/07/14 09:04:59 pedro Exp
7  * by the script:
8  *	MirOS: src/sys/kern/vnode_if.sh,v 1.2 2005/07/07 13:39:41 tg Exp
9  */
10 
11 /*
12  * Copyright (c) 1992, 1993
13  *	The Regents of the University of California.  All rights reserved.
14  *
15  * Redistribution and use in source and binary forms, with or without
16  * modification, are permitted provided that the following conditions
17  * are met:
18  * 1. Redistributions of source code must retain the above copyright
19  *    notice, this list of conditions and the following disclaimer.
20  * 2. Redistributions in binary form must reproduce the above copyright
21  *    notice, this list of conditions and the following disclaimer in the
22  *    documentation and/or other materials provided with the distribution.
23  * 3. Neither the name of the University nor the names of its contributors
24  *    may be used to endorse or promote products derived from this software
25  *    without specific prior written permission.
26  *
27  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS AS IS'' AND
28  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
29  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
30  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
31  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
32  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
33  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
34  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
35  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
36  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
37  * SUCH DAMAGE.
38  */
39 
40 extern struct vnodeop_desc vop_default_desc;
41 
42 #include "systm.h"
43 
44 struct vop_islocked_args {
45 	struct vnodeop_desc *a_desc;
46 	struct vnode *a_vp;
47 };
48 extern struct vnodeop_desc vop_islocked_desc;
49 int VOP_ISLOCKED(struct vnode *);
50 
51 struct vop_lookup_args {
52 	struct vnodeop_desc *a_desc;
53 	struct vnode *a_dvp;
54 	struct vnode **a_vpp;
55 	struct componentname *a_cnp;
56 };
57 extern struct vnodeop_desc vop_lookup_desc;
58 int VOP_LOOKUP(struct vnode *, struct vnode **, struct componentname *);
59 
60 struct vop_create_args {
61 	struct vnodeop_desc *a_desc;
62 	struct vnode *a_dvp;
63 	struct vnode **a_vpp;
64 	struct componentname *a_cnp;
65 	struct vattr *a_vap;
66 };
67 extern struct vnodeop_desc vop_create_desc;
68 int VOP_CREATE(struct vnode *, struct vnode **, struct componentname *,
69     struct vattr *);
70 
71 struct vop_mknod_args {
72 	struct vnodeop_desc *a_desc;
73 	struct vnode *a_dvp;
74 	struct vnode **a_vpp;
75 	struct componentname *a_cnp;
76 	struct vattr *a_vap;
77 };
78 extern struct vnodeop_desc vop_mknod_desc;
79 int VOP_MKNOD(struct vnode *, struct vnode **, struct componentname *,
80     struct vattr *);
81 
82 struct vop_open_args {
83 	struct vnodeop_desc *a_desc;
84 	struct vnode *a_vp;
85 	int a_mode;
86 	struct ucred *a_cred;
87 	struct proc *a_p;
88 };
89 extern struct vnodeop_desc vop_open_desc;
90 int VOP_OPEN(struct vnode *, int, struct ucred *, struct proc *);
91 
92 struct vop_close_args {
93 	struct vnodeop_desc *a_desc;
94 	struct vnode *a_vp;
95 	int a_fflag;
96 	struct ucred *a_cred;
97 	struct proc *a_p;
98 };
99 extern struct vnodeop_desc vop_close_desc;
100 int VOP_CLOSE(struct vnode *, int, struct ucred *, struct proc *);
101 
102 struct vop_access_args {
103 	struct vnodeop_desc *a_desc;
104 	struct vnode *a_vp;
105 	int a_mode;
106 	struct ucred *a_cred;
107 	struct proc *a_p;
108 };
109 extern struct vnodeop_desc vop_access_desc;
110 int VOP_ACCESS(struct vnode *, int, struct ucred *, struct proc *);
111 
112 struct vop_getattr_args {
113 	struct vnodeop_desc *a_desc;
114 	struct vnode *a_vp;
115 	struct vattr *a_vap;
116 	struct ucred *a_cred;
117 	struct proc *a_p;
118 };
119 extern struct vnodeop_desc vop_getattr_desc;
120 int VOP_GETATTR(struct vnode *, struct vattr *, struct ucred *, struct proc *);
121 
122 struct vop_setattr_args {
123 	struct vnodeop_desc *a_desc;
124 	struct vnode *a_vp;
125 	struct vattr *a_vap;
126 	struct ucred *a_cred;
127 	struct proc *a_p;
128 };
129 extern struct vnodeop_desc vop_setattr_desc;
130 int VOP_SETATTR(struct vnode *, struct vattr *, struct ucred *, struct proc *);
131 
132 struct vop_read_args {
133 	struct vnodeop_desc *a_desc;
134 	struct vnode *a_vp;
135 	struct uio *a_uio;
136 	int a_ioflag;
137 	struct ucred *a_cred;
138 };
139 extern struct vnodeop_desc vop_read_desc;
140 int VOP_READ(struct vnode *, struct uio *, int, struct ucred *);
141 
142 struct vop_write_args {
143 	struct vnodeop_desc *a_desc;
144 	struct vnode *a_vp;
145 	struct uio *a_uio;
146 	int a_ioflag;
147 	struct ucred *a_cred;
148 };
149 extern struct vnodeop_desc vop_write_desc;
150 int VOP_WRITE(struct vnode *, struct uio *, int, struct ucred *);
151 
152 struct vop_lease_args {
153 	struct vnodeop_desc *a_desc;
154 	struct vnode *a_vp;
155 	struct proc *a_p;
156 	struct ucred *a_cred;
157 	int a_flag;
158 };
159 extern struct vnodeop_desc vop_lease_desc;
160 int VOP_LEASE(struct vnode *, struct proc *, struct ucred *, int);
161 
162 struct vop_ioctl_args {
163 	struct vnodeop_desc *a_desc;
164 	struct vnode *a_vp;
165 	u_long a_command;
166 	void *a_data;
167 	int a_fflag;
168 	struct ucred *a_cred;
169 	struct proc *a_p;
170 };
171 extern struct vnodeop_desc vop_ioctl_desc;
172 int VOP_IOCTL(struct vnode *, u_long, void *, int, struct ucred *,
173     struct proc *);
174 
175 struct vop_poll_args {
176 	struct vnodeop_desc *a_desc;
177 	struct vnode *a_vp;
178 	int a_events;
179 	struct proc *a_p;
180 };
181 extern struct vnodeop_desc vop_poll_desc;
182 int VOP_POLL(struct vnode *, int, struct proc *);
183 
184 struct vop_kqfilter_args {
185 	struct vnodeop_desc *a_desc;
186 	struct vnode *a_vp;
187 	struct knote *a_kn;
188 };
189 extern struct vnodeop_desc vop_kqfilter_desc;
190 int VOP_KQFILTER(struct vnode *, struct knote *);
191 
192 struct vop_revoke_args {
193 	struct vnodeop_desc *a_desc;
194 	struct vnode *a_vp;
195 	int a_flags;
196 };
197 extern struct vnodeop_desc vop_revoke_desc;
198 int VOP_REVOKE(struct vnode *, int);
199 
200 struct vop_fsync_args {
201 	struct vnodeop_desc *a_desc;
202 	struct vnode *a_vp;
203 	struct ucred *a_cred;
204 	int a_waitfor;
205 	struct proc *a_p;
206 };
207 extern struct vnodeop_desc vop_fsync_desc;
208 int VOP_FSYNC(struct vnode *, struct ucred *, int, struct proc *);
209 
210 struct vop_remove_args {
211 	struct vnodeop_desc *a_desc;
212 	struct vnode *a_dvp;
213 	struct vnode *a_vp;
214 	struct componentname *a_cnp;
215 };
216 extern struct vnodeop_desc vop_remove_desc;
217 int VOP_REMOVE(struct vnode *, struct vnode *, struct componentname *);
218 
219 struct vop_link_args {
220 	struct vnodeop_desc *a_desc;
221 	struct vnode *a_dvp;
222 	struct vnode *a_vp;
223 	struct componentname *a_cnp;
224 };
225 extern struct vnodeop_desc vop_link_desc;
226 int VOP_LINK(struct vnode *, struct vnode *, struct componentname *);
227 
228 struct vop_rename_args {
229 	struct vnodeop_desc *a_desc;
230 	struct vnode *a_fdvp;
231 	struct vnode *a_fvp;
232 	struct componentname *a_fcnp;
233 	struct vnode *a_tdvp;
234 	struct vnode *a_tvp;
235 	struct componentname *a_tcnp;
236 };
237 extern struct vnodeop_desc vop_rename_desc;
238 int VOP_RENAME(struct vnode *, struct vnode *, struct componentname *,
239     struct vnode *, struct vnode *, struct componentname *);
240 
241 struct vop_mkdir_args {
242 	struct vnodeop_desc *a_desc;
243 	struct vnode *a_dvp;
244 	struct vnode **a_vpp;
245 	struct componentname *a_cnp;
246 	struct vattr *a_vap;
247 };
248 extern struct vnodeop_desc vop_mkdir_desc;
249 int VOP_MKDIR(struct vnode *, struct vnode **, struct componentname *,
250     struct vattr *);
251 
252 struct vop_rmdir_args {
253 	struct vnodeop_desc *a_desc;
254 	struct vnode *a_dvp;
255 	struct vnode *a_vp;
256 	struct componentname *a_cnp;
257 };
258 extern struct vnodeop_desc vop_rmdir_desc;
259 int VOP_RMDIR(struct vnode *, struct vnode *, struct componentname *);
260 
261 struct vop_symlink_args {
262 	struct vnodeop_desc *a_desc;
263 	struct vnode *a_dvp;
264 	struct vnode **a_vpp;
265 	struct componentname *a_cnp;
266 	struct vattr *a_vap;
267 	char *a_target;
268 };
269 extern struct vnodeop_desc vop_symlink_desc;
270 int VOP_SYMLINK(struct vnode *, struct vnode **, struct componentname *,
271     struct vattr *, char *);
272 
273 struct vop_readdir_args {
274 	struct vnodeop_desc *a_desc;
275 	struct vnode *a_vp;
276 	struct uio *a_uio;
277 	struct ucred *a_cred;
278 	int *a_eofflag;
279 	int *a_ncookies;
280 	u_long **a_cookies;
281 };
282 extern struct vnodeop_desc vop_readdir_desc;
283 int VOP_READDIR(struct vnode *, struct uio *, struct ucred *, int *, int *,
284     u_long **);
285 
286 struct vop_readlink_args {
287 	struct vnodeop_desc *a_desc;
288 	struct vnode *a_vp;
289 	struct uio *a_uio;
290 	struct ucred *a_cred;
291 };
292 extern struct vnodeop_desc vop_readlink_desc;
293 int VOP_READLINK(struct vnode *, struct uio *, struct ucred *);
294 
295 struct vop_abortop_args {
296 	struct vnodeop_desc *a_desc;
297 	struct vnode *a_dvp;
298 	struct componentname *a_cnp;
299 };
300 extern struct vnodeop_desc vop_abortop_desc;
301 int VOP_ABORTOP(struct vnode *, struct componentname *);
302 
303 struct vop_inactive_args {
304 	struct vnodeop_desc *a_desc;
305 	struct vnode *a_vp;
306 	struct proc *a_p;
307 };
308 extern struct vnodeop_desc vop_inactive_desc;
309 int VOP_INACTIVE(struct vnode *, struct proc *);
310 
311 struct vop_reclaim_args {
312 	struct vnodeop_desc *a_desc;
313 	struct vnode *a_vp;
314 	struct proc *a_p;
315 };
316 extern struct vnodeop_desc vop_reclaim_desc;
317 int VOP_RECLAIM(struct vnode *, struct proc *);
318 
319 struct vop_lock_args {
320 	struct vnodeop_desc *a_desc;
321 	struct vnode *a_vp;
322 	int a_flags;
323 	struct proc *a_p;
324 };
325 extern struct vnodeop_desc vop_lock_desc;
326 int VOP_LOCK(struct vnode *, int, struct proc *);
327 
328 struct vop_unlock_args {
329 	struct vnodeop_desc *a_desc;
330 	struct vnode *a_vp;
331 	int a_flags;
332 	struct proc *a_p;
333 };
334 extern struct vnodeop_desc vop_unlock_desc;
335 int VOP_UNLOCK(struct vnode *, int, struct proc *);
336 
337 struct vop_bmap_args {
338 	struct vnodeop_desc *a_desc;
339 	struct vnode *a_vp;
340 	daddr_t a_bn;
341 	struct vnode **a_vpp;
342 	daddr_t *a_bnp;
343 	int *a_runp;
344 };
345 extern struct vnodeop_desc vop_bmap_desc;
346 int VOP_BMAP(struct vnode *, daddr_t, struct vnode **, daddr_t *, int *);
347 
348 struct vop_print_args {
349 	struct vnodeop_desc *a_desc;
350 	struct vnode *a_vp;
351 };
352 extern struct vnodeop_desc vop_print_desc;
353 int VOP_PRINT(struct vnode *);
354 
355 struct vop_pathconf_args {
356 	struct vnodeop_desc *a_desc;
357 	struct vnode *a_vp;
358 	int a_name;
359 	register_t *a_retval;
360 };
361 extern struct vnodeop_desc vop_pathconf_desc;
362 int VOP_PATHCONF(struct vnode *, int, register_t *);
363 
364 struct vop_advlock_args {
365 	struct vnodeop_desc *a_desc;
366 	struct vnode *a_vp;
367 	void *a_id;
368 	int a_op;
369 	struct flock *a_fl;
370 	int a_flags;
371 };
372 extern struct vnodeop_desc vop_advlock_desc;
373 int VOP_ADVLOCK(struct vnode *, void *, int, struct flock *, int);
374 
375 struct vop_reallocblks_args {
376 	struct vnodeop_desc *a_desc;
377 	struct vnode *a_vp;
378 	struct cluster_save *a_buflist;
379 };
380 extern struct vnodeop_desc vop_reallocblks_desc;
381 int VOP_REALLOCBLKS(struct vnode *, struct cluster_save *);
382 
383 /* Special cases: */
384 #include <sys/buf.h>
385 
386 struct vop_strategy_args {
387 	struct vnodeop_desc *a_desc;
388 	struct buf *a_bp;
389 };
390 extern struct vnodeop_desc vop_strategy_desc;
391 int VOP_STRATEGY(struct buf *);
392 
393 struct vop_bwrite_args {
394 	struct vnodeop_desc *a_desc;
395 	struct buf *a_bp;
396 };
397 extern struct vnodeop_desc vop_bwrite_desc;
398 int VOP_BWRITE(struct buf *);
399 
400 /* End of special cases. */
401