From 90162edabf4063f7bfd36f7d9468293ccc869600 Mon Sep 17 00:00:00 2001 From: Tomohiro Kusumi Date: Fri, 29 May 2015 19:55:39 +0900 Subject: [PATCH] sys/gnu/vfs/ext2fs: Remove FS/I_FS macros - These file-local macros are from UFS, but not necessary. Directly refering to the superblock like the original ext2 code should be clearer. - (Note that dfly's ext2 seems to be broken currently) --- sys/gnu/vfs/ext2fs/ext2_readwrite.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/sys/gnu/vfs/ext2fs/ext2_readwrite.c b/sys/gnu/vfs/ext2fs/ext2_readwrite.c index c0e6c9f610..107c58002c 100644 --- a/sys/gnu/vfs/ext2fs/ext2_readwrite.c +++ b/sys/gnu/vfs/ext2fs/ext2_readwrite.c @@ -41,8 +41,6 @@ */ #define BLKSIZE(a, b, c) blksize(a, b, c) -#define FS struct ext2_sb_info -#define I_FS i_e2fs /* * Vnode op for reading. @@ -57,7 +55,7 @@ ext2_read(struct vop_read_args *ap) struct vnode *vp; struct inode *ip; struct uio *uio; - FS *fs; + struct ext2_sb_info *fs; struct buf *bp; daddr_t lbn, nextlbn; off_t nextloffset; @@ -80,7 +78,7 @@ ext2_read(struct vop_read_args *ap) } else if (vp->v_type != VREG && vp->v_type != VDIR) panic("ext2_read: type %d", vp->v_type); #endif - fs = ip->I_FS; + fs = ip->i_e2fs; #if 0 if ((u_quad_t)uio->uio_offset > fs->fs_maxfilesize) return (EFBIG); @@ -163,7 +161,7 @@ ext2_write(struct vop_write_args *ap) struct vnode *vp; struct uio *uio; struct inode *ip; - FS *fs; + struct ext2_sb_info *fs; struct buf *bp; struct thread *td; daddr_t lbn; @@ -199,7 +197,7 @@ ext2_write(struct vop_write_args *ap) panic("ext2_write: type"); } - fs = ip->I_FS; + fs = ip->i_e2fs; #if 0 if (uio->uio_offset < 0 || (u_quad_t)uio->uio_offset + uio->uio_resid > fs->fs_maxfilesize) -- 2.41.0