Skip to content

Commit cc49c71

Browse files
samitolvanenwilldeacon
authored andcommitted
efi/libstub: Disable Shadow Call Stack
Shadow stacks are not available in the EFI stub, filter out SCS flags. Suggested-by: James Morse <[email protected]> Signed-off-by: Sami Tolvanen <[email protected]> Reviewed-by: Kees Cook <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Signed-off-by: Will Deacon <[email protected]>
1 parent 439dc2a commit cc49c71

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

drivers/firmware/efi/libstub/Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,9 @@ KBUILD_CFLAGS := $(cflags-y) -DDISABLE_BRANCH_PROFILING \
3232
$(call cc-option,-fno-stack-protector) \
3333
-D__DISABLE_EXPORTS
3434

35+
# remove SCS flags from all objects in this directory
36+
KBUILD_CFLAGS := $(filter-out $(CC_FLAGS_SCS), $(KBUILD_CFLAGS))
37+
3538
GCOV_PROFILE := n
3639
KASAN_SANITIZE := n
3740
UBSAN_SANITIZE := n

0 commit comments

Comments
 (0)