Re: [PATCH v2] block: Fix start and length check added to iov_iter_extract_bvecs()
From: David Howells
Date: Fri Sep 04 2026 - 06:21:01 EST
Christoph Hellwig <hch@xxxxxx> wrote:
> Should this grow a comment explaining why for non-iov/kvec/ubuf
> we check the alignment of every sector instead of just the
> start alignment?
There should possibly be a comment explaining the need for an address
alignment at all. Is it mandatory for all devices? Or are we being a bit
over restrictive? I don't think NICs capable of RDMA are so restricted, for
example.
Note that iov_iter_alignment() for ITER_XARRAY and ITER_FOLIOQ basically just
check iov_offset and count anyway as they refer to whole pages/folios only,
with just the start and end reduced.
David