[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <3396eec4-a469-5b95-06db-c40e5616465b@redhat.com>
Date: Fri, 27 Jan 2023 01:20:05 +0100
From: David Hildenbrand <david@...hat.com>
To: David Howells <dhowells@...hat.com>
Cc: Al Viro <viro@...iv.linux.org.uk>,
Christoph Hellwig <hch@...radead.org>,
Matthew Wilcox <willy@...radead.org>,
Jens Axboe <axboe@...nel.dk>, Jan Kara <jack@...e.cz>,
Jeff Layton <jlayton@...nel.org>,
Logan Gunthorpe <logang@...tatee.com>,
linux-fsdevel@...r.kernel.org, linux-block@...r.kernel.org,
linux-kernel@...r.kernel.org, Christoph Hellwig <hch@....de>,
John Hubbard <jhubbard@...dia.com>, linux-mm@...ck.org
Subject: Re: [PATCH v7 2/8] iov_iter: Add a function to extract a page list
from an iterator
On 27.01.23 01:05, David Howells wrote:
> David Hildenbrand <david@...hat.com> wrote:
>
>> As raised already somewhere in the whole discussion by me, the right way to
>> take such a long-term ping as vmsplice() does is to use
>> FOLL_PIN|FOLL_LONGTERM.
>
> So the pipe infrastructure would have to be able to pin pages instead of
> carrying refs on them? What about pages just allocated and added to the pipe
> ring in normal pipe use?
Ordinary kernel allocations (alloc_page() ...) always have to be freed
via put_page() and friends. Such allocations are unmovable as default
and don't require any special care.
Pages mapped into user space are movable as default and might be placed
on ZONE_MOVABLE/CMA memory (well, and might be swapped out).
FOLL_LONGTERM makes sure to migrate these pages off of such problematic
physical memory regions, such that we can safely pin them until eternity.
--
Thanks,
David / dhildenb
Powered by blists - more mailing lists