1 /* $OpenBSD: ufs_extern.h,v 1.41 2024/07/07 01:39:06 jsg Exp $ */ 2 /* $NetBSD: ufs_extern.h,v 1.5 1996/02/09 22:36:03 christos Exp $ */ 3 4 /*- 5 * Copyright (c) 1991, 1993, 1994 6 * The Regents of the University of California. All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without 9 * modification, are permitted provided that the following conditions 10 * are met: 11 * 1. Redistributions of source code must retain the above copyright 12 * notice, this list of conditions and the following disclaimer. 13 * 2. Redistributions in binary form must reproduce the above copyright 14 * notice, this list of conditions and the following disclaimer in the 15 * documentation and/or other materials provided with the distribution. 16 * 3. Neither the name of the University nor the names of its contributors 17 * may be used to endorse or promote products derived from this software 18 * without specific prior written permission. 19 * 20 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 21 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 22 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 23 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 24 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 25 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 26 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 27 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30 * SUCH DAMAGE. 31 * 32 * @(#)ufs_extern.h 8.6 (Berkeley) 8/10/94 33 */ 34 35 struct buf; 36 struct componentname; 37 struct direct; 38 struct disklabel; 39 struct dquot; 40 struct fid; 41 struct flock; 42 struct indir; 43 struct inode; 44 struct mbuf; 45 struct mount; 46 struct nameidata; 47 struct proc; 48 struct ucred; 49 struct ufs_args; 50 struct ufsmount; 51 struct uio; 52 struct vattr; 53 struct vfsconf; 54 struct vnode; 55 56 int ufs_access(void *); 57 int ufs_advlock(void *); 58 int ufs_bmap(void *); 59 int ufs_close(void *); 60 int ufs_create(void *); 61 int ufs_getattr(void *); 62 int ufs_inactive(void *); 63 int ufs_ioctl(void *); 64 int ufs_islocked(void *); 65 int ufs_link(void *); 66 int ufs_lock(void *); 67 int ufs_lookup(void *); 68 int ufs_mkdir(void *); 69 int ufs_mknod(void *); 70 int ufs_open(void *); 71 int ufs_pathconf(void *); 72 int ufs_print(void *); 73 int ufs_readdir(void *); 74 int ufs_readlink(void *); 75 int ufs_remove(void *); 76 int ufs_rename(void *); 77 int ufs_rmdir(void *); 78 int ufs_kqfilter(void *); 79 int ufs_setattr(void *); 80 int ufs_strategy(void *); 81 int ufs_symlink(void *); 82 int ufs_unlock(void *); 83 int ufsspec_close(void *); 84 int ufsspec_read(void *); 85 int ufsspec_write(void *); 86 87 #ifdef FIFO 88 int ufsfifo_read(void *); 89 int ufsfifo_write(void *); 90 int ufsfifo_close(void *); 91 #endif 92 93 /* ufs_bmap.c */ 94 int ufs_bmaparray(struct vnode *, daddr_t, daddr_t *, struct indir *, 95 int *, int *); 96 int ufs_getlbns(struct vnode *, daddr_t, struct indir *, int *); 97 98 /* ufs_ihash.c */ 99 void ufs_ihashinit(void); 100 struct vnode *ufs_ihashget(dev_t, ufsino_t); 101 int ufs_ihashins(struct inode *); 102 void ufs_ihashrem(struct inode *); 103 104 /* ufs_inode.c */ 105 int ufs_init(struct vfsconf *); 106 int ufs_reclaim(struct vnode *); 107 108 /* ufs_lookup.c */ 109 void ufs_dirbad(struct inode *, doff_t, char *); 110 int ufs_dirbadentry(struct vnode *, struct direct *, int); 111 void ufs_makedirentry(struct inode *, struct componentname *, 112 struct direct *); 113 int ufs_direnter(struct vnode *, struct vnode *, struct direct *, 114 struct componentname *, struct buf *); 115 int ufs_dirremove(struct vnode *, struct inode *, int, int); 116 int ufs_dirrewrite(struct inode *, struct inode *, 117 ufsino_t, int, int); 118 int ufs_dirempty(struct inode *, ufsino_t, struct ucred *); 119 int ufs_checkpath(struct inode *, struct inode *, struct ucred *); 120 121 /* ufs_vfsops.c */ 122 int ufs_start(struct mount *, int, struct proc *); 123 int ufs_root(struct mount *, struct vnode **); 124 int ufs_quotactl(struct mount *, int, uid_t, caddr_t, struct proc *); 125 int ufs_fhtovp(struct mount *, struct ufid *, struct vnode **); 126 int ufs_check_export(struct mount *, struct mbuf *, int *, 127 struct ucred **); 128 129 /* ufs_vnops.c */ 130 void ufs_itimes(struct vnode *); 131 int ufs_makeinode(int, struct vnode *, struct vnode **, 132 struct componentname *); 133