diff options
author | Nicholas Miehlbradt <nicholas@linux.ibm.com> | 2023-02-28 06:43:55 +0100 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2023-04-04 14:11:03 +0200 |
commit | ac9c8901cb10aab043bf3599d19eebacfcda2858 (patch) | |
tree | d4e853d3daf6e4f2e99dacc5a3372e978bdaebee /arch/powerpc/Kconfig | |
parent | powerpc: Use of_address_to_resource() (diff) | |
download | linux-ac9c8901cb10aab043bf3599d19eebacfcda2858.tar.xz linux-ac9c8901cb10aab043bf3599d19eebacfcda2858.zip |
powerpc: Implement arch_within_stack_frames
Walks the stack when copy_{to,from}_user address is in the stack to
ensure that the object being copied is entirely a single stack frame and
does not contain stack metadata.
Substantially similar to the x86 implementation. The back chain is used
to traverse the stack and identify stack frame boundaries.
Signed-off-by: Nicholas Miehlbradt <nicholas@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://msgid.link/20230228054355.300628-1-nicholas@linux.ibm.com
Diffstat (limited to 'arch/powerpc/Kconfig')
-rw-r--r-- | arch/powerpc/Kconfig | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig index 47017975fc2b..fc4e81dafca7 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig @@ -200,6 +200,7 @@ config PPC select HAVE_ARCH_KCSAN if PPC_BOOK3S_64 select HAVE_ARCH_KFENCE if ARCH_SUPPORTS_DEBUG_PAGEALLOC select HAVE_ARCH_RANDOMIZE_KSTACK_OFFSET + select HAVE_ARCH_WITHIN_STACK_FRAMES select HAVE_ARCH_KGDB select HAVE_ARCH_MMAP_RND_BITS select HAVE_ARCH_MMAP_RND_COMPAT_BITS if COMPAT |