diff options
author | Max Filippov <jcmvbkbc@gmail.com> | 2017-03-27 02:44:47 -0700 |
---|---|---|
committer | Max Filippov <jcmvbkbc@gmail.com> | 2017-12-16 22:37:07 -0800 |
commit | 40d1a07b333ef1f7fce11ee20b8f4281d1a75fb9 (patch) | |
tree | 4855103872087025010742caa2ec0818f91f10ee /arch/xtensa/boot | |
parent | aa6476f76c1678d5d1087b39d3047601f0139ef0 (diff) | |
download | linux-40d1a07b333ef1f7fce11ee20b8f4281d1a75fb9.tar.bz2 |
xtensa: enable stack protector
The implementation is adopted from the ARM arch. GCC 7.3, 8 or newer is
required for building the xtensa kernel with SSP.
Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
Diffstat (limited to 'arch/xtensa/boot')
-rw-r--r-- | arch/xtensa/boot/lib/Makefile | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/xtensa/boot/lib/Makefile b/arch/xtensa/boot/lib/Makefile index d2a7f48564a4..2fe182915b63 100644 --- a/arch/xtensa/boot/lib/Makefile +++ b/arch/xtensa/boot/lib/Makefile @@ -15,6 +15,10 @@ CFLAGS_REMOVE_inftrees.o = -pg CFLAGS_REMOVE_inffast.o = -pg endif +CFLAGS_REMOVE_inflate.o += -fstack-protector -fstack-protector-strong +CFLAGS_REMOVE_zmem.o += -fstack-protector -fstack-protector-strong +CFLAGS_REMOVE_inftrees.o += -fstack-protector -fstack-protector-strong +CFLAGS_REMOVE_inffast.o += -fstack-protector -fstack-protector-strong quiet_cmd_copy_zlib = COPY $@ cmd_copy_zlib = cat $< > $@ |