mbox series

[0/3] powerpc: Prepare for clang's per-task stack protector support

Message ID 20241007-powerpc-fix-stackprotector-test-clang-v1-0-08c15b2694e4@kernel.org (mailing list archive)
Headers show
Series powerpc: Prepare for clang's per-task stack protector support | expand

Message

Nathan Chancellor Oct. 8, 2024, 4:22 a.m. UTC
This series prepares the powerpc Kconfig and Kbuild files for clang's
per-task stack protector support. clang requires
'-mstack-protector-guard-offset' to always be passed with the other
'-mstack-protector-guard' flags, which does not always happen with the
powerpc implementation, unlike arm, arm64, and riscv implementations.
This series brings powerpc in line with those other architectures, which
allows clang's support to work right away when it is merged.
Additionally, there is one other fix needed for the Kconfig test to work
correctly when targeting 32-bit.

I have tested this series in QEMU against LKDTM's REPORT_STACK_CANARY
with ppc64le_guest_defconfig and pmac32_defconfig built with a toolchain
that contains Keith's in-progress pull request, which should land for
LLVM 20:

https://github.com/llvm/llvm-project/pull/110928

---
Nathan Chancellor (3):
      powerpc: Fix stack protector Kconfig test for clang
      powerpc: Adjust adding stack protector flags to KBUILD_CLAGS for clang
      powerpc: Include -m32 / -m64 for stack protector Kconfig test

 arch/powerpc/Kconfig  |  4 ++--
 arch/powerpc/Makefile | 15 ++++++---------
 2 files changed, 8 insertions(+), 11 deletions(-)
---
base-commit: 8cf0b93919e13d1e8d4466eb4080a4c4d9d66d7b
change-id: 20241004-powerpc-fix-stackprotector-test-clang-84e67ed82f62

Best regards,