Re: [RFC net-next v3 05/29] net: bvec specific path in zerocopy_sg_from_iter

From: Al Viro
Date: Tue Jun 28 2022 - 16:14:02 EST


On Tue, Jun 28, 2022 at 07:56:27PM +0100, Pavel Begunkov wrote:
> Add an bvec specialised and optimised path in zerocopy_sg_from_iter.
> It'll be used later for {get,put}_page() optimisations.

If you need a variant that would not grab page references for ITER_BVEC
(and presumably other non-userland ones), the natural thing to do would
be to provide just such a primitive, wouldn't it?

The fun question here is by which paths ITER_BVEC can be passed to that
function and which all of them are currently guaranteed to hold the
underlying pages pinned...

And AFAICS you quietly assume that only ITER_BVEC ones will ever have that
"managed" flag of your set. Or am I misreading the next patch in the
series?