From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Fri, 8 May 2015 11:26:01 +0200 From: Ingo Molnar Subject: Re: [PATCH v2 00/10] evacuate struct page from the block layer, introduce __pfn_t Message-ID: <20150508092601.GA11002@gmail.com> References: <20150507173641.GA21781@gmail.com> <554BA748.9030804@linux.intel.com> <20150507191107.GB22952@gmail.com> <20150507193635.GC5966@gmail.com> <20150507194832.GB23511@gmail.com> <20150507195313.GA23597@gmail.com> <20150507201815.GD5966@gmail.com> <20150508053759.GA25786@gmail.com> <20150508092044.GH889@ZenIV.linux.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150508092044.GH889@ZenIV.linux.org.uk> Sender: linux-fsdevel-owner@vger.kernel.org To: Al Viro Cc: Jerome Glisse , Dave Hansen , Dan Williams , Linus Torvalds , Linux Kernel Mailing List , Boaz Harrosh , Jan Kara , Mike Snitzer , Neil Brown , Benjamin Herrenschmidt , Heiko Carstens , Chris Mason , Paul Mackerras , "H. Peter Anvin" , Christoph Hellwig , Alasdair Kergon , "linux-nvdimm@lists.01.org" , Mel Gorman , Matthew Wilcox , Ross Zwisler , Rik van Riel , Martin Schwidefsky , Jens Axboe , Theodore Ts'o , "Martin K. Petersen" , Julia Lawall , Tejun Heo , linux-fsdevel , Andrew Morton , paulmck@linux.vnet.ibm.com List-ID: * Al Viro wrote: > On Fri, May 08, 2015 at 07:37:59AM +0200, Ingo Molnar wrote: > > > So if code does iov_iter_get_pages_alloc() on a user address that > > has a real struct page behind it - and some other code does a > > regular get_user_pages() on it, we'll have two sets of struct page > > descriptors, the 'real' one, and a fake allocated one, right? > > Huh? iov_iter_get_pages() is given an array of pointers to struct > page, which it fills with what it finds. iov_iter_get_pages_alloc() > *allocates* such an array, fills that with what it finds and gives > the allocated array to caller. > > We are not allocating any struct page instances in either of those. Ah, stupid me - thanks for the explanation! Ingo