Thread (23 messages) 23 messages, 7 authors, 2026-01-14

Re: [PATCH v4 2/9] mm: add atomic VMA flags and set VM_MAYBE_GUARD as such

From: "David Hildenbrand (Red Hat)" <david@kernel.org>
Date: 2025-11-19 09:06:51
Also in: linux-fsdevel, linux-kselftest, linux-mm, linux-trace-kernel, lkml

On 18.11.25 11:17, Lorenzo Stoakes wrote:
This patch adds the ability to atomically set VMA flags with only the mmap
read/VMA read lock held.

As this could be hugely problematic for VMA flags in general given that
all other accesses are non-atomic and serialised by the mmap/VMA locks, we
implement this with a strict allow-list - that is, only designated flags
are allowed to do this.

We make VM_MAYBE_GUARD one of these flags.

Signed-off-by: Lorenzo Stoakes <redacted>
Reviewed-by: Pedro Falcato <pfalcato@suse.de>
Reviewed-by: Vlastimil Babka <redacted>
---
IIUC all other flag modifications need a write lock, so this should just 
work.

Acked-by: David Hildenbrand (Red Hat) <david@kernel.org>

-- 
Cheers

David
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help