4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
21 /* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
22 /* All Rights Reserved */
25 * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
26 * Use is subject to license terms.
29 #ifndef _SYS_FS_SUBR_H
30 #define _SYS_FS_SUBR_H
32 #include <sys/types.h>
34 #include <sys/fcntl.h>
37 #include <sys/vnode.h>
40 #include <sys/share.h>
41 #include <sys/flock.h>
48 * Utilities shared among file system implementations.
53 extern int fs_nosys();
54 extern int fs_inval();
55 extern int fs_notdir();
56 extern int fs_nosys_poll(struct vnode
*, short, int, short *,
57 struct pollhead
**, caller_context_t
*);
58 extern int fs_ioctl(vnode_t
*, int, intptr_t, int, cred_t
*, int *,
60 extern int fs_putpage(vnode_t
*, offset_t
, size_t, int, cred_t
*,
62 extern int fs_fsync(vnode_t
*, int, cred_t
*, caller_context_t
*);
63 extern int fs_seek(vnode_t
*, offset_t
, offset_t
*, caller_context_t
*);
64 extern int fs_frlock(vnode_t
*, int, struct flock64
*, int, offset_t
,
65 struct flk_callback
*, cred_t
*, caller_context_t
*);
66 extern int fs_poll(vnode_t
*, short, int, short *, struct pollhead
**,
68 extern int fs_pathconf(struct vnode
*, int, ulong_t
*, struct cred
*,
70 extern void clkset(time_t);
71 extern void fs_dispose(struct vnode
*, page_t
*, int, int, struct cred
*,
73 extern void fs_nodispose(struct vnode
*, page_t
*, int, int, struct cred
*,
75 extern int fs_fab_acl(struct vnode
*, vsecattr_t
*, int flag
, cred_t
*,
77 extern int fs_shrlock(struct vnode
*, int, struct shrlock
*, int,
78 cred_t
*, caller_context_t
*);
79 extern int fs_vnevent_support(vnode_t
*, vnevent_t
, vnode_t
*dvp
,
80 char *fnm
, caller_context_t
*);
81 extern int fs_acl_nontrivial(struct vnode
*vp
, struct cred
*cr
);
82 extern int fs_need_estale_retry(int);
83 extern void fs_vscan_register(int (*av_scan
)(vnode_t
*, cred_t
*, int));
84 extern int fs_vscan(vnode_t
*, cred_t
*, int);
92 #endif /* _SYS_FS_SUBR_H */