]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
bpf/veristat: Fix veristat for map type BPF_MAP_TYPE_CGRP_STORAGE
authorSong Liu <song@kernel.org>
Fri, 13 Jun 2025 05:00:01 +0000 (22:00 -0700)
committerAndrii Nakryiko <andrii@kernel.org>
Fri, 13 Jun 2025 17:08:22 +0000 (10:08 -0700)
BPF_MAP_TYPE_CGRP_STORAGE doesn't allow non-zero max_entries. So veristat
should not set it to 1.

Signed-off-by: Song Liu <song@kernel.org>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/bpf/20250613050001.1058733-1-song@kernel.org
tools/testing/selftests/bpf/veristat.c

index b2bb20b009524d66bfc7758d39c0e5534a54ebae..70cdabd88c50a43056afbf164eb104ce42706c0f 100644 (file)
@@ -1182,6 +1182,7 @@ static void fixup_obj(struct bpf_object *obj, struct bpf_program *prog, const ch
                case BPF_MAP_TYPE_TASK_STORAGE:
                case BPF_MAP_TYPE_INODE_STORAGE:
                case BPF_MAP_TYPE_CGROUP_STORAGE:
+               case BPF_MAP_TYPE_CGRP_STORAGE:
                        break;
                case BPF_MAP_TYPE_STRUCT_OPS:
                        mask_unrelated_struct_ops_progs(obj, map, prog);