[PATCH 0/2] No-exec support for ppc64

Jake Moilanen
2005-03-08T23:14:46Z

These patches add no execute support to PPC64. They prohibit executing
code on the stack, or most any non-text segment for both user space, and
kernel.

No execute is supported on Power4 processors and up. These processors
support pages that have a no-execute permission bit.

The patches include a base fixup from Anton Blanchard. This includes a
fix for the wrong bit being used for no-exec and for read/write on the
hardware PTEs.

For distros that compile w/ pt_gnu_stacks, they depend on Ben
Herrenschmidt's vDSO patches for signal trampoline. Without it, the
application will hang on the first signal due to the return code being
put on the signal context stack to return to the kernel on the
completion of the signal handler. The changes should be in the latest
BK tree.

The patch is broken into two parts:

1/2: PPC64 no-exec support for user space: This will prohibit user
space apps from executing in segments not marked as executable. The
base support is in here as well.

2/2: PPC64 no-exec support for kernel space: This prohibits the kernel
from executing non-text code.

Thanks,
Jake