From: Keith Busch <kbusch@xxxxxxxxxx> Previous version: https://lore.kernel.org/linux-block/20250819164922.640964-1-kbusch@xxxxxxxx/ This series removes the direct io requirement that io vector lengths align to the logical block size. There are two primary benefits from doing this: 1. It allows user space more flexibility in what kind of io vectors are accepted, removing the need to bounce their data to specially aligned buffers. 2. By moving the alignment checks to later when the segments are already being checked, we remove one more iov walk per IO, reducing CPU utilization and submission latency. Same as previously, I've tested direct IO on raw block, xfs, ext4, and btrfs. Changes from v3: - Added reviews - Code style and comment updates Keith Busch (8): block: check for valid bio while splitting block: add size alignment to bio_iov_iter_get_pages block: align the bio after building it block: simplify direct io validity check iomap: simplify direct io validity check block: remove bdev_iter_is_aligned blk-integrity: use simpler alignment check iov_iter: remove iov_iter_is_aligned block/bio-integrity.c | 4 +- block/bio.c | 64 ++++++++++++++++++---------- block/blk-map.c | 2 +- block/blk-merge.c | 21 ++++++++-- block/fops.c | 10 ++--- fs/iomap/direct-io.c | 5 +-- include/linux/bio.h | 13 ++++-- include/linux/blkdev.h | 21 ++++++---- include/linux/uio.h | 2 - lib/iov_iter.c | 95 ------------------------------------------ 10 files changed, 92 insertions(+), 145 deletions(-) -- 2.47.3