Re: [PATCH v2] userfaultfd: allow registration of ranges below mmap_min_addr

Denis M. Karpov
2026-04-09T15:54:26Z

On Thu, Apr 9, 2026 at 6:17 PM Mike Rapoport <rppt@kernel.org> wrote:
> On Thu, Apr 09, 2026 at 01:30:07PM +0100, Pedro Falcato wrote:
> > This looks relatively safe. However, I'm not sure if we want this in stable.
> > This has been broken for 11 years now, with no complaints.
>
> I believe Denis has a new usecase that wasn't there for those 11 years :)
>
> Denis, can you share more details about your usecase for us to better
> understand importance of backporting this to stable?
Hello Mike.
Actually, there is nothing new about the use case. We simply started using
UFFD instead of the classic mprotect approach in the binary translator to
track application writes. During development, we encountered this bug.
The translator cannot control where the translated application chooses
to map its
memory and if the app requires a low-address area, UFFD fails, whereas
mprotect would work just fine. I believe this is a genuine logic bug rather than
an improvement, and I would appreciate including the fix in stable.