projects
/
linux-2.6-microblaze.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
afb6ffa
)
exfat: reuse cache to improve exfat_get_cluster
author
Chi Zhiling
<chizhiling@kylinos.cn>
Wed, 14 Jan 2026 12:12:44 +0000
(20:12 +0800)
committer
Namjae Jeon
<linkinjeon@kernel.org>
Thu, 12 Feb 2026 12:21:50 +0000
(21:21 +0900)
Since exfat_ent_get supports cache buffer head, we can use this option to
reduce sb_bread calls when fetching consecutive entries.
Signed-off-by: Chi Zhiling <chizhiling@kylinos.cn>
Reviewed-by: Yuezhang Mo <Yuezhang.Mo@sony.com>
Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
fs/exfat/cache.c
patch
|
blob
|
history
diff --git
a/fs/exfat/cache.c
b/fs/exfat/cache.c
index
b806e7f
..
025b39b
100644
(file)
--- a/
fs/exfat/cache.c
+++ b/
fs/exfat/cache.c
@@
-238,6
+238,7
@@
int exfat_get_cluster(struct inode *inode, unsigned int cluster,
{
struct super_block *sb = inode->i_sb;
struct exfat_inode_info *ei = EXFAT_I(inode);
+ struct buffer_head *bh = NULL;
struct exfat_cache_id cid;
unsigned int content, fclus;
@@
-265,7
+266,7
@@
int exfat_get_cluster(struct inode *inode, unsigned int cluster,
return 0;
while (fclus < cluster) {
- if (exfat_ent_get(sb, *dclus, &content,
NULL
))
+ if (exfat_ent_get(sb, *dclus, &content,
&bh
))
return -EIO;
*last_dclus = *dclus;
@@
-279,6
+280,7
@@
int exfat_get_cluster(struct inode *inode, unsigned int cluster,
cache_init(&cid, fclus, *dclus);
}
+ brelse(bh);
exfat_cache_add(inode, &cid);
return 0;
}