From: Joe Lawrence <joe.lawrence@redhat.com>
To: Mikulas Patocka <mpatocka@redhat.com>
Cc: Josh Poimboeuf <jpoimboe@kernel.org>,
Peter Zijlstra <peterz@infradead.org>,
Petr Mladek <pmladek@suse.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] objtool: fix compilation failure with the x32 toolchain
Date: Tue, 6 Jan 2026 16:55:12 -0500 [thread overview]
Message-ID: <aV2EwLdkXgJHf8Bz@redhat.com> (raw)
In-Reply-To: <a1158c99-fe0e-a218-4b5b-ffac212489f6@redhat.com>
On Tue, Jan 06, 2026 at 12:13:15PM +0100, Mikulas Patocka wrote:
> When using the x32 toolchain, compilation fails because the printf
> specifier "%lx" (long), doesn't match the type of the "checksum" variable
> (long long). Fix this by changing the printf specifier to "%llx" and
> casting "checksum" to unsigned long long.
>
> Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
> Fixes: a3493b33384a ("objtool/klp: Add --debug-checksum=<funcs> to show per-instruction checksums")
>
> ---
> tools/objtool/include/objtool/warn.h | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> Index: linux-2.6/tools/objtool/include/objtool/warn.h
> ===================================================================
> --- linux-2.6.orig/tools/objtool/include/objtool/warn.h 2025-12-31 20:10:31.000000000 +0100
> +++ linux-2.6/tools/objtool/include/objtool/warn.h 2025-12-31 20:14:15.000000000 +0100
> @@ -152,8 +152,8 @@ static inline void unindent(int *unused)
> if (unlikely(insn->sym && insn->sym->pfunc && \
> insn->sym->pfunc->debug_checksum)) { \
> char *insn_off = offstr(insn->sec, insn->offset); \
> - __dbg("checksum: %s %s %016lx", \
> - func->name, insn_off, checksum); \
> + __dbg("checksum: %s %s %016llx", \
> + func->name, insn_off, (unsigned long long)checksum);\
> free(insn_off); \
> } \
> })
>
Acked-by: Joe Lawrence <joe.lawrence@redhat.com>
--
Joe
next prev parent reply other threads:[~2026-01-06 21:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-06 11:13 [PATCH] objtool: fix compilation failure with the x32 toolchain Mikulas Patocka
2026-01-06 21:55 ` Joe Lawrence [this message]
2026-01-13 10:43 ` [tip: objtool/urgent] " tip-bot2 for Mikulas Patocka
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aV2EwLdkXgJHf8Bz@redhat.com \
--to=joe.lawrence@redhat.com \
--cc=jpoimboe@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mpatocka@redhat.com \
--cc=peterz@infradead.org \
--cc=pmladek@suse.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox