From: Quentin Monnet <qmo@kernel.org>
To: Andrii Nakryiko <andrii.nakryiko@gmail.com>
Cc: Andrii Nakryiko <andrii@kernel.org>,
bpf@vger.kernel.org, kernel-team@meta.com
Subject: Re: [PATCH bpf-next] libbpf: fix -Wformat warnings from format/argument type mismatches
Date: Tue, 30 Jun 2026 21:37:21 +0100 [thread overview]
Message-ID: <67b2d2f5-8632-4c39-bdaf-07a0d4d48c1c@kernel.org> (raw)
In-Reply-To: <CAEf4BzaCbvsBePEaiHaCniXWUBhgDnJ99=XPL4idLY3_xkH3dw@mail.gmail.com>
2026-06-30 13:15 UTC-0700 ~ Andrii Nakryiko <andrii.nakryiko@gmail.com>
> On Tue, Jun 30, 2026 at 1:01 PM Quentin Monnet <qmo@kernel.org> wrote:
>>
>> 2026-06-30 11:32 UTC-0700 ~ Andrii Nakryiko <andrii.nakryiko@gmail.com>
>>> On Fri, Jun 26, 2026 at 6:30 AM <patchwork-bot+netdevbpf@kernel.org> wrote:
>>>>
>>>> Hello:
>>>>
>>>> This patch was applied to bpf/bpf-next.git (master)
>>>> by Alexei Starovoitov <ast@kernel.org>:
>>>>
>>>> On Wed, 24 Jun 2026 13:49:46 -0700 you wrote:
>>>>> Building libbpf with -Wall (as happens via bpftool's bootstrap build)
>>>>> surfaces ~120 -Wformat warnings where pr_warn/pr_debug format specifiers
>>>>> don't match their argument types: %d for __u32/Elf64_Word, %u for signed
>>>>> ints, %zd for size_t, %ld for unsigned long, and %x/%lx/%llx applied to
>>>>> signed values.
>>>>>
>>>>> Match each specifier to its argument's type where a correctly-signed
>>>>> specifier exists (%d<->%u, %ld->%lu, %zd->%zu). For hex conversions,
>>>>> which have no signed form, cast the argument instead (%x->(unsigned),
>>>>> %lx->(unsigned long), %llx->(unsigned long long)). No functional change.
>>>>>
>>>>> [...]
>>>>
>>>> Here is the summary with links:
>>>> - [bpf-next] libbpf: fix -Wformat warnings from format/argument type mismatches
>>>> https://git.kernel.org/bpf/bpf-next/c/df3153758ddb
>>>>
>>>
>>> Quentin,
>>>
>>> I synced these changes to libbpf's Github mirror. Can you please
>>> update bpftool mirror's libbpf reference to include this change, so
>>> that I can fix these noisy warnings for wprof? Thanks!
>>
>>
>> Hi Andrii, I just synced it, thank you.
>>
>
> Thanks, Quentin!
>
> I got a bunch of new ones with latest bpftool sync, I haven't looked
> into it, but thought I'll mention in case it's something on bpftool's
> Github Makefile side:
[...]
Oh, I haven't observed these on my setup, I'll try to look into it when
I can. What compiler do you use? And do you see the same when compiling
from the kernel repo? The Makefiles should be rather close, in theory.
Quentin
next prev parent reply other threads:[~2026-06-30 20:37 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-24 20:49 [PATCH bpf-next] libbpf: fix -Wformat warnings from format/argument type mismatches Andrii Nakryiko
2026-06-26 2:01 ` bot+bpf-ci
2026-06-26 13:30 ` patchwork-bot+netdevbpf
2026-06-30 18:32 ` Andrii Nakryiko
2026-06-30 20:01 ` Quentin Monnet
2026-06-30 20:15 ` Andrii Nakryiko
2026-06-30 20:37 ` Quentin Monnet [this message]
2026-06-30 20:55 ` Andrii Nakryiko
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=67b2d2f5-8632-4c39-bdaf-07a0d4d48c1c@kernel.org \
--to=qmo@kernel.org \
--cc=andrii.nakryiko@gmail.com \
--cc=andrii@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=kernel-team@meta.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.