mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-27 21:03:32 +00:00
riscv: Disable STACKPROTECTOR_PER_TASK if GCC_PLUGIN_RANDSTRUCT is enabled
commita18b14d888
upstream. riscv uses the value of TSK_STACK_CANARY to set stack-protector-guard-offset. With GCC_PLUGIN_RANDSTRUCT enabled, that value is non-deterministic, and with riscv:allmodconfig often results in build errors such as cc1: error: '8120' is not a valid offset in '-mstack-protector-guard-offset=' Enable STACKPROTECTOR_PER_TASK only if GCC_PLUGIN_RANDSTRUCT is disabled to fix the problem. Fixes:fea2fed201
("riscv: Enable per-task stack canaries") Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
ba7bc80da3
commit
1897993bb8
1 changed files with 1 additions and 0 deletions
|
@ -450,6 +450,7 @@ config CC_HAVE_STACKPROTECTOR_TLS
|
||||||
|
|
||||||
config STACKPROTECTOR_PER_TASK
|
config STACKPROTECTOR_PER_TASK
|
||||||
def_bool y
|
def_bool y
|
||||||
|
depends on !GCC_PLUGIN_RANDSTRUCT
|
||||||
depends on STACKPROTECTOR && CC_HAVE_STACKPROTECTOR_TLS
|
depends on STACKPROTECTOR && CC_HAVE_STACKPROTECTOR_TLS
|
||||||
|
|
||||||
endmenu
|
endmenu
|
||||||
|
|
Loading…
Reference in a new issue