From: sashiko-bot@kernel.org
To: "Ihor Solodrai" <ihor.solodrai@linux.dev>
Cc: bpf@vger.kernel.org
Subject: Re: [PATCH bpf-next v2 1/8] libbpf: Look up BTF strings without making BTF modifiable
Date: Fri, 23 Oct 2026 22:39:54 +0000 [thread overview]
Message-ID: <sashiko-outbox-183298@kernel.org> (raw)
In-Reply-To: <20261023222652.3927736-2-ihor.solodrai@linux.dev>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] libbpf: non-standard multi-line comment style in struct btf
--
commit 0c3dbaeec612c1bd0bf2896a8ba4e0a1a8431c92
Author: Ihor Solodrai <ihor.solodrai@linux.dev>
libbpf: Look up BTF strings without making BTF modifiable
This patch updates btf__find_str() to build the string lookup index via a
new btf_ensure_strs_set() helper without making the BTF instance
modifiable, and updates btf__free() to unconditionally free strs_set.
> diff --git a/tools/lib/bpf/btf.c b/tools/lib/bpf/btf.c
> index d2ff6f5d6d5b6..d8907281c0efd 100644
> --- a/tools/lib/bpf/btf.c
> +++ b/tools/lib/bpf/btf.c
> @@ -153,9 +153,9 @@ struct btf {
> */
> int start_str_off;
>
> - /* only one of strs_data or strs_set can be non-NULL, depending on
> - * whether BTF is in a modifiable state (strs_set is used) or not
> - * (strs_data points inside raw_data)
> + /* strs_data points inside raw_data until BTF becomes modifiable,
> + * then strings live in strs_set. Before that, strs_set may exist
> + * as a lookup index for btf__find_str().
> */
[Severity: Low]
In struct btf in tools/lib/bpf/btf.c, should the opening /* of this
multi-line comment be placed on its own line to follow the BPF comment
style?
/*
* strs_data points inside raw_data until BTF becomes modifiable,
* then strings live in strs_set. Before that, strs_set may exist
* as a lookup index for btf__find_str().
*/
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261023222652.3927736-1-ihor.solodrai@linux.dev?part=1
next prev parent reply other threads:[~2026-10-23 22:39 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-23 22:26 [PATCH bpf-next v2 0/8] bpftool: Per-record CO-RE attributes in the C dump Ihor Solodrai
2026-10-23 22:26 ` [PATCH bpf-next v2 1/8] libbpf: Look up BTF strings without making BTF modifiable Ihor Solodrai
2026-10-23 22:39 ` sashiko-bot [this message]
2026-10-23 22:26 ` [PATCH bpf-next v2 2/8] selftests/bpf: Cover unknown BTF header-extension bytes in btf dump Ihor Solodrai
2026-10-23 22:26 ` [PATCH bpf-next v2 3/8] bpftool: Apply __bpf_relocatable per record on BTF dump Ihor Solodrai
2026-10-27 18:03 ` Andrii Nakryiko
2026-10-27 18:15 ` Ihor Solodrai
2026-10-27 18:21 ` Andrii Nakryiko
2026-10-27 18:26 ` Ihor Solodrai
2026-10-27 21:25 ` Ihor Solodrai
2026-10-23 22:26 ` [PATCH bpf-next v2 4/8] bpftool: Skip __bpf_relocatable on verifier-rewritten context types Ihor Solodrai
2026-10-27 18:06 ` Andrii Nakryiko
2026-10-27 18:10 ` Andrii Nakryiko
2026-10-27 18:17 ` Ihor Solodrai
2026-10-23 22:26 ` [PATCH bpf-next v2 5/8] bpftool: Emit __bpf_static_offset " Ihor Solodrai
2026-10-27 18:10 ` Andrii Nakryiko
2026-10-23 22:26 ` [PATCH bpf-next v2 6/8] selftests/bpf: Cover record attributes in bpftool BTF dumps Ihor Solodrai
2026-10-23 22:26 ` [PATCH bpf-next v2 7/8] selftests/bpf: Cover context and socket accesses through vmlinux.h Ihor Solodrai
2026-10-23 22:26 ` [PATCH bpf-next v2 8/8] bpftool: Document __bpf_relocatable and __bpf_static_offset Ihor Solodrai
2026-10-23 22:28 ` [PATCH bpf-next v2 0/8] bpftool: Per-record CO-RE attributes in the C dump Vineet Gupta
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=sashiko-outbox-183298@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=ihor.solodrai@linux.dev \
--cc=sashiko-reviews@lists.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.