From: Alistair Popple <apopple@nvidia.com>
To: Jason Gunthorpe <jgg@nvidia.com>
Cc: <akpm@linux-foundation.org>, <jglisse@redhat.com>,
<jhubbard@nvidia.com>, <ziy@nvidia.com>, <rcampbell@nvidia.com>,
<Felix.Kuehling@amd.com>, <linux-mm@kvack.org>,
<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] mm/hmm.c: Allow VM_MIXEDMAP to work with hmm_range_fault
Date: Mon, 8 Nov 2021 18:58:01 +1100 [thread overview]
Message-ID: <5535346.2Y9IAguWGx@nvdebian> (raw)
In-Reply-To: <20211105122557.GA2744544@nvidia.com>
On Friday, 5 November 2021 11:25:57 PM AEDT Jason Gunthorpe wrote:
> On Thu, Nov 04, 2021 at 12:20:01PM +1100, Alistair Popple wrote:
> > hmm_range_fault() can be used instead of get_user_pages() for devices
> > which allow faulting however unlike get_user_pages() it will return an
> > error when used on a VM_MIXEDMAP range.
> >
> > To make hmm_range_fault() more closely match get_user_pages() remove
> > this restriction. This requires dealing with the !ARCH_HAS_PTE_SPECIAL
> > case in hmm_vma_handle_pte(). Rather than replicating the logic of
> > vm_normal_page() call it directly and do a check for the zero pfn
> > similar to what get_user_pages() currently does.
> >
> > Also add a test to hmm selftest to verify functionality.
>
> Please add a fixes line
This has been the case since hmm_vma_get_pfns() was first introduced. Therefore
the fixes line is:
Fixes: da4c3c735ea4 ("mm/hmm/mirror: helper to snapshot CPU page table")
Should I send a v2 adding that tag or does Andrew normally pick these up along
with the Reviewed-by?
Thanks.
> > Signed-off-by: Alistair Popple <apopple@nvidia.com>
> > ---
> > lib/test_hmm.c | 24 +++++++++++++++
> > mm/hmm.c | 5 +--
> > tools/testing/selftests/vm/hmm-tests.c | 42 ++++++++++++++++++++++++++
> > 3 files changed, 69 insertions(+), 2 deletions(-)
>
> Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>
>
> Jason
>
next prev parent reply other threads:[~2021-11-08 7:58 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-04 1:20 [PATCH] mm/hmm.c: Allow VM_MIXEDMAP to work with hmm_range_fault Alistair Popple
2021-11-05 12:25 ` Jason Gunthorpe
2021-11-08 7:58 ` Alistair Popple [this message]
2021-11-16 4:48 ` Andrew Morton
2021-11-16 7:15 ` Alistair Popple
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5535346.2Y9IAguWGx@nvdebian \
--to=apopple@nvidia.com \
--cc=Felix.Kuehling@amd.com \
--cc=akpm@linux-foundation.org \
--cc=jgg@nvidia.com \
--cc=jglisse@redhat.com \
--cc=jhubbard@nvidia.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=rcampbell@nvidia.com \
--cc=ziy@nvidia.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.