ANDROID: gki_defconfig: cfi: unconditionally normalize integers

The -fsanitize-cfi-icall-experimental-normalize-integers flag must be
passed to clang for it to be possible to use Rust in the kernel when CFI
is enabled. However, only passing this flag when CONFIG_RUST is enabled
is undesirable because it affects the ABI of C code.

Enabling the flag unconditionally allows us to toggle CONFIG_RUST
without having it change the ABI of existing C code. This helps prevent
b/350371019 from happening again in the future.

Bug: 350943879
Change-Id: I773d1c70df50d0879b141ba02fc3f096c48ab169
Signed-off-by: Alice Ryhl <aliceryhl@google.com>
This commit is contained in:
Alice Ryhl
2024-07-25 13:02:20 +00:00
parent b42bc19c79
commit 70df9211df
2 changed files with 2 additions and 0 deletions
+1
View File
@@ -89,6 +89,7 @@ CONFIG_KPROBES=y
CONFIG_JUMP_LABEL=y
CONFIG_SHADOW_CALL_STACK=y
CONFIG_CFI_CLANG=y
CONFIG_CFI_ICALL_NORMALIZE_INTEGERS=y
CONFIG_MODULES=y
CONFIG_MODULE_UNLOAD=y
CONFIG_MODVERSIONS=y
+1
View File
@@ -84,6 +84,7 @@ CONFIG_KVM_AMD=y
CONFIG_KPROBES=y
CONFIG_JUMP_LABEL=y
CONFIG_CFI_CLANG=y
CONFIG_CFI_ICALL_NORMALIZE_INTEGERS=y
CONFIG_MODULES=y
CONFIG_MODULE_UNLOAD=y
CONFIG_MODVERSIONS=y