mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
[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 <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Cc: Al Viro <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
9a53c3a783
commit
d8c76e6f45
37 changed files with 80 additions and 75 deletions
|
|
@ -1165,7 +1165,7 @@ static void udf_fill_inode(struct inode *inode, struct buffer_head *bh)
|
|||
inode->i_op = &udf_dir_inode_operations;
|
||||
inode->i_fop = &udf_dir_operations;
|
||||
inode->i_mode |= S_IFDIR;
|
||||
inode->i_nlink ++;
|
||||
inc_nlink(inode);
|
||||
break;
|
||||
}
|
||||
case ICBTAG_FILE_TYPE_REALTIME:
|
||||
|
|
|
|||
|
|
@ -762,7 +762,7 @@ static int udf_mkdir(struct inode * dir, struct dentry * dentry, int mode)
|
|||
cpu_to_le32(UDF_I_UNIQUE(inode) & 0x00000000FFFFFFFFUL);
|
||||
cfi.fileCharacteristics |= FID_FILE_CHAR_DIRECTORY;
|
||||
udf_write_fi(dir, &cfi, fi, &fibh, NULL, NULL);
|
||||
dir->i_nlink++;
|
||||
inc_nlink(dir);
|
||||
mark_inode_dirty(dir);
|
||||
d_instantiate(dentry, inode);
|
||||
if (fibh.sbh != fibh.ebh)
|
||||
|
|
@ -1147,7 +1147,7 @@ static int udf_link(struct dentry * old_dentry, struct inode * dir,
|
|||
if (fibh.sbh != fibh.ebh)
|
||||
udf_release_data(fibh.ebh);
|
||||
udf_release_data(fibh.sbh);
|
||||
inode->i_nlink ++;
|
||||
inc_nlink(inode);
|
||||
inode->i_ctime = current_fs_time(inode->i_sb);
|
||||
mark_inode_dirty(inode);
|
||||
atomic_inc(&inode->i_count);
|
||||
|
|
@ -1282,7 +1282,7 @@ static int udf_rename (struct inode * old_dir, struct dentry * old_dentry,
|
|||
}
|
||||
else
|
||||
{
|
||||
new_dir->i_nlink ++;
|
||||
inc_nlink(new_dir);
|
||||
mark_inode_dirty(new_dir);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue