mbox series

[0/6] Avoid the mmap lock for fault-around

Message ID 20230404135850.3673404-1-willy@infradead.org (mailing list archive)
Headers show
Series Avoid the mmap lock for fault-around | expand

Message

Matthew Wilcox April 4, 2023, 1:58 p.m. UTC
The linux-next tree currently contains patches (mostly from Suren)
which handle some page faults without the protection of the mmap lock.
This patchset adds the ability to handle page faults on parts of files
which are already in the page cache without taking the mmap lock.

I've taken a very gradual approach to pushing the lock down.  I'm not 100%
confident in my ability to grasp all the finer aspects of VMA handling,
so some reviewrs may well feel that I could have combined some of
these patches.  I did try to skip one of these steps and it had a bug,
so I feel justified in proceeding cautiously.

Several people have volunteered to run benchmarks on this, so I haven't.
I have run it through xfstests and it doesn't appear to introduce any
regressions.

Matthew Wilcox (Oracle) (6):
  mm: Allow per-VMA locks on file-backed VMAs
  mm: Move FAULT_FLAG_VMA_LOCK check from handle_mm_fault()
  mm: Move FAULT_FLAG_VMA_LOCK check into handle_pte_fault()
  mm: Move FAULT_FLAG_VMA_LOCK check down in handle_pte_fault()
  mm: Move the FAULT_FLAG_VMA_LOCK check down from do_pte_missing()
  mm: Run the fault-around code under the VMA lock

 mm/hugetlb.c |  4 ++++
 mm/memory.c  | 28 +++++++++++++++++++---------
 2 files changed, 23 insertions(+), 9 deletions(-)