]> git.baikalelectronics.ru Git - kernel.git/commit
MIPS: properly stop .eh_frame generation
authorAlexander Lobakin <alobakin@pm.me>
Sun, 10 Jan 2021 11:56:28 +0000 (11:56 +0000)
committerThomas Bogendoerfer <tsbogend@alpha.franken.de>
Fri, 15 Jan 2021 14:27:54 +0000 (15:27 +0100)
commitf9be06e34c7ad6280084c19b0d0bf3001e10e76d
treed546bbcd0a47fcf320a0f60cc955bdfa07813e5e
parent393ab43ea2e114bdafc8c3c0a6cd1ec1c9834237
MIPS: properly stop .eh_frame generation

Commit 4ececce750d5 ("MIPS: Add DWARF unwinding to assembly") added
-fno-asynchronous-unwind-tables to KBUILD_CFLAGS to prevent compiler
from emitting .eh_frame symbols.
However, as MIPS heavily uses CFI, that's not enough. Use the
approach taken for x86 (as it also uses CFI) and explicitly put CFI
symbols into the .debug_frame section (except for VDSO).
This allows us to drop .eh_frame from DISCARDS as it's no longer
being generated.

Fixes: 4ececce750d5 ("MIPS: Add DWARF unwinding to assembly")
Suggested-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Alexander Lobakin <alobakin@pm.me>
Reviewed-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Nathan Chancellor <natechancellor@gmail.com>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
arch/mips/include/asm/asm.h
arch/mips/kernel/vmlinux.lds.S