[<prev] [next>] [day] [month] [year] [list]
Message-ID: <176060840056.709179.17703718813399608345.tip-bot2@tip-bot2>
Date: Thu, 16 Oct 2025 09:53:20 -0000
From: "tip-bot2 for Dylan Hatch" <tip-bot2@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: Dylan Hatch <dylanbhatch@...gle.com>, Josh Poimboeuf <jpoimboe@...nel.org>,
x86@...nel.org, linux-kernel@...r.kernel.org
Subject: [tip: objtool/core] objtool: Fix standalone --hacks=jump_label
The following commit has been merged into the objtool/core branch of tip:
Commit-ID: be8374a5ba7cbab6b97df94b4ffe0b92f5c8a6d2
Gitweb: https://git.kernel.org/tip/be8374a5ba7cbab6b97df94b4ffe0b92f5c8a6d2
Author: Dylan Hatch <dylanbhatch@...gle.com>
AuthorDate: Tue, 23 Sep 2025 00:49:41
Committer: Josh Poimboeuf <jpoimboe@...nel.org>
CommitterDate: Tue, 14 Oct 2025 14:45:21 -07:00
objtool: Fix standalone --hacks=jump_label
The objtool command line 'objtool --hacks=jump_label foo.o' on its own
should be expected to rewrite jump labels to NOPs. This means the
add_special_section_alts() code path needs to run when only this option
is provided.
This is mainly relevant in certain debugging situations, but could
potentially also fix kernel builds in which objtool is run with
--hacks=jump_label but without --orc, --stackval, --uaccess, or
--hacks=noinstr.
Fixes: de6fbcedf5ab ("objtool: Read special sections with alts only when specific options are selected")
Signed-off-by: Dylan Hatch <dylanbhatch@...gle.com>
Signed-off-by: Josh Poimboeuf <jpoimboe@...nel.org>
---
tools/objtool/check.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/tools/objtool/check.c b/tools/objtool/check.c
index a577057..b0e6479 100644
--- a/tools/objtool/check.c
+++ b/tools/objtool/check.c
@@ -2563,7 +2563,8 @@ static int decode_sections(struct objtool_file *file)
* Must be before add_jump_destinations(), which depends on 'func'
* being set for alternatives, to enable proper sibling call detection.
*/
- if (opts.stackval || opts.orc || opts.uaccess || opts.noinstr) {
+ if (opts.stackval || opts.orc || opts.uaccess || opts.noinstr ||
+ opts.hack_jump_label) {
ret = add_special_section_alts(file);
if (ret)
return ret;
Powered by blists - more mailing lists