aboutsummaryrefslogtreecommitdiffstats
path: root/fs/exfat/namei.c
diff options
context:
space:
mode:
authorYuezhang Mo <Yuezhang.Mo@sony.com>2022-06-29 11:05:51 +0800
committerNamjae Jeon <linkinjeon@kernel.org>2022-08-01 10:14:06 +0900
commitbe17b1ccd4e82a66b9d9676dec8edce137e967d8 (patch)
tree3d92a6365494e6251dbaf49c08cac8d8d9c79fc1 /fs/exfat/namei.c
parentexfat: remove duplicate write inode for truncating file (diff)
downloadlinux-dev-be17b1ccd4e82a66b9d9676dec8edce137e967d8.tar.xz
linux-dev-be17b1ccd4e82a66b9d9676dec8edce137e967d8.zip
exfat: remove duplicate write inode for extending dir/file
Since the timestamps need to be updated, the directory entries will be updated by mark_inode_dirty() whether or not a new cluster is allocated for the file or directory, so there is no need to use __exfat_write_inode() to update the directory entries when allocating a new cluster for a file or directory. Signed-off-by: Yuezhang Mo <Yuezhang.Mo@sony.com> Reviewed-by: Andy Wu <Andy.Wu@sony.com> Reviewed-by: Aoyama Wataru <wataru.aoyama@sony.com> Reviewed-by: Daniel Palmer <daniel.palmer@sony.com> Reviewed-by: Sungjong Seo <sj1557.seo@samsung.com> Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
Diffstat (limited to 'fs/exfat/namei.c')
-rw-r--r--fs/exfat/namei.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/fs/exfat/namei.c b/fs/exfat/namei.c
index d640f9de16a9..7fac9c4b60cf 100644
--- a/fs/exfat/namei.c
+++ b/fs/exfat/namei.c
@@ -388,10 +388,6 @@ static int exfat_find_empty_entry(struct inode *inode,
ei->i_size_aligned += sbi->cluster_size;
ei->flags = p_dir->flags;
inode->i_blocks += 1 << sbi->sect_per_clus_bits;
-
- /* update the directory entry */
- if (__exfat_write_inode(inode, IS_DIRSYNC(inode)))
- return -EIO;
}
return dentry;