xref: /linux/arch/arm/include/asm/set_memory.h (revision 03ab8e6297acd1bc0eedaa050e2a1635c576fd11)
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /*
3  * Copyright (C) 1999-2002 Russell King
4  */
5 
6 #ifndef _ASMARM_SET_MEMORY_H
7 #define _ASMARM_SET_MEMORY_H
8 
9 #ifdef CONFIG_MMU
10 int set_memory_ro(unsigned long addr, int numpages);
11 int set_memory_rw(unsigned long addr, int numpages);
12 int set_memory_x(unsigned long addr, int numpages);
13 int set_memory_nx(unsigned long addr, int numpages);
14 int set_memory_valid(unsigned long addr, int numpages, int enable);
15 #else
set_memory_ro(unsigned long addr,int numpages)16 static inline int set_memory_ro(unsigned long addr, int numpages) { return 0; }
set_memory_rw(unsigned long addr,int numpages)17 static inline int set_memory_rw(unsigned long addr, int numpages) { return 0; }
set_memory_x(unsigned long addr,int numpages)18 static inline int set_memory_x(unsigned long addr, int numpages) { return 0; }
set_memory_nx(unsigned long addr,int numpages)19 static inline int set_memory_nx(unsigned long addr, int numpages) { return 0; }
20 #endif
21 
22 #endif
23