aboutsummaryrefslogtreecommitdiff
path: root/sys/gnu/fs/ext2fs/ext2_mount.h
diff options
context:
space:
mode:
authorPoul-Henning Kamp <phk@FreeBSD.org>1997-10-16 10:50:27 +0000
committerPoul-Henning Kamp <phk@FreeBSD.org>1997-10-16 10:50:27 +0000
commitcec0f20ce75cb0da74afcd4d65a9795fd0864604 (patch)
tree13f8a41dd65c484c7fec96e128a73b0a5ca05c14 /sys/gnu/fs/ext2fs/ext2_mount.h
parent9fb4ca060c29aa20b3184ef2e29ea0137e2ffdac (diff)
downloadsrc-cec0f20ce75cb0da74afcd4d65a9795fd0864604.tar.gz
src-cec0f20ce75cb0da74afcd4d65a9795fd0864604.zip
VFS mega cleanup commit (x/N)
1. Add new file "sys/kern/vfs_default.c" where default actions for VOPs go. Implement proper defaults for ABORTOP, BWRITE, LEASE, POLL, REVOKE and STRATEGY. Various stuff spread over the entire tree belongs here. 2. Change VOP_BLKATOFF to a normal function in cd9660. 3. Kill VOP_BLKATOFF, VOP_TRUNCATE, VOP_VFREE, VOP_VALLOC. These are private interface functions between UFS and the underlying storage manager layer (FFS/LFS/MFS/EXT2FS). The functions now live in struct ufsmount instead. 4. Remove a kludge of VOP_ functions in all filesystems, that did nothing but obscure the simplicity and break the expandability. If a filesystem doesn't implement VOP_FOO, it shouldn't have an entry for it in its vnops table. The system will try to DTRT if it is not implemented. There are still some cruft left, but the bulk of it is done. 5. Fix another VCALL in vfs_cache.c (thanks Bruce!)
Notes
Notes: svn path=/head/; revision=30474
Diffstat (limited to 'sys/gnu/fs/ext2fs/ext2_mount.h')
-rw-r--r--sys/gnu/fs/ext2fs/ext2_mount.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/sys/gnu/fs/ext2fs/ext2_mount.h b/sys/gnu/fs/ext2fs/ext2_mount.h
index d57dd59c8936..50bfe575f51e 100644
--- a/sys/gnu/fs/ext2fs/ext2_mount.h
+++ b/sys/gnu/fs/ext2fs/ext2_mount.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)ufsmount.h 8.6 (Berkeley) 3/30/95
- * $Id: ufsmount.h,v 1.9 1997/10/10 18:18:13 phk Exp $
+ * $Id: ufsmount.h,v 1.10 1997/10/12 20:26:28 phk Exp $
*/
#ifndef _UFS_UFS_UFSMOUNT_H_
@@ -97,8 +97,17 @@ struct ufsmount {
struct netexport um_export; /* export information */
int64_t um_savedmaxfilesize; /* XXX - limit maxfilesize */
struct malloc_type *um_malloctype; /* The inodes malloctype */
+ int (*um_blkatoff) __P((struct vnode *, off_t, char **, struct buf **));
+ int (*um_truncate) __P((struct vnode *, off_t, int, struct ucred *, struct proc *));
+ int (*um_valloc) __P((struct vnode *, int, struct ucred *, struct vnode **));
+ int (*um_vfree) __P((struct vnode *, ino_t, int));
};
+#define UFS_BLKATOFF(aa, bb, cc, dd) VFSTOUFS((aa)->v_mount)->um_blkatoff(aa, bb, cc, dd)
+#define UFS_TRUNCATE(aa, bb, cc, dd, ee) VFSTOUFS((aa)->v_mount)->um_truncate(aa, bb, cc, dd, ee)
+#define UFS_VALLOC(aa, bb, cc, dd) VFSTOUFS((aa)->v_mount)->um_valloc(aa, bb, cc, dd)
+#define UFS_VFREE(aa, bb, cc) VFSTOUFS((aa)->v_mount)->um_vfree(aa, bb, cc)
+
/*
* Flags describing the state of quotas.
*/