From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Wed, 10 Oct 2018 10:03:26 +0200 From: Jan Kara To: john.hubbard@gmail.com Cc: Matthew Wilcox , Michal Hocko , Christopher Lameter , Jason Gunthorpe , Dan Williams , Jan Kara , linux-mm@kvack.org, LKML , linux-rdma , linux-fsdevel@vger.kernel.org, John Hubbard , Al Viro , Jerome Glisse , Christoph Hellwig , Ralph Campbell Subject: Re: [PATCH v5 2/3] mm: introduce put_user_page*(), placeholder versions Message-ID: <20181010080326.GB11507@quack2.suse.cz> References: <20181010041134.14096-1-jhubbard@nvidia.com> <20181010041134.14096-3-jhubbard@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20181010041134.14096-3-jhubbard@nvidia.com> Sender: owner-linux-mm@kvack.org List-ID: On Tue 09-10-18 21:11:33, john.hubbard@gmail.com wrote: > +/* > + * put_user_pages() - for each page in the @pages array, release the page > + * using put_user_page(). > + * > + * Please see the put_user_page() documentation for details. > + * > + * This is just like put_user_pages_dirty(), except that it invokes > + * set_page_dirty_lock(), instead of set_page_dirty(). This paragraph should be deleted. Other than that the patch looks good. Honza > + * > + * @pages: array of pages to be marked dirty and released. > + * @npages: number of pages in the @pages array. > + * > + */ > +void put_user_pages(struct page **pages, unsigned long npages) > +{ > + unsigned long index; > + > + for (index = 0; index < npages; index++) > + put_user_page(pages[index]); > +} > +EXPORT_SYMBOL(put_user_pages); > + > /* > * get_kernel_pages() - pin kernel pages in memory > * @kiov: An array of struct kvec structures > -- > 2.19.1 > -- Jan Kara SUSE Labs, CR