]> git.ipfire.org Git - thirdparty/linux.git/commit
iomap: simplify iomap_dio_bio_iter
authorChristoph Hellwig <hch@lst.de>
Mon, 26 Jan 2026 05:53:39 +0000 (06:53 +0100)
committerJens Axboe <axboe@kernel.dk>
Wed, 28 Jan 2026 12:16:39 +0000 (05:16 -0700)
commit6e7a6c80198ead08b11aa6cdc92e60a42fc5895f
treec03271e4e2f91c8397f7cf6a42636e529931eccd
parent4ad357e39b2ecd5da7bcc7e840ee24d179593cd5
iomap: simplify iomap_dio_bio_iter

Use iov_iter_count to check if we need to continue as that just reads
a field in the iov_iter, and only use bio_iov_vecs_to_alloc to calculate
the actual number of vectors to allocate for the bio.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Damien Le Moal <dlemoal@kernel.org>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Tested-by: Anuj Gupta <anuj20.g@samsung.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/iomap/direct-io.c