Skip to content

Commit a8d39a6

Browse files
jpoimboeIngo Molnar
authored andcommitted
objtool: Remove redundant opts.noinstr dependency
The --noinstr dependecy on --link is already enforced in the cmdline arg parsing code. Remove the redundant check. Signed-off-by: Josh Poimboeuf <[email protected]> Signed-off-by: Ingo Molnar <[email protected]> Cc: Linus Torvalds <[email protected]> Link: https://lore.kernel.org/r/0ead7ffa0f5be2e81aebbcc585e07b2c98702b44.1742852847.git.jpoimboe@kernel.org
1 parent 876a4bc commit a8d39a6

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

tools/objtool/check.c

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -340,12 +340,7 @@ static void init_insn_state(struct objtool_file *file, struct insn_state *state,
340340
memset(state, 0, sizeof(*state));
341341
init_cfi_state(&state->cfi);
342342

343-
/*
344-
* We need the full vmlinux for noinstr validation, otherwise we can
345-
* not correctly determine insn_call_dest(insn)->sec (external symbols
346-
* do not have a section).
347-
*/
348-
if (opts.link && opts.noinstr && sec)
343+
if (opts.noinstr && sec)
349344
state->noinstr = sec->noinstr;
350345
}
351346

0 commit comments

Comments
 (0)