From: Russell King Date: Mon, 21 Nov 2016 16:07:05 +0000 (+0000) Subject: ARM: mm: allow set_memory_*() to be used on the vmalloc region X-Git-Tag: rel_imx_4.19.35_1.1.0~13514^2~1^3 X-Git-Url: https://git.somdevices.com/?a=commitdiff_plain;h=76fb051d42945d142fe265b6ec79e06aa9cfb250;p=linux.git ARM: mm: allow set_memory_*() to be used on the vmalloc region We can allow modules to be loaded into the vmalloc region, where they should also benefit from the same protections as those loaded into the more efficient module region. Allow these functions to operate there as well. Signed-off-by: Russell King --- diff --git a/arch/arm/mm/pageattr.c b/arch/arm/mm/pageattr.c index 6cb0d8ea9138..3b69f2642513 100644 --- a/arch/arm/mm/pageattr.c +++ b/arch/arm/mm/pageattr.c @@ -55,7 +55,8 @@ static int change_memory_common(unsigned long addr, int numpages, if (!size) return 0; - if (!in_range(start, size, MODULES_VADDR, MODULES_END)) + if (!in_range(start, size, MODULES_VADDR, MODULES_END) && + !in_range(start, size, VMALLOC_START, VMALLOC_END)) return -EINVAL; data.set_mask = set_mask;