[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAPcyv4hWksbxM5h4b4hCfs_MSggDoEDoxiu4sw2uj1N=z+mOcg@mail.gmail.com>
Date: Fri, 15 Nov 2019 08:41:55 -0800
From: Dan Williams <dan.j.williams@...el.com>
To: John Hubbard <jhubbard@...dia.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Christoph Hellwig <hch@...radead.org>,
Ira Weiny <ira.weiny@...el.com>, Jan Kara <jack@...e.cz>,
Jason Gunthorpe <jgg@...pe.ca>, Jens Axboe <axboe@...nel.dk>,
Jérôme Glisse <jglisse@...hat.com>,
linux-nvdimm <linux-nvdimm@...ts.01.org>,
Linux MM <linux-mm@...ck.org>,
LKML <linux-kernel@...r.kernel.org>,
Christoph Hellwig <hch@....de>
Subject: Re: [PATCH 2/2] mm: devmap: refactor 1-based refcounting for
ZONE_DEVICE pages
On Thu, Nov 14, 2019 at 4:11 PM John Hubbard <jhubbard@...dia.com> wrote:
>
> An upcoming patch changes and complicates the refcounting and
> especially the "put page" aspects of it. In order to keep
> everything clean, refactor the devmap page release routines:
>
> * Rename put_devmap_managed_page() to page_is_devmap_managed(),
> and limit the functionality to "read only": return a bool,
> with no side effects.
>
> * Add a new routine, put_devmap_managed_page(), to handle checking
> what kind of page it is, and what kind of refcount handling it
> requires.
>
> * Rename __put_devmap_managed_page() to free_devmap_managed_page(),
> and limit the functionality to unconditionally freeing a devmap
> page.
>
> This is originally based on a separate patch by Ira Weiny, which
> applied to an early version of the put_user_page() experiments.
> Since then, Jérôme Glisse suggested the refactoring described above.
>
> Cc: Jan Kara <jack@...e.cz>
> Cc: Jérôme Glisse <jglisse@...hat.com>
> Cc: Christoph Hellwig <hch@....de>
> Cc: Dan Williams <dan.j.williams@...el.com>
> Suggested-by: Jérôme Glisse <jglisse@...hat.com>
> Signed-off-by: Ira Weiny <ira.weiny@...el.com>
> Signed-off-by: John Hubbard <jhubbard@...dia.com>
> ---
> include/linux/mm.h | 27 ++++++++++++++++++++++++---
> mm/memremap.c | 16 ++--------------
> 2 files changed, 26 insertions(+), 17 deletions(-)
Looks good,
Reviewed-by: Dan Williams <dan.j.williams@...el.com>
Powered by blists - more mailing lists