[PATCH v2 11/11] ipe: convert VMA flag tests to use vma_flags_t

Lorenzo Stoakes (ARM) ljs at kernel.org
Tue Nov 24 17:08:03 UTC 2026


Replace use of the legacy vm_flags_t flags with vma_flags_t values in the
IPE mprotect LSM hook.

No functional change intended.

Signed-off-by: Lorenzo Stoakes (ARM) <ljs at kernel.org>
Acked-by: Fan Wu <wufan at kernel.org>
Reviewed-by: Lance Yang <lance.yang at linux.dev>
---
 security/ipe/hooks.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/security/ipe/hooks.c b/security/ipe/hooks.c
index d878b52ceec8..247b07748b1d 100644
--- a/security/ipe/hooks.c
+++ b/security/ipe/hooks.c
@@ -112,7 +112,7 @@ int ipe_file_mprotect(struct vm_area_struct *vma,
 	struct ipe_eval_ctx ctx = IPE_EVAL_CTX_INIT;
 
 	/* Already Executable */
-	if (vma->vm_flags & VM_EXEC)
+	if (vma_test(vma, VMA_EXEC_BIT))
 		return 0;
 
 	if (prot & PROT_EXEC) {

-- 
2.56.1




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