objtool: Move object file loading out of check()
authorJulien Thierry <jthierry@redhat.com>
Tue, 25 Aug 2020 12:47:39 +0000 (13:47 +0100)
committerJosh Poimboeuf <jpoimboe@redhat.com>
Tue, 1 Sep 2020 22:19:07 +0000 (17:19 -0500)
commit6545eb030e6f14cef8793a86312483c788eaee46
tree19301101e41edf3595fd3a5ceaa5d7804abc3821
parent7c9903c9bf716d89b34f96cc2ed64e28dabf570b
objtool: Move object file loading out of check()

Structure objtool_file can be used by different subcommands. In fact
it already is, by check and orc.

Provide a function that allows to initialize objtool_file, that builtin
can call, without relying on check to do the correct setup for them and
explicitly hand the objtool_file to them.

Reviewed-by: Miroslav Benes <mbenes@suse.cz>
Signed-off-by: Julien Thierry <jthierry@redhat.com>
Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com>
tools/objtool/builtin-check.c
tools/objtool/builtin-orc.c
tools/objtool/check.c
tools/objtool/objtool.c
tools/objtool/objtool.h
tools/objtool/weak.c