[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170428063913.iz6xjcxblecofjlq@gmail.com>
Date: Fri, 28 Apr 2017 08:39:13 +0200
From: Ingo Molnar <mingo@...nel.org>
To: "Kirill A. Shutemov" <kirill@...temov.name>
Cc: Dan Williams <dan.j.williams@...el.com>,
Ingo Molnar <mingo@...hat.com>, akpm@...ux-foundation.org,
linux-mm@...ck.org,
Jérôme Glisse <jglisse@...hat.com>,
Logan Gunthorpe <logang@...tatee.com>,
linux-kernel@...r.kernel.org,
Kirill Shutemov <kirill.shutemov@...ux.intel.com>
Subject: Re: [PATCH] mm, zone_device: replace {get, put}_zone_device_page()
with a single reference
* Kirill A. Shutemov <kirill@...temov.name> wrote:
> On Wed, Apr 26, 2017 at 05:55:31PM -0700, Dan Williams wrote:
> > Kirill points out that the calls to {get,put}_dev_pagemap() can be
> > removed from the mm fast path if we take a single get_dev_pagemap()
> > reference to signify that the page is alive and use the final put of the
> > page to drop that reference.
> >
> > This does require some care to make sure that any waits for the
> > percpu_ref to drop to zero occur *after* devm_memremap_page_release(),
> > since it now maintains its own elevated reference.
> >
> > Cc Ingo Molnar <mingo@...hat.com>
> > Cc: Jérôme Glisse <jglisse@...hat.com>
> > Cc: Logan Gunthorpe <logang@...tatee.com>
> > Cc: Andrew Morton <akpm@...ux-foundation.org>
> > Suggested-by: Kirill Shutemov <kirill.shutemov@...ux.intel.com>
> > Signed-off-by: Dan Williams <dan.j.williams@...el.com>
> > ---
> >
> > This patch might fix the regression that we found with the conversion to
> > generic get_user_pages_fast() in the x86/mm branch pending for 4.12
> > (commit 2947ba054a4d "x86/mm/gup: Switch GUP to the generic
> > get_user_page_fast() implementation"). I'll test tomorrow, but in case
> > someone can give it a try before I wake up, here's an early version.
>
> + Ingo.
>
> This works for me with and without GUP revert.
>
> Tested-by: Kirill A. Shutemov <kirill.shutemov@...ux.intel.com>
>
> > drivers/dax/pmem.c | 2 +-
> > drivers/nvdimm/pmem.c | 13 +++++++++++--
>
> There's a trivial conflict in drivers/nvdimm/pmem.c when applied to
> tip/master.
Ok, could someone please send a version either to Linus for v4.11, or a version
against latest -tip so I can included it in x86/mm, so that x86/mm gets unbroken.
Thanks,
Ingo
Powered by blists - more mailing lists