From: Erez_Zadok Date: Tue, 17 Jul 2007 03:45:46 +0000 (-0400) Subject: Unionfs: use igrab instead of atomic_inc inode refcnt X-Git-Url: https://git.fsl.cs.sunysb.edu/?a=commitdiff_plain;h=57f24466cf4cf387c88fe0af3aeba169e66c26d8;p=unionfs-3.4.y.git Unionfs: use igrab instead of atomic_inc inode refcnt In branch management code, use igrab() which is better than directly incrementing the lower inode reference count. Signed-off-by: Erez Zadok --- diff --git a/fs/unionfs/super.c b/fs/unionfs/super.c index c168b2383c37..f4118dfa0a36 100644 --- a/fs/unionfs/super.c +++ b/fs/unionfs/super.c @@ -740,7 +740,7 @@ out_no_change: for (i=dbstart(sb->s_root); i<=dbend(sb->s_root); i++) { struct dentry *lower_dentry = unionfs_lower_dentry_idx(sb->s_root, i); - atomic_inc(&lower_dentry->d_inode->i_count); + igrab(lower_dentry->d_inode); new_lower_inodes[i] = lower_dentry->d_inode; } /* 2. release reference on all older lower inodes */