From: Jiayuan Chen <mrpre@163.com>
To: bpf@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, ast@kernel.org,
daniel@iogearbox.net, davem@davemloft.net, kuba@kernel.org,
hawk@kernel.org, john.fastabend@gmail.com, andrii@kernel.org,
martin.lau@linux.dev, eddyz87@gmail.com, song@kernel.org,
yonghong.song@linux.dev, kpsingh@kernel.org, sdf@fomichev.me,
haoluo@google.com, jolsa@kernel.org, qmo@kernel.org,
Jiayuan Chen <mrpre@163.com>
Subject: [PATCH bpf-next v1 0/1] Using the right format specifiers for bpftool
Date: Fri, 7 Feb 2025 20:37:05 +0800 [thread overview]
Message-ID: <20250207123706.727928-1-mrpre@163.com> (raw)
Fixed some incorrect formatting specifiers that were exposed when I added
the "-Wformat" flag to the compiler options.
This patch doesn't include "-Wformat" in the Makefile for now, as I've
only addressed some obvious semantic issues with the compiler warnings.
There are still other warnings that need to be tackled.
For example, there's an ifindex that's sometimes defined as a signed type
and sometimes as an unsigned type, which makes formatting a real pain
- sometimes it needs %d and sometimes %u. This might require a more
fundamental fix from the variable definition side.
If the maintainer is okay with adding "-Wformat" to the
tools/bpf/bpftool/Makefile, please let us know, and we can follow up with
further fixes.
Jiayuan Chen (1):
bpftool: Using the right format specifiers
tools/bpf/bpftool/gen.c | 12 ++++++------
tools/bpf/bpftool/link.c | 14 +++++++-------
tools/bpf/bpftool/main.c | 8 ++++----
tools/bpf/bpftool/map.c | 10 +++++-----
4 files changed, 22 insertions(+), 22 deletions(-)
--
2.43.5
next reply other threads:[~2025-02-07 12:39 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-07 12:37 Jiayuan Chen [this message]
2025-02-07 12:37 ` [PATCH bpf-next v1 1/1] bpftool: Using the right format specifiers Jiayuan Chen
2025-02-07 13:22 ` Quentin Monnet
2025-02-07 13:22 ` [PATCH bpf-next v1 0/1] Using the right format specifiers for bpftool Quentin Monnet
2025-02-07 14:27 ` Jiayuan Chen
2025-02-07 15:08 ` Quentin Monnet
2025-02-11 0:10 ` patchwork-bot+netdevbpf
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=20250207123706.727928-1-mrpre@163.com \
--to=mrpre@163.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=eddyz87@gmail.com \
--cc=haoluo@google.com \
--cc=hawk@kernel.org \
--cc=john.fastabend@gmail.com \
--cc=jolsa@kernel.org \
--cc=kpsingh@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=martin.lau@linux.dev \
--cc=qmo@kernel.org \
--cc=sdf@fomichev.me \
--cc=song@kernel.org \
--cc=yonghong.song@linux.dev \
/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.