android_kernel_samsung_sm8650/arch
Ard Biesheuvel 6053d8ffd4 UPSTREAM: arm64: scs: Disable LTO for SCS patching code
Full LTO takes the '-mbranch-protection=none' passed to the compiler
when generating the dynamic shadow call stack patching code as a hint to
stop emitting PAC instructions altogether. (Thin LTO appears unaffected
by this)

Work around this by disabling LTO for the compilation unit, which
appears to convince the linker that it should still use PAC in the rest
of the kernel..

Fixes: 3b619e22c460 ("arm64: implement dynamic shadow call stack for Clang")
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Reviewed-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Sami Tolvanen <samitolvanen@google.com>
Tested-by: Sami Tolvanen <samitolvanen@google.com>
Link: https://lore.kernel.org/r/20240123133052.1417449-6-ardb+git@google.com
Signed-off-by: Will Deacon <will@kernel.org>
(cherry picked from commit d104a6fef3fec137d8d44961224ab76edbd6cbc7)
Bug: 317883735
Change-Id: Ic4bdb0a6e527f8cb2745282b81945aa7b7231502
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
2024-02-07 10:37:36 +00:00
..
alpha alpha: remove __init annotation from exported page_is_ram() 2023-08-16 18:27:31 +02:00
arc ARC: atomics: Add compiler barrier to atomic operations... 2023-09-19 12:28:04 +02:00
arm This is the 6.1.68 stable release 2024-01-05 08:40:52 +00:00
arm64 UPSTREAM: arm64: scs: Disable LTO for SCS patching code 2024-02-07 10:37:36 +00:00
csky UPSTREAM: mm/fault: convert remaining simple cases to lock_mm_and_find_vma() 2023-07-27 05:04:57 +00:00
hexagon UPSTREAM: mm/fault: convert remaining simple cases to lock_mm_and_find_vma() 2023-07-27 05:04:57 +00:00
ia64 Merge 6.1.44 into android14-6.1-lts 2023-09-12 15:09:42 +00:00
loongarch This is the 6.1.68 stable release 2024-01-05 08:40:52 +00:00
m68k m68k: Fix invalid .section syntax 2023-09-13 09:42:21 +02:00
microblaze BACKPORT: mm: always expand the stack with the mmap write lock held 2023-07-27 11:47:21 +00:00
mips MIPS: Loongson64: Enable DMA noncoherent support 2023-12-13 18:39:29 +01:00
nios2 Merge branch 'android14-6.1' into 'android14-6.1-lts' 2023-08-23 18:31:43 +00:00
openrisc Merge branch 'android14-6.1' into 'android14-6.1-lts' 2023-08-23 18:31:43 +00:00
parisc This is the 6.1.68 stable release 2024-01-05 08:40:52 +00:00
powerpc Merge tag 'android14-6.1.68_r00' into branch 'android14-6.1' 2024-01-09 16:57:00 +00:00
riscv Merge tag 'android14-6.1.68_r00' into branch 'android14-6.1' 2024-01-09 16:57:00 +00:00
s390 Merge tag 'android14-6.1.68_r00' into branch 'android14-6.1' 2024-01-09 16:57:00 +00:00
sh sh: bios: Revive earlyprintk support 2023-11-20 11:52:07 +01:00
sparc Merge 6.1.61 into android14-6.1-lts 2023-11-07 08:21:27 +00:00
um um: Fix hostaudio build errors 2023-09-13 09:42:58 +02:00
x86 ANDROID: Build null_blk and scsi_debug as kernel modules 2024-02-01 23:53:56 +00:00
xtensa xtensa: boot/lib: fix function prototypes 2023-10-06 14:56:49 +02:00
.gitignore
Kconfig Merge 6.1.44 into android14-6.1-lts 2023-09-12 15:09:42 +00:00