mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-20 21:51:05 +00:00
fs: Replace current_fs_time() with current_time()
current_fs_time() uses struct super_block* as an argument. As per Linus's suggestion, this is changed to take struct inode* as a parameter instead. This is because the function is primarily meant for vfs inode timestamps. Also the function was renamed as per Arnd's suggestion. Change all calls to current_fs_time() to use the new current_time() function instead. current_fs_time() will be deleted. Signed-off-by: Deepa Dinamani <deepa.kernel@gmail.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
parent
02027d42c3
commit
c2050a454c
34 changed files with 70 additions and 70 deletions
|
@ -616,7 +616,7 @@ static int udf_add_nondir(struct dentry *dentry, struct inode *inode)
|
|||
*(__le32 *)((struct allocDescImpUse *)cfi.icb.impUse)->impUse =
|
||||
cpu_to_le32(iinfo->i_unique & 0x00000000FFFFFFFFUL);
|
||||
udf_write_fi(dir, &cfi, fi, &fibh, NULL, NULL);
|
||||
dir->i_ctime = dir->i_mtime = current_fs_time(dir->i_sb);
|
||||
dir->i_ctime = dir->i_mtime = current_time(dir);
|
||||
mark_inode_dirty(dir);
|
||||
if (fibh.sbh != fibh.ebh)
|
||||
brelse(fibh.ebh);
|
||||
|
@ -730,7 +730,7 @@ static int udf_mkdir(struct inode *dir, struct dentry *dentry, umode_t mode)
|
|||
cfi.fileCharacteristics |= FID_FILE_CHAR_DIRECTORY;
|
||||
udf_write_fi(dir, &cfi, fi, &fibh, NULL, NULL);
|
||||
inc_nlink(dir);
|
||||
dir->i_ctime = dir->i_mtime = current_fs_time(dir->i_sb);
|
||||
dir->i_ctime = dir->i_mtime = current_time(dir);
|
||||
mark_inode_dirty(dir);
|
||||
unlock_new_inode(inode);
|
||||
d_instantiate(dentry, inode);
|
||||
|
@ -845,7 +845,7 @@ static int udf_rmdir(struct inode *dir, struct dentry *dentry)
|
|||
inode->i_size = 0;
|
||||
inode_dec_link_count(dir);
|
||||
inode->i_ctime = dir->i_ctime = dir->i_mtime =
|
||||
current_fs_time(dir->i_sb);
|
||||
current_time(inode);
|
||||
mark_inode_dirty(dir);
|
||||
|
||||
end_rmdir:
|
||||
|
@ -888,7 +888,7 @@ static int udf_unlink(struct inode *dir, struct dentry *dentry)
|
|||
retval = udf_delete_entry(dir, fi, &fibh, &cfi);
|
||||
if (retval)
|
||||
goto end_unlink;
|
||||
dir->i_ctime = dir->i_mtime = current_fs_time(dir->i_sb);
|
||||
dir->i_ctime = dir->i_mtime = current_time(dir);
|
||||
mark_inode_dirty(dir);
|
||||
inode_dec_link_count(inode);
|
||||
inode->i_ctime = dir->i_ctime;
|
||||
|
@ -1079,9 +1079,9 @@ static int udf_link(struct dentry *old_dentry, struct inode *dir,
|
|||
brelse(fibh.ebh);
|
||||
brelse(fibh.sbh);
|
||||
inc_nlink(inode);
|
||||
inode->i_ctime = current_fs_time(inode->i_sb);
|
||||
inode->i_ctime = current_time(inode);
|
||||
mark_inode_dirty(inode);
|
||||
dir->i_ctime = dir->i_mtime = current_fs_time(dir->i_sb);
|
||||
dir->i_ctime = dir->i_mtime = current_time(dir);
|
||||
mark_inode_dirty(dir);
|
||||
ihold(inode);
|
||||
d_instantiate(dentry, inode);
|
||||
|
@ -1172,7 +1172,7 @@ static int udf_rename(struct inode *old_dir, struct dentry *old_dentry,
|
|||
* Like most other Unix systems, set the ctime for inodes on a
|
||||
* rename.
|
||||
*/
|
||||
old_inode->i_ctime = current_fs_time(old_inode->i_sb);
|
||||
old_inode->i_ctime = current_time(old_inode);
|
||||
mark_inode_dirty(old_inode);
|
||||
|
||||
/*
|
||||
|
@ -1188,11 +1188,11 @@ static int udf_rename(struct inode *old_dir, struct dentry *old_dentry,
|
|||
udf_delete_entry(old_dir, ofi, &ofibh, &ocfi);
|
||||
|
||||
if (new_inode) {
|
||||
new_inode->i_ctime = current_fs_time(new_inode->i_sb);
|
||||
new_inode->i_ctime = current_time(new_inode);
|
||||
inode_dec_link_count(new_inode);
|
||||
}
|
||||
old_dir->i_ctime = old_dir->i_mtime = current_fs_time(old_dir->i_sb);
|
||||
new_dir->i_ctime = new_dir->i_mtime = current_fs_time(new_dir->i_sb);
|
||||
old_dir->i_ctime = old_dir->i_mtime = current_time(old_dir);
|
||||
new_dir->i_ctime = new_dir->i_mtime = current_time(new_dir);
|
||||
mark_inode_dirty(old_dir);
|
||||
mark_inode_dirty(new_dir);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue