Replace use of the legacy vm_flags_t flags with vma_flags_t values in the AppArmor mprotect LSM hook.
No functional change intended. Signed-off-by: Lorenzo Stoakes (ARM) <[email protected]> Reviewed-by: Lance Yang <[email protected]> --- security/apparmor/lsm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/security/apparmor/lsm.c b/security/apparmor/lsm.c index eaebc3c60c5a..9ff9096b6199 100644 --- a/security/apparmor/lsm.c +++ b/security/apparmor/lsm.c @@ -591,7 +591,7 @@ static int apparmor_file_mprotect(struct vm_area_struct *vma, unsigned long reqprot, unsigned long prot) { return common_mmap(OP_FMPROT, vma->vm_file, prot, - !(vma->vm_flags & VM_SHARED) ? MAP_PRIVATE : 0); + !vma_test(vma, VMA_SHARED_BIT) ? MAP_PRIVATE : 0); } #ifdef CONFIG_IO_URING -- 2.56.1
