diff options
author | Dan Aloni <daloni@magicleap.com> | 2019-08-15 15:28:18 +0300 |
---|---|---|
committer | Todd Kjos <tkjos@google.com> | 2019-08-22 21:24:48 +0000 |
commit | fdfc07c1377c447f3b3814ef4c335cf1c838d686 (patch) | |
tree | 4a028351b26c7086afa25ef92716898c04139200 /drivers/s390 | |
parent | e005abce5829d9060148325bc482a908f8ad8cbd (diff) |
ANDROID: arm64: fix leftover RWX when using CONFIG_UNMAP_KERNEL_AT_EL0
With CONFIG_UNMAP_KERNEL_AT_EL0 enabled, before this change, there was an RWX
mapping at a fixed `fixmap` address (as discovered using CONFIG_ARM64_PTDUMP).
0xffff7ffffe7fc000-0xffff7ffffe7fd000 4K RW x SHD AF UXN MEM/NORMAL
Having PAGE_KERNEL_ROX by default for this fixmap makes sense for a security
POV, for reducing the ability to load and run shellcode.
Originally, the commit that introduced CONFIG_UNMAP_KERNEL_AT_EL0, had the following:
pgprot_t prot = rodata_enabled ? PAGE_KERNEL_ROX : PAGE_KERNEL_EXEC;
However rodata_enabled is not available in arch/arm64 on this early version of
the kernel.
Change-Id: I21f26df498fb591fc28e32f4dfad671a9ed3d8d3
Fixes: 39685f556c0c ("FROMLIST: arm64: mm: Map entry trampoline into
trampoline and kernel page tables")
Signed-off-by: Dan Aloni <daloni@magicleap.com>
Diffstat (limited to 'drivers/s390')
0 files changed, 0 insertions, 0 deletions