aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@infradead.org>2008-08-13 02:13:09 -0400
committerLachlan McIlroy <lachlan@redback.melbourne.sgi.com>2008-08-13 02:13:09 -0400
commit0b1f917730dc2276fadbd9813ac3666abd7b1cbd (patch)
tree8fe61b1287643bf47d3d88204f33393361d8d70c /fs
parent604323ca760beebf00a07153706dcbe7128324e0 (diff)
[XFS] remove remaining VN_HOLD calls
Use IHOLD(ip) instead of VN_HOLD(VFS_I(ip)). SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31765a Signed-off-by: Christoph Hellwig <hch@infradead.org> Signed-off-by: Lachlan McIlroy <lachlan@sgi.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/xfs/quota/xfs_dquot.c2
-rw-r--r--fs/xfs/xfs_bmap.c2
-rw-r--r--fs/xfs/xfs_dfrag.c10
3 files changed, 5 insertions, 9 deletions
diff --git a/fs/xfs/quota/xfs_dquot.c b/fs/xfs/quota/xfs_dquot.c
index 68adc5fd9b95..9de42d031745 100644
--- a/fs/xfs/quota/xfs_dquot.c
+++ b/fs/xfs/quota/xfs_dquot.c
@@ -431,7 +431,7 @@ xfs_qm_dqalloc(
431 * when it unlocks the inode. Since we want to keep the quota 431 * when it unlocks the inode. Since we want to keep the quota
432 * inode around, we bump the vnode ref count now. 432 * inode around, we bump the vnode ref count now.
433 */ 433 */
434 VN_HOLD(VFS_I(quotip)); 434 IHOLD(quotip);
435 435
436 xfs_trans_ijoin(tp, quotip, XFS_ILOCK_EXCL); 436 xfs_trans_ijoin(tp, quotip, XFS_ILOCK_EXCL);
437 nmaps = 1; 437 nmaps = 1;
diff --git a/fs/xfs/xfs_bmap.c b/fs/xfs/xfs_bmap.c
index bac82af39a52..3d6a2ce8503e 100644
--- a/fs/xfs/xfs_bmap.c
+++ b/fs/xfs/xfs_bmap.c
@@ -4000,7 +4000,7 @@ xfs_bmap_add_attrfork(
4000 ip->i_d.di_aformat = XFS_DINODE_FMT_EXTENTS; 4000 ip->i_d.di_aformat = XFS_DINODE_FMT_EXTENTS;
4001 } 4001 }
4002 ASSERT(ip->i_d.di_anextents == 0); 4002 ASSERT(ip->i_d.di_anextents == 0);
4003 VN_HOLD(VFS_I(ip)); 4003 IHOLD(ip);
4004 xfs_trans_ijoin(tp, ip, XFS_ILOCK_EXCL); 4004 xfs_trans_ijoin(tp, ip, XFS_ILOCK_EXCL);
4005 xfs_trans_log_inode(tp, ip, XFS_ILOG_CORE); 4005 xfs_trans_log_inode(tp, ip, XFS_ILOG_CORE);
4006 switch (ip->i_d.di_format) { 4006 switch (ip->i_d.di_format) {
diff --git a/fs/xfs/xfs_dfrag.c b/fs/xfs/xfs_dfrag.c
index 9e751011e231..d92407842e3b 100644
--- a/fs/xfs/xfs_dfrag.c
+++ b/fs/xfs/xfs_dfrag.c
@@ -350,15 +350,11 @@ xfs_swap_extents(
350 break; 350 break;
351 } 351 }
352 352
353 /*
354 * Increment vnode ref counts since xfs_trans_commit &
355 * xfs_trans_cancel will both unlock the inodes and
356 * decrement the associated ref counts.
357 */
358 VN_HOLD(vp);
359 VN_HOLD(tvp);
360 353
354 IHOLD(ip);
361 xfs_trans_ijoin(tp, ip, lock_flags); 355 xfs_trans_ijoin(tp, ip, lock_flags);
356
357 IHOLD(tip);
362 xfs_trans_ijoin(tp, tip, lock_flags); 358 xfs_trans_ijoin(tp, tip, lock_flags);
363 359
364 xfs_trans_log_inode(tp, ip, ilf_fields); 360 xfs_trans_log_inode(tp, ip, ilf_fields);