Skip to content

mm: Clear uffd-wp PTE/PMD state on mremap()

Ryan Roberts linux-kselftest linux-mm lkml stable 1 version Applied

Status from this message: [merged mm-stable] selftests-mm-introduce-uffd-wp-mremap-regression-test.patch removed from -mm tree

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 12 repliesApplied 2/2

Patches in v1 All 2 applied

#Subject and filesSizeRepliesApplied
1/2mm: Clear uffd-wp PTE/PMD state on mremap()include/linux/userfaultfd_k.h mm/huge_memory.c mm/hugetlb.c +1 more+68 -212 repliesApplied
2/2selftests/mm: Introduce uffd-wp-mremap regression testtools/testing/selftests/mm/.gitignore tools/testing/selftests/mm/Makefile tools/testing/selftests/mm/run_vmtests.sh +1 more+384 -00 repliesApplied

Reviews trailers per patch

1 of 2 patches has a Reviewed-by or Acked-by.

PatchPeter Xu
1/2R-b
2/2

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH v1 0/2] mm: Clear uffd-wp PTE/PMD state on mremap()

Hi All,

This series contains a fix for a warning emitted when a uffd-registered region, which doesn't have UFFD_FEATURE_EVENT_REMAP, is mremap()ed. patch 1 describes the problem and fixes it, and patch 2 adds a selftest to verify the fix.

Thanks to Mikołaj Lenczewski who originally created the patch, which I have subsequently extended.

Applies on top of mm-unstable (f349e79bfbf3)

Thanks,
Ryan

Ryan Roberts (2):
mm: Clear uffd-wp PTE/PMD state on mremap() selftests/mm: Introduce uffd-wp-mremap regression test

 include/linux/userfaultfd_k.h               |  12 +
 mm/huge_memory.c                            |  12 +
 mm/hugetlb.c                                |  14 +-
 mm/mremap.c                                 |  32 +-
 tools/testing/selftests/mm/.gitignore       |   1 +
 tools/testing/selftests/mm/Makefile         |   2 +
 tools/testing/selftests/mm/run_vmtests.sh   |   1 +
 tools/testing/selftests/mm/uffd-wp-mremap.c | 380 ++++++++++++++++++++
 8 files changed, 452 insertions(+), 2 deletions(-)
 create mode 100644 tools/testing/selftests/mm/uffd-wp-mremap.c

--
2.43.0