From: Yonghong Song <yonghong.song@linux.dev>
To: Quentin Monnet <quentin@isovalent.com>,
Andrii Nakryiko <andrii.nakryiko@gmail.com>
Cc: bpf@vger.kernel.org, Alexei Starovoitov <ast@kernel.org>,
Andrii Nakryiko <andrii@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
kernel-team@fb.com, Martin KaFai Lau <martin.lau@kernel.org>
Subject: Re: [PATCH bpf-next] bpftool: Fix missing pids during link show
Date: Tue, 12 Mar 2024 08:23:43 -0700 [thread overview]
Message-ID: <b29a7355-350d-4ed7-9929-18f5188b5547@linux.dev> (raw)
In-Reply-To: <59db83c6-e16f-40f6-becc-968292d9564f@isovalent.com>
On 3/12/24 7:00 AM, Quentin Monnet wrote:
> 2024-03-11 23:30 UTC+0000 ~ Yonghong Song <yonghong.song@linux.dev>
>> On 3/11/24 4:13 PM, Andrii Nakryiko wrote:
>>> On Mon, Mar 11, 2024 at 2:41 PM Yonghong Song
>>> <yonghong.song@linux.dev> wrote:
>>>> Current 'bpftool link' command does not show pids, e.g.,
>>>> $ tools/build/bpftool/bpftool link
>>>> ...
>>>> 4: tracing prog 23
>>>> prog_type lsm attach_type lsm_mac
>>>> target_obj_id 1 target_btf_id 31320
>>>>
>>>> Hack the following change to enable normal libbpf debug output,
>>>> --- a/tools/bpf/bpftool/pids.c
>>>> +++ b/tools/bpf/bpftool/pids.c
>>>> @@ -121,9 +121,9 @@ int build_obj_refs_table(struct hashmap **map,
>>>> enum bpf_obj_type type)
>>>> /* we don't want output polluted with libbpf errors if
>>>> bpf_iter is not
>>>> * supported
>>>> */
>>>> - default_print = libbpf_set_print(libbpf_print_none);
>>>> + /* default_print = libbpf_set_print(libbpf_print_none); */
>>>> err = pid_iter_bpf__load(skel);
>>>> - libbpf_set_print(default_print);
>>>> + /* libbpf_set_print(default_print); */
> I'm taking note to make these logs available when users pass the --debug
> flag (https://github.com/libbpf/bpftool/issues/137), there's no reason
> to hide them in that case.
Totally make sense as most kernels used in production should already have
bpf_link and bpf_iter support already.
[...]
prev parent reply other threads:[~2024-03-12 15:23 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-11 21:41 [PATCH bpf-next] bpftool: Fix missing pids during link show Yonghong Song
2024-03-11 23:13 ` Andrii Nakryiko
2024-03-11 23:30 ` Yonghong Song
2024-03-12 14:00 ` Quentin Monnet
2024-03-12 15:23 ` Yonghong Song [this message]
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=b29a7355-350d-4ed7-9929-18f5188b5547@linux.dev \
--to=yonghong.song@linux.dev \
--cc=andrii.nakryiko@gmail.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=kernel-team@fb.com \
--cc=martin.lau@kernel.org \
--cc=quentin@isovalent.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