aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_iget.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@infradead.org>2010-06-23 21:51:19 -0400
committerAlex Elder <aelder@sgi.com>2010-07-26 14:16:44 -0400
commitef35e9255d4ed12522e836fbcec861e7306d794a (patch)
tree4ae5b2aef3f8dac9dd44490f6952e359239aa117 /fs/xfs/xfs_iget.c
parentd2e078c33c24f97411b0fdd7cd2173e68125e7e3 (diff)
xfs: remove xfs_iput_new
We never get an i_mode of 0 or a locked VFS inode until we pass in the XFS_IGET_CREATE flag to xfs_iget, which makes xfs_iput_new equivalent to xfs_iput for the only caller. In addition to that xfs_nfs_get_inode does not even need to lock the inode given that the generation never changes for a life inode, so just pass a 0 lock_flags to xfs_iget and release the inode using IRELE in the error path. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com>
Diffstat (limited to 'fs/xfs/xfs_iget.c')
-rw-r--r--fs/xfs/xfs_iget.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/fs/xfs/xfs_iget.c b/fs/xfs/xfs_iget.c
index 75664d1b9f59..b460e62bcf86 100644
--- a/fs/xfs/xfs_iget.c
+++ b/fs/xfs/xfs_iget.c
@@ -435,29 +435,6 @@ xfs_iput(xfs_inode_t *ip,
435} 435}
436 436
437/* 437/*
438 * Special iput for brand-new inodes that are still locked
439 */
440void
441xfs_iput_new(
442 xfs_inode_t *ip,
443 uint lock_flags)
444{
445 struct inode *inode = VFS_I(ip);
446
447 xfs_itrace_entry(ip);
448
449 if ((ip->i_d.di_mode == 0)) {
450 ASSERT(!xfs_iflags_test(ip, XFS_IRECLAIMABLE));
451 make_bad_inode(inode);
452 }
453 if (inode->i_state & I_NEW)
454 unlock_new_inode(inode);
455 if (lock_flags)
456 xfs_iunlock(ip, lock_flags);
457 IRELE(ip);
458}
459
460/*
461 * This is called free all the memory associated with an inode. 438 * This is called free all the memory associated with an inode.
462 * It must free the inode itself and any buffers allocated for 439 * It must free the inode itself and any buffers allocated for
463 * if_extents/if_data and if_broot. It must also free the lock 440 * if_extents/if_data and if_broot. It must also free the lock