aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mm/Kconfig3
-rw-r--r--mm/mmap.c2
2 files changed, 5 insertions, 0 deletions
diff --git a/mm/Kconfig b/mm/Kconfig
index 034d87953600..b1f7624276f8 100644
--- a/mm/Kconfig
+++ b/mm/Kconfig
@@ -765,6 +765,9 @@ config ARCH_HAS_CURRENT_STACK_POINTER
config ARCH_HAS_FILTER_PGPROT
bool
+config ARCH_HAS_VM_GET_PAGE_PROT
+ bool
+
config ARCH_HAS_PTE_DEVMAP
bool
diff --git a/mm/mmap.c b/mm/mmap.c
index e32640456c92..c1376ce34316 100644
--- a/mm/mmap.c
+++ b/mm/mmap.c
@@ -120,6 +120,7 @@ pgprot_t protection_map[16] __ro_after_init = {
[VM_SHARED | VM_EXEC | VM_WRITE | VM_READ] = __S111
};
+#ifndef CONFIG_ARCH_HAS_VM_GET_PAGE_PROT
#ifndef CONFIG_ARCH_HAS_FILTER_PGPROT
static inline pgprot_t arch_filter_pgprot(pgprot_t prot)
{
@@ -136,6 +137,7 @@ pgprot_t vm_get_page_prot(unsigned long vm_flags)
return arch_filter_pgprot(ret);
}
EXPORT_SYMBOL(vm_get_page_prot);
+#endif /* CONFIG_ARCH_HAS_VM_GET_PAGE_PROT */
static pgprot_t vm_pgprot_modify(pgprot_t oldprot, unsigned long vm_flags)
{