diff options
author | Tobias Klauser <tklauser@distanz.ch> | 2020-07-29 09:51:29 +0200 |
---|---|---|
committer | Palmer Dabbelt <palmerdabbelt@google.com> | 2020-08-04 15:02:49 -0700 |
commit | 40284a072c42f6177184fb1f62ba94c69e0c0277 (patch) | |
tree | b2eb252c0069b82397d479c54c155dce5efd7805 /arch/riscv | |
parent | 635093e306a3e4543937b079dc797c2ee0bafa09 (diff) | |
download | linux-stable-40284a072c42f6177184fb1f62ba94c69e0c0277.tar.gz linux-stable-40284a072c42f6177184fb1f62ba94c69e0c0277.tar.bz2 linux-stable-40284a072c42f6177184fb1f62ba94c69e0c0277.zip |
riscv: disable stack-protector for vDSO
Currently, building the vDSO with clang leads assembler errors like the
following:
/tmp/vgettimeofday-1ae0d2.s: Assembler messages:
/tmp/vgettimeofday-1ae0d2.s:28: Error: bad expression
/tmp/vgettimeofday-1ae0d2.s:28: Error: illegal operands `auipc a2,%got_pcrel_hi(__stack_chk_guard)'
Disable the stack-protector for vDSO to fix these.
Link: https://github.com/ClangBuiltLinux/linux/issues/1112
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com>
Diffstat (limited to 'arch/riscv')
-rw-r--r-- | arch/riscv/kernel/vdso/Makefile | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/riscv/kernel/vdso/Makefile b/arch/riscv/kernel/vdso/Makefile index c8c9e40023c6..478e7338ddc1 100644 --- a/arch/riscv/kernel/vdso/Makefile +++ b/arch/riscv/kernel/vdso/Makefile @@ -16,6 +16,8 @@ vdso-syms += flush_icache # Files to link into the vdso obj-vdso = $(patsubst %, %.o, $(vdso-syms)) note.o +ccflags-y := -fno-stack-protector + ifneq ($(c-gettimeofday-y),) CFLAGS_vgettimeofday.o += -fPIC -include $(c-gettimeofday-y) endif |