aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2022-06-26 08:41:04 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2022-06-26 08:41:04 -0700
commit97d4d0269706c468ec57cbb95a79f1a5c8fd1892 (patch)
treed5f610e8e3f4277bada5044a0c7c8e436a981dbd /fs
parentMerge tag '5.19-rc3-smb3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6 (diff)
parentexfat: use updated exfat_chain directly during renaming (diff)
downloadlinux-dev-97d4d0269706c468ec57cbb95a79f1a5c8fd1892.tar.xz
linux-dev-97d4d0269706c468ec57cbb95a79f1a5c8fd1892.zip
Merge tag 'exfat-for-5.19-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/linkinjeon/exfat
Pull exfat fix from Namjae Jeon: - Use updated exfat_chain directly instead of snapshot values in rename. * tag 'exfat-for-5.19-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/linkinjeon/exfat: exfat: use updated exfat_chain directly during renaming
Diffstat (limited to 'fs')
-rw-r--r--fs/exfat/namei.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/exfat/namei.c b/fs/exfat/namei.c
index 76acc3721951..c6eaf7e9ea74 100644
--- a/fs/exfat/namei.c
+++ b/fs/exfat/namei.c
@@ -1198,7 +1198,9 @@ static int __exfat_rename(struct inode *old_parent_inode,
return -ENOENT;
}
- exfat_chain_dup(&olddir, &ei->dir);
+ exfat_chain_set(&olddir, EXFAT_I(old_parent_inode)->start_clu,
+ EXFAT_B_TO_CLU_ROUND_UP(i_size_read(old_parent_inode), sbi),
+ EXFAT_I(old_parent_inode)->flags);
dentry = ei->entry;
ep = exfat_get_dentry(sb, &olddir, dentry, &old_bh);