Re: [PATCH] mm/userfaultfd: only allocate anon_vma in CoW mappings

From: Lorenzo Stoakes (ARM)

Date: Thu Oct 15 2026 - 05:13:12 EST


On Wed, Oct 14, 2026 at 08:29:35PM +0200, David Hildenbrand (Arm) wrote:
> > Hmm really? Is it possible to do that without the hugetlb lock?
>
> Yes, we don't have to sync against PMD sharing if PMD sharing is impossible.

Ahhh I see.

> Will send that out for the next cycle.

Looks sane!

>
> > It'd be good in general if we could get rid of that lock as a whole :) but maybe
> > dreaming.
>
> Yeah :)

I will probably have to go and look at that more deeply for
mmap_prepare/scalable CoW reasons. I will wear goggles... :)

--
Cheers, Lorenzo