summaryrefslogtreecommitdiff
path: root/fs/ext3
diff options
context:
space:
mode:
authorDave Hansen <haveblue@us.ibm.com>2006-09-30 23:29:04 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2006-10-01 00:39:30 -0700
commitd8c76e6f45c111c32a4b3e50a2adc9210737b0d8 (patch)
tree25521b59d48c6d8c9aec1af54dbe5008ad4b215b /fs/ext3
parent9a53c3a783c2fa9b969628e65695c11c3e51e673 (diff)
[PATCH] r/o bind mount prepwork: inc_nlink() helper
This is mostly included for parity with dec_nlink(), where we will have some more hooks. This one should stay pretty darn straightforward for now. Signed-off-by: Dave Hansen <haveblue@us.ibm.com> Acked-by: Christoph Hellwig <hch@lst.de> Cc: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/ext3')
-rw-r--r--fs/ext3/namei.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/ext3/namei.c b/fs/ext3/namei.c
index 14c55adfae83..b45c88bd5f73 100644
--- a/fs/ext3/namei.c
+++ b/fs/ext3/namei.c
@@ -1616,7 +1616,7 @@ static int ext3_delete_entry (handle_t *handle,
*/
static inline void ext3_inc_count(handle_t *handle, struct inode *inode)
{
- inode->i_nlink++;
+ inc_nlink(inode);
}
static inline void ext3_dec_count(handle_t *handle, struct inode *inode)
@@ -1775,7 +1775,7 @@ retry:
iput (inode);
goto out_stop;
}
- dir->i_nlink++;
+ inc_nlink(dir);
ext3_update_dx_flag(dir);
ext3_mark_inode_dirty(handle, dir);
d_instantiate(dentry, inode);
@@ -2341,7 +2341,7 @@ static int ext3_rename (struct inode * old_dir, struct dentry *old_dentry,
if (new_inode) {
drop_nlink(new_inode);
} else {
- new_dir->i_nlink++;
+ inc_nlink(new_dir);
ext3_update_dx_flag(new_dir);
ext3_mark_inode_dirty(handle, new_dir);
}