aboutsummaryrefslogtreecommitdiffstats
path: root/tools/objtool/builtin-check.c
diff options
context:
space:
mode:
authorSami Tolvanen <samitolvanen@google.com>2020-07-17 12:04:27 -0700
committerKees Cook <keescook@chromium.org>2021-02-23 12:46:57 -0800
commit0e731dbc18241d68318e0a7d2c2c0087c9073fb9 (patch)
treef84a8f54bed013cb49dc370484745143abc72133 /tools/objtool/builtin-check.c
parentobjtool: Fix __mcount_loc generation with Clang's assembler (diff)
downloadlinux-dev-0e731dbc18241d68318e0a7d2c2c0087c9073fb9.tar.xz
linux-dev-0e731dbc18241d68318e0a7d2c2c0087c9073fb9.zip
objtool: Don't autodetect vmlinux.o
With LTO, we run objtool on vmlinux.o, but don't want noinstr validation. This change requires --vmlinux to be passed to objtool explicitly. Suggested-by: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Sami Tolvanen <samitolvanen@google.com> Reviewed-by: Kees Cook <keescook@chromium.org>
Diffstat (limited to 'tools/objtool/builtin-check.c')
-rw-r--r--tools/objtool/builtin-check.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/tools/objtool/builtin-check.c b/tools/objtool/builtin-check.c
index e92e76f69176..facfc10bc5dc 100644
--- a/tools/objtool/builtin-check.c
+++ b/tools/objtool/builtin-check.c
@@ -41,7 +41,7 @@ const struct option check_options[] = {
int cmd_check(int argc, const char **argv)
{
- const char *objname, *s;
+ const char *objname;
struct objtool_file *file;
int ret;
@@ -52,10 +52,6 @@ int cmd_check(int argc, const char **argv)
objname = argv[0];
- s = strstr(objname, "vmlinux.o");
- if (s && !s[9])
- vmlinux = true;
-
file = objtool_open_read(objname);
if (!file)
return 1;