]> www.infradead.org Git - users/jedix/linux-maple.git/commit
ext4: make __ext4_block_zero_page_range() support large folio
authorZhang Yi <yi.zhang@huawei.com>
Mon, 12 May 2025 06:33:14 +0000 (14:33 +0800)
committerTheodore Ts'o <tytso@mit.edu>
Tue, 20 May 2025 14:31:12 +0000 (10:31 -0400)
commit2e9466fc5d7c74a0aeeb388c3c2a4c02b7069d58
treea8c380d0799cdede9f880dc8acafcbc1de419e06
parent16705e52e6291c6ab4249aaf1cdf0b8e88afe775
ext4: make __ext4_block_zero_page_range() support large folio

The partial block zero range helper __ext4_block_zero_page_range()
currently only supports folios of PAGE_SIZE in size. The calculations
for the start block and the offset within a folio for the given range
are incorrect. Modify the implementation to use offset_in_folio()
instead of directly masking PAGE_SIZE - 1, which will be able to support
for large folios.

Signed-off-by: Zhang Yi <yi.zhang@huawei.com>
Link: https://patch.msgid.link/20250512063319.3539411-4-yi.zhang@huaweicloud.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
fs/ext4/inode.c