@@ -424,7 +424,7 @@ extern unsigned int kobjsize(const void *objp);
* mapping from the currently active vm_flags protection bits (the
* low four bits) to a page protection mask..
*/
-#ifdef __P000
+#ifndef CONFIG_ARCH_HAS_VM_GET_PAGE_PROT
extern pgprot_t protection_map[16];
#endif
@@ -81,7 +81,7 @@ static void unmap_region(struct mm_struct *mm,
struct vm_area_struct *vma, struct vm_area_struct *prev,
unsigned long start, unsigned long end);
-#ifdef __P000
+#ifndef CONFIG_ARCH_HAS_VM_GET_PAGE_PROT
pgprot_t protection_map[16] __ro_after_init = {
[VM_NONE] = __P000,
[VM_READ] = __P001,
@@ -100,9 +100,6 @@ pgprot_t protection_map[16] __ro_after_init = {
[VM_SHARED | VM_EXEC | VM_WRITE] = __S110,
[VM_SHARED | VM_EXEC | VM_WRITE | VM_READ] = __S111
};
-#endif
-
-#ifndef CONFIG_ARCH_HAS_VM_GET_PAGE_PROT
DECLARE_VM_GET_PAGE_PROT
#endif /* CONFIG_ARCH_HAS_VM_GET_PAGE_PROT */