From: Tal Zussman <tz2294@columbia.edu>
To: Andrew Morton <akpm@linux-foundation.org>,
Peter Xu <peterx@redhat.com>,
"Jason A. Donenfeld" <Jason@zx2c4.com>,
David Hildenbrand <david@redhat.com>,
Alexander Viro <viro@zeniv.linux.org.uk>,
Christian Brauner <brauner@kernel.org>, Jan Kara <jack@suse.cz>,
Andrea Arcangeli <aarcange@redhat.com>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
linux-fsdevel@vger.kernel.org, Tal Zussman <tz2294@columbia.edu>
Subject: [PATCH v3 0/4] mm: userfaultfd: assorted fixes and cleanups
Date: Thu, 19 Jun 2025 21:24:22 -0400 [thread overview]
Message-ID: <20250619-uffd-fixes-v3-0-a7274d3bd5e4@columbia.edu> (raw)
Two fixes and two cleanups for userfaultfd.
Note that the third patch yields a small change in the ABI, but we seem
to have concluded that that's acceptable in this case.
---
Changes in v3:
- Propagate tags. (David, Jason)
- Move the uffd unregistration fixes patch before the
VM_WARN_ON_ONCE() conversion patch, as per David.
- Update comments and commit message of 2/4, as per David.
- Update the commit message in 3/4 with more details about various
conversions, as per David.
- Convert two additional WARN_ON()s in 3/4, as per David.
- Link to v2: https://lore.kernel.org/r/20250607-uffd-fixes-v2-0-339dafe9a2fe@columbia.edu
Changes in v2:
- Remove Pavel Emelyanov <xemul@parallels.com> from To: due to bouncing
email.
- Propagate tags. (David, Peter)
- Add a patch converting userfaultfd BUG_ON()s to VM_WARN_ON_ONCE().
- Move the "different uffd" check in Patch 3 (prev. Patch 2) before the
vma_can_userfault() check due to the wp_async bug, as per James.
- Change the added BUG_ON() in Patch 3 to a VM_WARN_ON_ONCE, as per
James and David.
- Reorder the assertions in Patch 3 to simplify them and avoid the
wp_async bug, as per James.
- Update the Patch 3 commit message to include more details, as per
Peter.
- Link to v1: https://lore.kernel.org/r/20250603-uffd-fixes-v1-0-9c638c73f047@columbia.edu
---
Tal Zussman (4):
userfaultfd: correctly prevent registering VM_DROPPABLE regions
userfaultfd: prevent unregistering VMAs through a different userfaultfd
userfaultfd: remove (VM_)BUG_ON()s
userfaultfd: remove UFFD_CLOEXEC, UFFD_NONBLOCK, and UFFD_FLAGS_SET
fs/userfaultfd.c | 78 ++++++++++++++++++++++---------------------
include/linux/userfaultfd_k.h | 6 +---
mm/userfaultfd.c | 68 ++++++++++++++++++-------------------
3 files changed, 74 insertions(+), 78 deletions(-)
---
base-commit: 546b1c9e93c2bb8cf5ed24e0be1c86bb089b3253
change-id: 20250531-uffd-fixes-142331b15e63
Best regards,
--
Tal Zussman <tz2294@columbia.edu>
next reply other threads:[~2025-06-20 1:35 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-20 1:24 Tal Zussman [this message]
2025-06-20 1:24 ` [PATCH v3 1/4] userfaultfd: correctly prevent registering VM_DROPPABLE regions Tal Zussman
2025-06-20 1:24 ` [PATCH v3 2/4] userfaultfd: prevent unregistering VMAs through a different userfaultfd Tal Zussman
2025-06-20 1:24 ` [PATCH v3 3/4] userfaultfd: remove (VM_)BUG_ON()s Tal Zussman
2025-06-20 1:24 ` [PATCH v3 4/4] userfaultfd: remove UFFD_CLOEXEC, UFFD_NONBLOCK, and UFFD_FLAGS_SET Tal Zussman
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=20250619-uffd-fixes-v3-0-a7274d3bd5e4@columbia.edu \
--to=tz2294@columbia.edu \
--cc=Jason@zx2c4.com \
--cc=aarcange@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=brauner@kernel.org \
--cc=david@redhat.com \
--cc=jack@suse.cz \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=peterx@redhat.com \
--cc=viro@zeniv.linux.org.uk \
/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