]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
exfat: support multi-cluster for exfat_get_cluster
authorChi Zhiling <chizhiling@kylinos.cn>
Wed, 14 Jan 2026 12:18:08 +0000 (20:18 +0800)
committerNamjae Jeon <linkinjeon@kernel.org>
Thu, 12 Feb 2026 12:21:51 +0000 (21:21 +0900)
commit9276e330c17b6c926bdc5da90cbc58d6c4f26298
tree1660767f743cf3ddf7c8daf937456ed7137a7952
parent9fb696a10a6735a15a0d2b4370419702e99818d0
exfat: support multi-cluster for exfat_get_cluster

This patch introduces a count parameter to exfat_get_cluster, which
serves as an input parameter for the caller to specify the desired
number of clusters, and as an output parameter to store the length
of consecutive clusters.

This patch can improve read performance by reducing the number of
get_block calls in sequential read scenarios. speacially in small
cluster size.

According to my test data, the performance improvement is
approximately 10% when read FAT_CHAIN file with 512 bytes of
cluster size.

454 MB/s -> 511 MB/s

Suggested-by: Yuezhang Mo <Yuezhang.Mo@sony.com>
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
fs/exfat/exfat_fs.h
fs/exfat/inode.c