Skip to content

Commit e548709

Browse files
rgushchinborkmann
authored andcommitted
bpftool: add support for PERCPU_CGROUP_STORAGE maps
This commit adds support for BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE map type. Signed-off-by: Roman Gushchin <[email protected]> Acked-by: Jakub Kicinski <[email protected]> Acked-by: Song Liu <[email protected]> Cc: Daniel Borkmann <[email protected]> Cc: Alexei Starovoitov <[email protected]> Signed-off-by: Daniel Borkmann <[email protected]>
1 parent 25025e0 commit e548709

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tools/bpf/bpftool/map.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,13 +72,15 @@ static const char * const map_type_name[] = {
7272
[BPF_MAP_TYPE_SOCKHASH] = "sockhash",
7373
[BPF_MAP_TYPE_CGROUP_STORAGE] = "cgroup_storage",
7474
[BPF_MAP_TYPE_REUSEPORT_SOCKARRAY] = "reuseport_sockarray",
75+
[BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE] = "percpu_cgroup_storage",
7576
};
7677

7778
static bool map_is_per_cpu(__u32 type)
7879
{
7980
return type == BPF_MAP_TYPE_PERCPU_HASH ||
8081
type == BPF_MAP_TYPE_PERCPU_ARRAY ||
81-
type == BPF_MAP_TYPE_LRU_PERCPU_HASH;
82+
type == BPF_MAP_TYPE_LRU_PERCPU_HASH ||
83+
type == BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE;
8284
}
8385

8486
static bool map_is_map_of_maps(__u32 type)

0 commit comments

Comments
 (0)