Re: [PATCH] 9p/virtio: restrict page pinning to user_backed_iter() iovec

David Howells
2025-12-19T12:03:44Z

Dominique Martinet <asmadeus@codewreck.org> wrote:

> FWIW I tried logging and saw ITER_BVEC, ITER_KVEC and ITER_FOLIOQ --
> O_DIRECT writes are seen as BVEC so I guess it's not as direct as I
> expected them to be -- that code could very well be leftovers from
> the switch to iov_iter back in 2015...

ITER_FOLIOQ should only be seen from buffered I/O. For unbuffered/direct I/O,
user-backed writes are extracted to ITER_BVEC; kernel-backed writes are
sliced, but the original iter type comes down. For the moment.

David