Date: Tue, 23 Jan 2018 14:17:04 +0000 (UTC) From: "Pedro F. Giffuni" <pfg@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r328280 - head/sys/fs/ext2fs Message-ID: <201801231417.w0NEH46E083069@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: pfg Date: Tue Jan 23 14:17:04 2018 New Revision: 328280 URL: https://svnweb.freebsd.org/changeset/base/328280 Log: extfs: Remove unused variables. Found by: scan-build Reviewed by: fsu Differential Revision: https://reviews.freebsd.org/D14017 Modified: head/sys/fs/ext2fs/ext2_csum.c head/sys/fs/ext2fs/ext2_extents.c head/sys/fs/ext2fs/ext2_lookup.c Modified: head/sys/fs/ext2fs/ext2_csum.c ============================================================================== --- head/sys/fs/ext2fs/ext2_csum.c Tue Jan 23 13:03:47 2018 (r328279) +++ head/sys/fs/ext2fs/ext2_csum.c Tue Jan 23 14:17:04 2018 (r328280) @@ -535,12 +535,11 @@ static uint32_t ext2_ei_csum(struct inode *ip, struct ext2fs_dinode *ei) { struct m_ext2fs *fs; - uint16_t old_lo, old_hi; + uint16_t old_hi; uint32_t inum, gen, crc; fs = ip->i_e2fs; - old_lo = ei->e2di_chksum_lo; ei->e2di_chksum_lo = 0; if ((EXT2_INODE_SIZE(ip->i_e2fs) > E2FS_REV0_INODE_SIZE && ei->e2di_extra_isize >= EXT2_INODE_CSUM_HI_EXTRA_END)) { Modified: head/sys/fs/ext2fs/ext2_extents.c ============================================================================== --- head/sys/fs/ext2fs/ext2_extents.c Tue Jan 23 13:03:47 2018 (r328279) +++ head/sys/fs/ext2fs/ext2_extents.c Tue Jan 23 14:17:04 2018 (r328280) @@ -125,10 +125,8 @@ ext4_ext_print_path(struct inode *ip, struct ext4_exte void ext4_ext_print_extent_tree_status(struct inode * ip) { - struct m_ext2fs *fs; struct ext4_extent_header *ehp; - fs = ip->i_e2fs; ehp = (struct ext4_extent_header *)(char *)ip->i_db; printf("Extent status:ip=%d\n", ip->i_number); @@ -882,7 +880,6 @@ ext4_ext_grow_indepth(struct inode *ip, struct ext4_ex struct m_ext2fs *fs; struct ext4_extent_path *curpath; struct ext4_extent_header *neh; - struct ext4_extent_index *fidx; struct buf *bp; e4fs_daddr_t newblk; int error = 0; @@ -925,7 +922,6 @@ ext4_ext_grow_indepth(struct inode *ip, struct ext4_ex ext4_index_store_pblock(curpath->ep_index, newblk); neh = ext4_ext_inode_header(ip); - fidx = EXT_FIRST_INDEX(neh); neh->eh_depth = path->ep_depth + 1; ext4_ext_dirty(ip, curpath); out: @@ -938,12 +934,9 @@ static int ext4_ext_create_new_leaf(struct inode *ip, struct ext4_extent_path *path, struct ext4_extent *newext) { - struct m_ext2fs *fs; struct ext4_extent_path *curpath; int depth, i, error; - fs = ip->i_e2fs; - repeat: i = depth = ext4_ext_inode_depth(ip); @@ -1033,13 +1026,11 @@ static int ext4_ext_insert_extent(struct inode *ip, struct ext4_extent_path *path, struct ext4_extent *newext) { - struct m_ext2fs *fs; struct ext4_extent_header * eh; struct ext4_extent *ex, *nex, *nearex; struct ext4_extent_path *npath; int depth, len, error, next; - fs = ip->i_e2fs; depth = ext4_ext_inode_depth(ip); ex = path[depth].ep_ext; npath = NULL; @@ -1166,11 +1157,9 @@ ext4_new_blocks(struct inode *ip, daddr_t lbn, e4fs_da struct ucred *cred, unsigned long *count, int *perror) { struct m_ext2fs *fs; - struct ext2mount *ump; e4fs_daddr_t newblk; fs = ip->i_e2fs; - ump = ip->i_ump; /* * We will allocate only single block for now. Modified: head/sys/fs/ext2fs/ext2_lookup.c ============================================================================== --- head/sys/fs/ext2fs/ext2_lookup.c Tue Jan 23 13:03:47 2018 (r328279) +++ head/sys/fs/ext2fs/ext2_lookup.c Tue Jan 23 14:17:04 2018 (r328280) @@ -869,8 +869,8 @@ ext2_direnter(struct inode *ip, struct vnode *dvp, str struct inode *dp; struct ext2fs_direct_2 newdir; struct buf *bp; - int error, newentrysize; int DIRBLKSIZ = ip->i_e2fs->e2fs_bsize; + int error; #ifdef INVARIANTS @@ -886,7 +886,6 @@ ext2_direnter(struct inode *ip, struct vnode *dvp, str else newdir.e2d_type = EXT2_FT_UNKNOWN; bcopy(cnp->cn_nameptr, newdir.e2d_name, (unsigned)cnp->cn_namelen + 1); - newentrysize = EXT2_DIR_REC_LEN(newdir.e2d_namlen); if (ext2_htree_has_idx(dp)) { error = ext2_htree_add_entry(dvp, &newdir, cnp);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201801231417.w0NEH46E083069>