diff options
author | Jinbum Park <jinb.park7@gmail.com> | 2017-12-11 19:25:30 -0500 |
---|---|---|
committer | Russell King <rmk+kernel@armlinux.org.uk> | 2017-12-17 17:16:20 -0500 |
commit | 6fbab054eccd14480d0c0805cab80db08e0fb3ee (patch) | |
tree | 87de3a8a5c6bbea148668bd2e496b1790bca1ff8 | |
parent | 670431eaacbfa30be59f4ea027a2d9662ddf2bff (diff) |
ARM: 8734/1: mm: idmap: Mark variables as ro_after_init
idmap_pgd, arch_phys_to_idmap_offset are setup once
while init stage, and never changed after that.
so, it is good candidate for __ro_after_init.
Reviewed-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Jinbum Park <jinb.park7@gmail.com>
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
-rw-r--r-- | arch/arm/mm/idmap.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm/mm/idmap.c b/arch/arm/mm/idmap.c index 10bfba85eb96..1d1edd064199 100644 --- a/arch/arm/mm/idmap.c +++ b/arch/arm/mm/idmap.c | |||
@@ -16,8 +16,8 @@ | |||
16 | * are not supported on any CPU using the idmap tables as its current | 16 | * are not supported on any CPU using the idmap tables as its current |
17 | * page tables. | 17 | * page tables. |
18 | */ | 18 | */ |
19 | pgd_t *idmap_pgd; | 19 | pgd_t *idmap_pgd __ro_after_init; |
20 | long long arch_phys_to_idmap_offset; | 20 | long long arch_phys_to_idmap_offset __ro_after_init; |
21 | 21 | ||
22 | #ifdef CONFIG_ARM_LPAE | 22 | #ifdef CONFIG_ARM_LPAE |
23 | static void idmap_add_pmd(pud_t *pud, unsigned long addr, unsigned long end, | 23 | static void idmap_add_pmd(pud_t *pud, unsigned long addr, unsigned long end, |