linux-IllusionX/scripts
Josh Poimboeuf 2a0098d706 objtool: Fix seg fault with gold linker
Objtool segfaults when the gold linker is used with
CONFIG_MODVERSIONS=y and CONFIG_UNWINDER_ORC=y.

With CONFIG_MODVERSIONS=y, the .o file gets passed to the linker before
being passed to objtool.  The gold linker seems to strip unused ELF
symbols by default, which confuses objtool and causes the seg fault when
it's trying to generate ORC metadata.

Objtool should really be running immediately after GCC anyway, without a
linker call in between.  Change the makefile ordering so that objtool is
called before the linker.

Reported-and-tested-by: Markus <M4rkusXXL@web.de>
Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Fixes: ee9f8fce99 ("x86/unwind: Add the ORC unwinder")
Link: http://lkml.kernel.org/r/355f04da33581f4a3bf82e5b512973624a1e23a2.1516025651.git.jpoimboe@redhat.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2018-01-16 01:27:27 +01:00
..
basic
coccinelle
dtc
gcc-plugins
gdb
genksyms
kconfig
ksymoops
mod
package
selinux
tracing
.gitignore
adjust_autoksyms.sh
asn1_compiler.c
bloat-o-meter
bootgraph.pl
check_00index.sh
check_extable.sh
checkincludes.pl
checkkconfigsymbols.py
checkpatch.pl
checkstack.pl
checksyscalls.sh
checkversion.pl
cleanfile
cleanpatch
coccicheck
config
conmakehash.c
const_structs.checkpatch
decode_stacktrace.sh
decodecode
depmod.sh
diffconfig
export_report.pl
extract-cert.c
extract-ikconfig
extract-module-sig.pl
extract-sys-certs.pl
extract-vmlinux
extract_xc3028.pl
faddr2line
gcc-goto.sh
gcc-ld
gcc-plugin.sh
gcc-version.sh
gcc-x86_32-has-stack-protector.sh
gcc-x86_64-has-stack-protector.sh
gen_initramfs_list.sh
get_dvb_firmware
get_maintainer.pl
gfp-translate
headerdep.pl
headers.sh
headers_check.pl
headers_install.sh
insert-sys-cert.c
kallsyms.c
Kbuild.include
kernel-doc
ld-version.sh
leaking_addresses.pl scripts: add leaking_addresses.pl 2017-11-06 11:46:42 -08:00
Lindent
link-vmlinux.sh
Makefile
Makefile.asm-generic
Makefile.build objtool: Fix seg fault with gold linker 2018-01-16 01:27:27 +01:00
Makefile.clean
Makefile.dtbinst
Makefile.extrawarn
Makefile.gcc-plugins
Makefile.headersinst
Makefile.help
Makefile.host
Makefile.kasan
Makefile.lib
Makefile.modbuiltin
Makefile.modinst
Makefile.modpost
Makefile.modsign
Makefile.ubsan
makelst
markup_oops.pl
mkcompile_h
mkmakefile
mksysmap
mkuboot.sh
module-common.lds
namespace.pl
objdiff
parse-maintainers.pl
patch-kernel
pnmtologo.c
profile2linkerlist.pl
prune-kernel
recordmcount.c
recordmcount.h
recordmcount.pl
setlocalversion
show_delta
sign-file.c
sortextable.c
sortextable.h
spelling.txt
sphinx-pre-install
stackdelta
stackusage
tags.sh
unifdef.c
ver_linux
xen-hypercalls.sh
xz_wrap.sh