[PATCH 07/13] mm/madvise: convert madvise_vma_behavior() to use vma_flags_t

sashiko-bot at kernel.org sashiko-bot at kernel.org
Thu Nov 5 21:43:23 UTC 2026


> Replace use of the legacy vm_flags_t flags with vma_flags_t values
> throughout the madvise logic.
> 
> In order to do so, update ksm_madvise() and hugepage_madvise() to take a
> vma_flags_t pointer, and update their other callers in mremap and the
> powerpc KVM ultravisor code accordingly.
> 
> In the latter case we replace vm_flags_reset() with vma_overwrite_flags().
> The VMA is write locked at this point, so the atomic flags preserved by
> vma_overwrite_flags() cannot differ from those copied, and the behaviour
> is unchanged.
> 
> No functional change intended.
> 
> Signed-off-by: Lorenzo Stoakes (ARM) <ljs at kernel.org>

Sashiko has reviewed this patch and found no issues.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261105-late-2026-vma-flags-v1-0-0d3cd15ab75f@kernel.org?part=7




More information about the Linux-security-module-archive mailing list