diff options
author | Christophe Leroy <christophe.leroy@c-s.fr> | 2018-11-28 20:21:10 +0300 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2018-12-19 10:56:32 +0300 |
commit | 385e89d5b20f5a7c33fd7c1904da0e6a8e1b366f (patch) | |
tree | 6bca1bde5792cd345deca9a6dea1f0b929f42e31 /arch/powerpc/mm/dump_linuxpagetables-generic.c | |
parent | badb9687cec50bdba59746532de1969d6d26f3a7 (diff) | |
download | linux-385e89d5b20f5a7c33fd7c1904da0e6a8e1b366f.tar.xz |
powerpc/mm: add exec protection on powerpc 603
The 603 doesn't have a HASH table, TLB misses are handled by
software. It is then possible to generate page fault when
_PAGE_EXEC is not set like in nohash/32.
There is one "reserved" PTE bit available, this patch uses
it for _PAGE_EXEC.
In order to support it, set_pte_filter() and
set_access_flags_filter() are made common, and the handling
is made dependent on MMU_FTR_HPTE_TABLE
Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/mm/dump_linuxpagetables-generic.c')
-rw-r--r-- | arch/powerpc/mm/dump_linuxpagetables-generic.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/arch/powerpc/mm/dump_linuxpagetables-generic.c b/arch/powerpc/mm/dump_linuxpagetables-generic.c index 1e3829ec1348..3fe98a0974c6 100644 --- a/arch/powerpc/mm/dump_linuxpagetables-generic.c +++ b/arch/powerpc/mm/dump_linuxpagetables-generic.c @@ -21,13 +21,11 @@ static const struct flag_info flag_array[] = { .set = "rw", .clear = "r ", }, { -#ifndef CONFIG_PPC_BOOK3S_32 .mask = _PAGE_EXEC, .val = _PAGE_EXEC, .set = " X ", .clear = " ", }, { -#endif .mask = _PAGE_PRESENT, .val = _PAGE_PRESENT, .set = "present", |