Merge remote-tracking branch 'ovl/rename2' into for-linus
[cascardo/linux.git] / fs / libfs.c
index 4758353..d8ee308 100644 (file)
@@ -265,7 +265,7 @@ struct dentry *mount_pseudo(struct file_system_type *fs_type, char *name,
         */
        root->i_ino = 1;
        root->i_mode = S_IFDIR | S_IRUSR | S_IWUSR;
-       root->i_atime = root->i_mtime = root->i_ctime = CURRENT_TIME;
+       root->i_atime = root->i_mtime = root->i_ctime = current_time(root);
        dentry = __d_alloc(s, &d_name);
        if (!dentry) {
                iput(root);
@@ -295,7 +295,7 @@ int simple_link(struct dentry *old_dentry, struct inode *dir, struct dentry *den
 {
        struct inode *inode = d_inode(old_dentry);
 
-       inode->i_ctime = dir->i_ctime = dir->i_mtime = CURRENT_TIME;
+       inode->i_ctime = dir->i_ctime = dir->i_mtime = current_time(inode);
        inc_nlink(inode);
        ihold(inode);
        dget(dentry);
@@ -329,7 +329,7 @@ int simple_unlink(struct inode *dir, struct dentry *dentry)
 {
        struct inode *inode = d_inode(dentry);
 
-       inode->i_ctime = dir->i_ctime = dir->i_mtime = CURRENT_TIME;
+       inode->i_ctime = dir->i_ctime = dir->i_mtime = current_time(inode);
        drop_nlink(inode);
        dput(dentry);
        return 0;
@@ -373,7 +373,7 @@ int simple_rename(struct inode *old_dir, struct dentry *old_dentry,
        }
 
        old_dir->i_ctime = old_dir->i_mtime = new_dir->i_ctime =
-               new_dir->i_mtime = inode->i_ctime = CURRENT_TIME;
+               new_dir->i_mtime = inode->i_ctime = current_time(old_dir);
 
        return 0;
 }
@@ -524,7 +524,7 @@ int simple_fill_super(struct super_block *s, unsigned long magic,
         */
        inode->i_ino = 1;
        inode->i_mode = S_IFDIR | 0755;
-       inode->i_atime = inode->i_mtime = inode->i_ctime = CURRENT_TIME;
+       inode->i_atime = inode->i_mtime = inode->i_ctime = current_time(inode);
        inode->i_op = &simple_dir_inode_operations;
        inode->i_fop = &simple_dir_operations;
        set_nlink(inode, 2);
@@ -550,7 +550,7 @@ int simple_fill_super(struct super_block *s, unsigned long magic,
                        goto out;
                }
                inode->i_mode = S_IFREG | files->mode;
-               inode->i_atime = inode->i_mtime = inode->i_ctime = CURRENT_TIME;
+               inode->i_atime = inode->i_mtime = inode->i_ctime = current_time(inode);
                inode->i_fop = files->ops;
                inode->i_ino = i;
                d_add(dentry, inode);
@@ -1096,7 +1096,7 @@ struct inode *alloc_anon_inode(struct super_block *s)
        inode->i_uid = current_fsuid();
        inode->i_gid = current_fsgid();
        inode->i_flags |= S_PRIVATE;
-       inode->i_atime = inode->i_mtime = inode->i_ctime = CURRENT_TIME;
+       inode->i_atime = inode->i_mtime = inode->i_ctime = current_time(inode);
        return inode;
 }
 EXPORT_SYMBOL(alloc_anon_inode);