summaryrefslogtreecommitdiffstats
path: root/fs/exfat/super.c
diff options
context:
space:
mode:
authorHyeongseok Kim <hyeongseok@gmail.com>2021-03-02 06:05:20 +0100
committerNamjae Jeon <namjae.jeon@samsung.com>2021-04-27 13:45:06 +0200
commit5c2d728507299f84631ab8020d6f0f98f2cb8fc2 (patch)
treebaf8a7fed6645523987a98b3e66ac693227a4d4b /fs/exfat/super.c
parentexfat: fix erroneous discard when clear cluster bit (diff)
downloadlinux-5c2d728507299f84631ab8020d6f0f98f2cb8fc2.tar.xz
linux-5c2d728507299f84631ab8020d6f0f98f2cb8fc2.zip
exfat: introduce bitmap_lock for cluster bitmap access
s_lock which is for protecting concurrent access of file operations is too huge for cluster bitmap protection, so introduce a new bitmap_lock to narrow the lock range if only need to access cluster bitmap. Signed-off-by: Hyeongseok Kim <hyeongseok@gmail.com> Acked-by: Sungjong Seo <sj1557.seo@samsung.com> Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com>
Diffstat (limited to '')
-rw-r--r--fs/exfat/super.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/exfat/super.c b/fs/exfat/super.c
index c6d8d2e53486..d38d17a77e76 100644
--- a/fs/exfat/super.c
+++ b/fs/exfat/super.c
@@ -752,6 +752,7 @@ static int exfat_init_fs_context(struct fs_context *fc)
return -ENOMEM;
mutex_init(&sbi->s_lock);
+ mutex_init(&sbi->bitmap_lock);
ratelimit_state_init(&sbi->ratelimit, DEFAULT_RATELIMIT_INTERVAL,
DEFAULT_RATELIMIT_BURST);