linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Matthew Wilcox <willy@infradead.org>
To: Peter Xu <peterx@redhat.com>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-arm-kernel@lists.infradead.org, linux-s390@vger.kernel.org
Subject: Re: [PATCH 0/3] mm/arch: Fix a few collide definition on private use of VM_FAULT_*
Date: Mon, 6 Feb 2023 02:51:18 +0000	[thread overview]
Message-ID: <Y+BrJhxeJbAp49QE@casper.infradead.org> (raw)
In-Reply-To: <Y+BPy3jFcHqOnWL0@x1n>

On Sun, Feb 05, 2023 at 07:54:35PM -0500, Peter Xu wrote:
> On Mon, Feb 06, 2023 at 12:10:53AM +0000, Matthew Wilcox wrote:
> > On Sun, Feb 05, 2023 at 06:17:01PM -0500, Peter Xu wrote:
> > > I noticed a few collision usage on VM_FAULT_* definition in the page fault
> > > path on arm/arm64/s390 where the VM_FAULT_* can overlap with the generic
> > > definition of vm_fault_reason.
> > > 
> > > The major overlapped part being VM_FAULT_HINDEX_MASK which is used only by
> > > the hugetlb hwpoisoning.
> > > 
> > > I'm not sure whether any of them can have a real impact, but that does not
> > > look like to be expected.  I didn't copy stable, if anyone thinks it should
> > > please shoot.  Nor did I test them in any form - I just changed the
> > > allocations from top bits and added a comment for each of them.
> > 
> > This seems like a bad way to do it.  Why not just put these VM_FAULT_*
> > definitions in linux/mm_types.h?  Then we'll see them when adding new
> > VM_FAULT codes.  Sure, they won't be used by every architecture, but
> > so what?
> 
> My initial version actually contains a few VM_FAULT_PRIVATE_N there, but I

That wasn't what I meant.  I meant putting VM_FAULT_BADMAP and
VM_FAULT_SIGSEGV in mm_types.h.  Not having "Here is a range of reserved
arch private ones".



  reply	other threads:[~2023-02-06  2:51 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-05 23:17 [PATCH 0/3] mm/arch: Fix a few collide definition on private use of VM_FAULT_* Peter Xu
2023-02-05 23:17 ` [PATCH 1/3] mm/arm: Define private VM_FAULT_* reasons from top bits Peter Xu
2023-02-05 23:17 ` [PATCH 2/3] mm/arm64: " Peter Xu
2023-02-05 23:17 ` [PATCH 3/3] mm/s390: " Peter Xu
2023-02-09 20:10   ` Heiko Carstens
2023-02-06  0:10 ` [PATCH 0/3] mm/arch: Fix a few collide definition on private use of VM_FAULT_* Matthew Wilcox
2023-02-06  0:54   ` Peter Xu
2023-02-06  2:51     ` Matthew Wilcox [this message]
2023-02-06  3:18       ` Peter Xu
2023-02-06  5:09         ` Matthew Wilcox
2023-02-09 20:04           ` Heiko Carstens

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=Y+BrJhxeJbAp49QE@casper.infradead.org \
    --to=willy@infradead.org \
    --cc=akpm@linux-foundation.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linux-s390@vger.kernel.org \
    --cc=peterx@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).