Re: [PATCH bpf-next 3/5] bpftool: Update comments about skel data maps

Andrii Nakryiko <[email protected]>
Newsgroups org.kernel.vger.linux-kselftest,org.kernel.vger.bpf,org.kernel.vger.linux-kernel
Message-ID <CAEf4BzajJQobFoSUE9JxyieKupF5_j7q3jxWMHC8ZqAUcHY0yw@mail.gmail.com>
On Fri, Aug 14, 2026 at 10:32 AM Leon Hwang <[email protected]> wrote:
>
> Since is_skel_data() includes the non-memory-mapped percpu_array map, the
> "memory-mapped maps" in comments are incorrect for percpu data.
>
> Update "memory-mapped internal maps" to "skel data maps" for better
> explanation.

What is a "skel data map"? "memory-mapped internal map" is fine as is,
leave it be


>
> Signed-off-by: Leon Hwang <[email protected]>
> ---
>  tools/bpf/bpftool/gen.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/tools/bpf/bpftool/gen.c b/tools/bpf/bpftool/gen.c
> index a50540ef6521..e5e82255af24 100644
> --- a/tools/bpf/bpftool/gen.c
> +++ b/tools/bpf/bpftool/gen.c
> @@ -303,7 +303,7 @@ static int codegen_datasecs(struct bpf_object *obj, const char *obj_name)
>                 return -errno;
>
>         bpf_object__for_each_map(map, obj) {
> -               /* only generate definitions for memory-mapped internal maps */
> +               /* only generate definitions for skel data maps */
>                 if (!is_skel_data(map, map_ident, sizeof(map_ident)))
>                         continue;
>
> @@ -510,7 +510,7 @@ static size_t bpf_map_mmap_sz(const struct bpf_map *map)
>         return map_sz;
>  }
>
> -/* Emit type size asserts for all top-level fields in memory-mapped internal maps. */
> +/* Emit type size asserts for all top-level fields in skel data maps. */
>  static void codegen_asserts(struct bpf_object *obj, const char *obj_name)
>  {
>         struct btf *btf = bpf_object__btf(obj);
> --
> 2.55.0
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.