linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/7]  userfaultfd: add support for shared memory
@ 2016-08-04  8:14 Mike Rapoport
  2016-08-04  8:14 ` [PATCH 1/7] userfaultfd: introduce vma_can_userfault Mike Rapoport
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: Mike Rapoport @ 2016-08-04  8:14 UTC (permalink / raw)
  To: Andrea Arcangeli
  Cc: Hugh Dickins, Pavel Emelyanov, linux-mm, linux-kernel,
	Mike Rapoport

These patches enable userfaultfd support for shared memory mappings. The
VMAs backed with shmem/tmpfs can be registered with userfaultfd which
allows management of page faults in these areas by userland.

This patch set adds implementation of shmem_mcopy_atomic_pte for proper
handling of UFFDIO_COPY command. A callback to handle_userfault is added
to shmem page fault handling path. The userfaultfd register/unregister
methods are extended to allow shmem VMAs.

The UFFDIO_ZEROPAGE and UFFDIO_REGISTER_MODE_WP are not implemented which
is reflected by userfaultfd API handshake methods.

The patches are based on current Andrea's tree:
https://git.kernel.org/pub/scm/linux/kernel/git/andrea/aa.git

Mike Rapoport (7):
  userfaultfd: introduce vma_can_userfault
  userfaultfd: shmem: add shmem_mcopy_atomic_pte for userfaultfd support
  userfaultfd: shmem: introduce vma_is_shmem
  userfaultfd: shmem: use shmem_mcopy_atomic_pte for shared memory
  userfaultfd: shmem: add userfaultfd hook for shared memory faults
  userfaultfd: shmem: allow registration of shared memory ranges
  userfaultfd: shmem: add userfaultfd_shmem test

 fs/userfaultfd.c                         |  32 ++++---
 include/linux/mm.h                       |  10 +++
 include/linux/shmem_fs.h                 |  11 +++
 include/uapi/linux/userfaultfd.h         |   2 +-
 mm/shmem.c                               | 139 +++++++++++++++++++++++++++++--
 mm/userfaultfd.c                         |  31 ++++---
 tools/testing/selftests/vm/Makefile      |   3 +
 tools/testing/selftests/vm/run_vmtests   |  11 +++
 tools/testing/selftests/vm/userfaultfd.c |  39 ++++++++-
 9 files changed, 237 insertions(+), 41 deletions(-)

-- 
1.9.1

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2016-08-04 18:54 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-08-04  8:14 [PATCH 0/7] userfaultfd: add support for shared memory Mike Rapoport
2016-08-04  8:14 ` [PATCH 1/7] userfaultfd: introduce vma_can_userfault Mike Rapoport
2016-08-04  8:14 ` [PATCH 2/7] userfaultfd: shmem: add shmem_mcopy_atomic_pte for userfaultfd support Mike Rapoport
2016-08-04  8:14 ` [PATCH 3/7] userfaultfd: shmem: introduce vma_is_shmem Mike Rapoport
2016-08-04  8:14 ` [PATCH 4/7] userfaultfd: shmem: use shmem_mcopy_atomic_pte for shared memory Mike Rapoport
2016-08-04  8:14 ` [PATCH 5/7] userfaultfd: shmem: add userfaultfd hook for shared memory faults Mike Rapoport
2016-08-04  8:14 ` [PATCH 6/7] userfaultfd: shmem: allow registration of shared memory ranges Mike Rapoport
2016-08-04  8:14 ` [PATCH 7/7] userfaultfd: shmem: add userfaultfd_shmem test Mike Rapoport
2016-08-04 18:54 ` [PATCH 0/7] userfaultfd: add support for shared memory Andrea Arcangeli

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).