linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Peter Xu <peterx@redhat.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
	Andrea Arcangeli <aarcange@redhat.com>,
	Axel Rasmussen <axelrasmussen@google.com>,
	Nadav Amit <nadav.amit@gmail.com>, Li Wang <liwan@redhat.com>
Subject: Re: [PATCH] mm/userfaultfd: selftests: Fix memory corruption with thp enabled
Date: Fri, 24 Sep 2021 10:14:21 -0400	[thread overview]
Message-ID: <YU3dPTsNWVhEo/5y@t490s> (raw)
In-Reply-To: <20210923191941.da28da4400c11a3241a07acf@linux-foundation.org>

On Thu, Sep 23, 2021 at 07:19:41PM -0700, Andrew Morton wrote:
> On Thu, 23 Sep 2021 19:25:12 -0400 Peter Xu <peterx@redhat.com> wrote:
> 
> > In RHEL's gating selftests we've encountered memory corruption in the uffd
> > event test even with upstream kernel:
> > 
> > ...
> >
> > 
> > We can mark the Fixes tag upon 0db282ba2c12 as it's reported to only happen
> > there, however the real "Fixes" IMHO should be 8ba6e8640844, as before that
> > commit we'll always do explicit release_pages() before registration of uffd,
> > and 8ba6e8640844 changed that logic by adding extra unmap/map and we didn't
> > release the pages at the right place.  Meanwhile I don't have a solid glue
> > anyway on whether posix_memalign() could always avoid triggering this bug,
> > hence it's safer to attach this fix to commit 8ba6e8640844.
> > 
> 
> Thanks.  I added a cc:stable to this.  I don't think we want selftests
> in older kernels to be falsely reporting kernel bugs?

Not sure how we normally handle such case for selftests, but I agree.

Btw, 8ba6e8640844 is merged in 5.14, so the only stable branch that will need
it will be 5.14.y; it can be applied cleanly there.

Thanks,

-- 
Peter Xu


  reply	other threads:[~2021-09-24 14:14 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-23 23:25 [PATCH] mm/userfaultfd: selftests: Fix memory corruption with thp enabled Peter Xu
2021-09-24  2:19 ` Andrew Morton
2021-09-24 14:14   ` Peter Xu [this message]
2021-09-24 17:21 ` Axel Rasmussen
2021-09-24 19:59   ` Peter Xu
2021-09-27 17:34     ` Axel Rasmussen
2021-09-27 17:39       ` Peter Xu
2021-09-27 17:36     ` Peter Xu
2021-09-27 17:49       ` Axel Rasmussen
2021-09-27 20:37         ` Peter Xu

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=YU3dPTsNWVhEo/5y@t490s \
    --to=peterx@redhat.com \
    --cc=aarcange@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=axelrasmussen@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=liwan@redhat.com \
    --cc=nadav.amit@gmail.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).