Skip to contentSkip to conversation

userfaultfd-wp-support-write-protection-for-userfault-vma-range.patch removed from -mm tree

merged [email protected] 1 participant 1 message Apr 8, 2020

lore
Share & tools
lore

[email protected]

author tree notice Applied
#0 lore raw

The patch titled
Subject: userfaultfd: wp: support write protection for userfault vma range
has been removed from the -mm tree. Its filename was
userfaultfd-wp-support-write-protection-for-userfault-vma-range.patch

This patch was dropped because it was merged into mainline or a subsystem tree

------------------------------------------------------
From: Shaohua Li <[email protected]>
Subject: userfaultfd: wp: support write protection for userfault vma range

Add API to enable/disable writeprotect a vma range. Unlike mprotect, this doesn't split/merge vmas.

[[email protected]:
- use the helper to find VMA;
- return -ENOENT if not found to match mcopy case;
- use the new MM_CP_UFFD_WP* flags for change_protection
- check against mmap_changing for failures
- replace find_dst_vma with vma_find_uffd]

Cc Andrea Arcangeli <[email protected]>
Cc Rik van Riel <[email protected]>
Cc Kirill A. Shutemov <[email protected]>
Cc Mel Gorman <[email protected]>
Cc Hugh Dickins <[email protected]>
Cc Johannes Weiner <[email protected]>
Cc Bobby Powers <[email protected]>
Cc Brian Geffon <[email protected]>
Cc David Hildenbrand <[email protected]>
Cc Denis Plotnikov <[email protected]>
Cc "Dr . David Alan Gilbert" <[email protected]>
Cc Martin Cracauer <[email protected]>
Cc Marty McFadden <[email protected]>
Cc Maya Gokhale <[email protected]>
Cc Mike Kravetz <[email protected]>
Cc Pavel Emelyanov <[email protected]>

---

 include/linux/userfaultfd_k.h |    3 +
 mm/userfaultfd.c              |   54 ++++++++++++++++++++++++++++++++
 2 files changed, 57 insertions(+)
include/linux/userfaultfd_k.h renamed from include/linux/userfaultfd_k.h~userfaultfd-wp-support-write-protection-for-userfault-vma-range +3 -0
@@ -41,6 +41,9 @@ extern ssize_t mfill_zeropage(struct mm_
 			      unsigned long dst_start,
 			      unsigned long len,
 			      bool *mmap_changing);
+extern int mwriteprotect_range(struct mm_struct *dst_mm,
+			       unsigned long start, unsigned long len,
+			       bool enable_wp, bool *mmap_changing);
 
 /* mm helpers */
 static inline bool is_mergeable_vm_userfaultfd_ctx(struct vm_area_struct *vma,
mm/userfaultfd.c renamed from mm/userfaultfd.c~userfaultfd-wp-support-write-protection-for-userfault-vma-range +54 -0

57 lines not on this page · raw message

_

Patches currently in -mm which might be from [email protected] are