]> git.ipfire.org Git - thirdparty/linux.git/commit
iomap: use find_next_bit() for uptodate bitmap scanning
authorJoanne Koong <joannelkoong@gmail.com>
Tue, 11 Nov 2025 19:36:58 +0000 (11:36 -0800)
committerChristian Brauner <brauner@kernel.org>
Tue, 25 Nov 2025 09:22:10 +0000 (10:22 +0100)
commitb56c1c54f225ca02d88ec562f017be23429bf5b2
treefea45515327234b0ae493c4e7ee2ece4185ba6de
parentfed9c62d28b726dad70cc03fd28ffd700b59c741
iomap: use find_next_bit() for uptodate bitmap scanning

Use find_next_bit()/find_next_zero_bit() for iomap uptodate bitmap
scanning. This uses __ffs() internally and is more efficient for
finding the next uptodate or non-uptodate bit than iterating through the
the bitmap range testing every bit.

Signed-off-by: Joanne Koong <joannelkoong@gmail.com>
Link: https://patch.msgid.link/20251111193658.3495942-10-joannelkoong@gmail.com
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Suggested-by: Christoph Hellwig <hch@infradead.org>
Signed-off-by: Christian Brauner <brauner@kernel.org>
fs/iomap/buffered-io.c