From 333079522aafe9276ede700d067cc4f7ca797fd7 Mon Sep 17 00:00:00 2001 From: "Dmitry V. Levin" Date: Wed, 26 Dec 2018 03:38:33 +0000 Subject: [PATCH] xlat: update BPF_* constants * xlat/bpf_map_types.in (BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE): New constant introduced by Linux kernel commit v4.20-rc1~14^2~124^2~12^2~7. (BPF_MAP_TYPE_QUEUE, BPF_MAP_TYPE_STACK): New constants introduced by Linux kernel commit v4.20-rc1~151^2~32^2~11^2~3. * xlat/bpf_commands.in (BPF_MAP_LOOKUP_AND_DELETE_ELEM): New constant introduced by Linux kernel commit v4.20-rc1~151^2~32^2~11^2~2. * tests/bpf.c (BPF_MAP_CREATE_checks): Update. --- tests/bpf.c | 4 ++-- xlat/bpf_commands.in | 1 + xlat/bpf_map_types.in | 3 +++ 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/tests/bpf.c b/tests/bpf.c index 9e7f66f6..d1941683 100644 --- a/tests/bpf.c +++ b/tests/bpf.c @@ -278,7 +278,7 @@ static struct bpf_attr_check BPF_MAP_CREATE_checks[] = { }, { /* 2 */ .data = { .BPF_MAP_CREATE_data = { - .map_type = 21, + .map_type = 24, .key_size = 0xface1e55, .value_size = 0xbadc0ded, .max_entries = 0xbeefcafe, @@ -289,7 +289,7 @@ static struct bpf_attr_check BPF_MAP_CREATE_checks[] = { .map_ifindex = 3141592653, } }, .size = offsetofend(struct BPF_MAP_CREATE_struct, map_ifindex), - .str = "map_type=0x15 /* BPF_MAP_TYPE_??? */" + .str = "map_type=0x18 /* BPF_MAP_TYPE_??? */" ", key_size=4207812181, value_size=3134983661" ", max_entries=3203386110" ", map_flags=0xffffffc0 /* BPF_F_??? */" diff --git a/xlat/bpf_commands.in b/xlat/bpf_commands.in index befb029e..6dff998d 100644 --- a/xlat/bpf_commands.in +++ b/xlat/bpf_commands.in @@ -20,3 +20,4 @@ BPF_RAW_TRACEPOINT_OPEN 17 BPF_BTF_LOAD 18 BPF_BTF_GET_FD_BY_ID 19 BPF_TASK_FD_QUERY 20 +BPF_MAP_LOOKUP_AND_DELETE_ELEM 21 diff --git a/xlat/bpf_map_types.in b/xlat/bpf_map_types.in index e2273823..8a67d3ed 100644 --- a/xlat/bpf_map_types.in +++ b/xlat/bpf_map_types.in @@ -20,3 +20,6 @@ BPF_MAP_TYPE_XSKMAP 17 BPF_MAP_TYPE_SOCKHASH 18 BPF_MAP_TYPE_CGROUP_STORAGE 19 BPF_MAP_TYPE_REUSEPORT_SOCKARRAY 20 +BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE 21 +BPF_MAP_TYPE_QUEUE 22 +BPF_MAP_TYPE_STACK 23