Skip to content

Commit 3bcfb70

Browse files
committed
exfat: move setting VOL_DIRTY over exfat_remove_entries()
Move setting VOL_DIRTY over exfat_remove_entries() to avoid unneeded leaving VOL_DIRTY on -ENOTEMPTY. Fixes: 5f2aa07 ("exfat: add inode operations") Cc: [email protected] # v5.7 Reported-by: Tetsuhiro Kohada <[email protected]> Reviewed-by: Sungjong Seo <[email protected]> Signed-off-by: Namjae Jeon <[email protected]>
1 parent a0271a1 commit 3bcfb70

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fs/exfat/namei.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -975,7 +975,6 @@ static int exfat_rmdir(struct inode *dir, struct dentry *dentry)
975975
goto unlock;
976976
}
977977

978-
exfat_set_vol_flags(sb, VOL_DIRTY);
979978
exfat_chain_set(&clu_to_free, ei->start_clu,
980979
EXFAT_B_TO_CLU_ROUND_UP(i_size_read(inode), sbi), ei->flags);
981980

@@ -1002,6 +1001,7 @@ static int exfat_rmdir(struct inode *dir, struct dentry *dentry)
10021001
num_entries++;
10031002
brelse(bh);
10041003

1004+
exfat_set_vol_flags(sb, VOL_DIRTY);
10051005
err = exfat_remove_entries(dir, &cdir, entry, 0, num_entries);
10061006
if (err) {
10071007
exfat_err(sb, "failed to exfat_remove_entries : err(%d)", err);

0 commit comments

Comments
 (0)