mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-05 08:26:59 +00:00
f2c7e3562b
To support detection of read faults with Radix execute-only memory, the
vma_is_accessible() check in access_error() (which checks for PROT_NONE)
was replaced with a check to see if VM_READ was missing, and if so,
returns true to assert the fault was caused by a bad read.
This is incorrect, as it ignores that both VM_WRITE and VM_EXEC imply
read on powerpc, as defined in protection_map[]. This causes mappings
containing VM_WRITE or VM_EXEC without VM_READ to misreport the cause of
page faults, since the MMU is still allowing reads.
Correct this by restoring the original vma_is_accessible() check for
PROT_NONE mappings, and adding a separate check for Radix PROT_EXEC-only
mappings.
Fixes:
|
||
---|---|---|
.. | ||
book3s32 | ||
book3s64 | ||
kasan | ||
nohash | ||
ptdump | ||
cacheflush.c | ||
copro_fault.c | ||
dma-noncoherent.c | ||
drmem.c | ||
fault.c | ||
hugetlbpage.c | ||
init-common.c | ||
init_32.c | ||
init_64.c | ||
ioremap.c | ||
ioremap_32.c | ||
ioremap_64.c | ||
maccess.c | ||
Makefile | ||
mem.c | ||
mmu_context.c | ||
mmu_decl.h | ||
numa.c | ||
pageattr.c | ||
pgtable-frag.c | ||
pgtable.c | ||
pgtable_32.c | ||
pgtable_64.c |