From: Baokun Li Date: Fri, 21 Nov 2025 09:06:35 +0000 (+0800) Subject: ext4: enable DIOREAD_NOLOCK by default for BS > PS as well X-Git-Tag: v6.19-rc1~161^2~20 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=58297412edf077870eedce2481db5755b4e98474;p=thirdparty%2Flinux.git ext4: enable DIOREAD_NOLOCK by default for BS > PS as well The dioread_nolock related processes already support large folio, so dioread_nolock is enabled by default regardless of whether the blocksize is less than, equal to, or greater than PAGE_SIZE. Signed-off-by: Baokun Li Reviewed-by: Zhang Yi Reviewed-by: Jan Kara Reviewed-by: Ojaswin Mujoo Message-ID: <20251121090654.631996-6-libaokun@huaweicloud.com> Signed-off-by: Theodore Ts'o --- diff --git a/fs/ext4/super.c b/fs/ext4/super.c index 707f890d674e5..f39679892e713 100644 --- a/fs/ext4/super.c +++ b/fs/ext4/super.c @@ -4392,8 +4392,7 @@ static void ext4_set_def_opts(struct super_block *sb, ((def_mount_opts & EXT4_DEFM_NODELALLOC) == 0)) set_opt(sb, DELALLOC); - if (sb->s_blocksize <= PAGE_SIZE) - set_opt(sb, DIOREAD_NOLOCK); + set_opt(sb, DIOREAD_NOLOCK); } static int ext4_handle_clustersize(struct super_block *sb)