]> Gentwo Git Trees - linux/.git/commit
mm/vma: small VMA lock cleanups
authorLorenzo Stoakes <lorenzo.stoakes@oracle.com>
Fri, 24 Oct 2025 09:09:02 +0000 (10:09 +0100)
committerAndrew Morton <akpm@linux-foundation.org>
Mon, 17 Nov 2025 01:28:26 +0000 (17:28 -0800)
commitb734b9d973ccd7ad1cfebc2e1f7db693824a37ef
treebeba22d24f032523ece169e5b17bcbf82c67ef8a
parentad8b2e096181bd23a32d8672de107136d0c478e9
mm/vma: small VMA lock cleanups

We declare vma_start_read() as a static function in mm/mmap_lock.c, so
there is no need to provide a stub for !CONFIG_PER_VMA_LOCK.

__is_vma_write_locked() is declared in a header and should therefore be
static inline.

Put parens around (refcnt & VMA_LOCK_OFFSET) in is_vma_writer_only() to
make precedence clear.

Link: https://lkml.kernel.org/r/20251024090902.1118174-1-lorenzo.stoakes@oracle.com
Signed-off-by: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
Reviewed-by: Suren Baghdasaryan <surenb@google.com>
Reviewed-by: Shakeel Butt <shakeel.butt@linux.dev>
Reviewed-by: Vlastimil Babka <vbabka@suse.cz>
Cc: Liam Howlett <liam.howlett@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/mmap_lock.h