summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/bpf/progs/test_map_in_map_invalid.c
diff options
context:
space:
mode:
authorHengqi Chen <hengqi.chen@gmail.com>2021-10-01 00:14:56 +0800
committerAndrii Nakryiko <andrii@kernel.org>2021-10-01 15:31:51 -0700
commitbd368cb554d685c60e65ab799bf238663c682105 (patch)
tree99c4e3b27c85b415115fb1f648e7d663d4f1f669 /tools/testing/selftests/bpf/progs/test_map_in_map_invalid.c
parentf731052325efc3726577feb743c7495f880ae07d (diff)
selftests/bpf: Use BTF-defined key/value for map definitions
Change map definitions in BPF selftests to use BTF-defined key/value types. This unifies the map definitions and ensures libbpf won't emit warning about retrying map creation. Signed-off-by: Hengqi Chen <hengqi.chen@gmail.com> Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/20210930161456.3444544-3-hengqi.chen@gmail.com
Diffstat (limited to 'tools/testing/selftests/bpf/progs/test_map_in_map_invalid.c')
-rw-r--r--tools/testing/selftests/bpf/progs/test_map_in_map_invalid.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/testing/selftests/bpf/progs/test_map_in_map_invalid.c b/tools/testing/selftests/bpf/progs/test_map_in_map_invalid.c
index 703c08e06442..9c7d75cf0bd6 100644
--- a/tools/testing/selftests/bpf/progs/test_map_in_map_invalid.c
+++ b/tools/testing/selftests/bpf/progs/test_map_in_map_invalid.c
@@ -13,7 +13,7 @@ struct inner {
struct {
__uint(type, BPF_MAP_TYPE_ARRAY_OF_MAPS);
__uint(max_entries, 0); /* This will make map creation to fail */
- __uint(key_size, sizeof(__u32));
+ __type(key, __u32);
__array(values, struct inner);
} mim SEC(".maps");