Re: [RFC PATCH v3] mm: retry page faults under per-VMA lock when mmap_lock is not required
From: Suren Baghdasaryan
Date: Fri Jul 10 2026 - 21:55:16 EST
On Fri, Jul 10, 2026 at 4:37 PM Barry Song <baohua@xxxxxxxxxx> wrote:
>
> On Fri, Jul 10, 2026 at 10:54 PM Suren Baghdasaryan <surenb@xxxxxxxxxx> wrote:
> [...]
> > > Have you audited every single VM_FAULT_RETRY case? Because getting this
> > > wrong could be a serious problem and break things. You should include a
> > > list of call sites in your patch and explain why it's fine in each case.
> >
> > That's my main worry with this patch as well. I think a better
> > approach would keep VM_FAULT_RETRY as is (falling back to mmap_lock),
> > introduce VM_FAULT_RETRY_VMA (or whatever is best to indicate a retry
> > with VMA lock) and then convert individual VM_FAULT_RETRY cases to
> > VM_FAULT_RETRY_VMA with proper reasoning and explanation why it is
> > safe. Less churn, gradual conversion, and happy reviewers.
> >
>
> I am not really sure there are any happy reviewers here.
> VM_FAULT_RETRY_VMA and the gradual migration to per-VMA lock retry
> are exactly what was done in the previous versions, even since RFC v1[1] :-)
Right and the pushback you received was not due to that approach,
right? So, why change something that nobody complained about? Unless I
missed another discussion asking to change this approach, in which
case I would really like to read it and understand the reasons.
>
> [1] https://lore.kernel.org/all/20251127011438.6918-1-21cnbao@xxxxxxxxx/