Revert "FROMLIST: rust: add flags for shadow call stack sanitizer"
This reverts commit263770649d. A newer version of this patchset will land in 6.12-rc1. Revert the old version now to avoid merge conflicts in the 6.12-rc1 merge. Removing these flags could result in miscompilation in Rust+SCS builds, however commitf126745da8("rust: SHADOW_CALL_STACK is incompatible with Rust") has already landed through 6.11-rc2, so such builds are rejected by Kconfig. Change-Id: Id0ea2372811159c67c1afd7e4fed525848c21f8b Signed-off-by: Alice Ryhl <aliceryhl@google.com>
This commit is contained in:
@@ -948,7 +948,6 @@ ifdef CONFIG_SHADOW_CALL_STACK
|
||||
ifndef CONFIG_DYNAMIC_SCS
|
||||
CC_FLAGS_SCS := -fsanitize=shadow-call-stack
|
||||
KBUILD_CFLAGS += $(CC_FLAGS_SCS)
|
||||
KBUILD_RUSTFLAGS += -Zsanitizer=shadow-call-stack
|
||||
endif
|
||||
export CC_FLAGS_SCS
|
||||
endif
|
||||
|
||||
@@ -57,12 +57,9 @@ KBUILD_AFLAGS += $(call cc-option,-mabi=lp64)
|
||||
ifneq ($(CONFIG_UNWIND_TABLES),y)
|
||||
KBUILD_CFLAGS += -fno-asynchronous-unwind-tables -fno-unwind-tables
|
||||
KBUILD_AFLAGS += -fno-asynchronous-unwind-tables -fno-unwind-tables
|
||||
KBUILD_RUSTFLAGS += -Cforce-unwind-tables=n
|
||||
else
|
||||
KBUILD_CFLAGS += -fasynchronous-unwind-tables
|
||||
KBUILD_AFLAGS += -fasynchronous-unwind-tables
|
||||
# TODO: Pass -Zuse-sync-unwind=n once we upgrade to Rust 1.77.0
|
||||
KBUILD_RUSTFLAGS += -Cforce-unwind-tables=y
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_STACKPROTECTOR_PER_TASK),y)
|
||||
@@ -117,7 +114,6 @@ endif
|
||||
|
||||
ifeq ($(CONFIG_SHADOW_CALL_STACK), y)
|
||||
KBUILD_CFLAGS += -ffixed-x18
|
||||
KBUILD_RUSTFLAGS += -Ctarget-feature=+reserve-x18
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_CPU_BIG_ENDIAN), y)
|
||||
|
||||
Reference in New Issue
Block a user