Utilize the TLB Execute-Inhibit bit with non-executable mappings on CPUs
authorvisa <visa@openbsd.org>
Sun, 14 Aug 2016 08:23:52 +0000 (08:23 +0000)
committervisa <visa@openbsd.org>
Sun, 14 Aug 2016 08:23:52 +0000 (08:23 +0000)
commit8f99340c2165c03820aaa750409a836b05aec719
tree88f5d7a6fa7257b54c2cc3c004aeb09bb7a25304
parent5c97b65caeca91d52cf4d5b65fca7de1c5e39cc8
Utilize the TLB Execute-Inhibit bit with non-executable mappings on CPUs
that support the Execute-Inhibit exception. This makes user space W^X
effective on Octeon Plus and later Octeon versions.

Feedback from miod@, thanks!
No objection from deraadt@
sys/arch/mips64/include/cpu.h
sys/arch/mips64/include/mips_cpu.h
sys/arch/mips64/include/pte.h
sys/arch/mips64/mips64/context.S
sys/arch/mips64/mips64/db_machdep.c
sys/arch/mips64/mips64/mips64r2.S
sys/arch/mips64/mips64/pmap.c
sys/arch/mips64/mips64/tlbhandler.S
sys/arch/mips64/mips64/trap.c
sys/arch/octeon/octeon/locore.S
sys/arch/octeon/octeon/machdep.c