Home
last modified time | relevance | path

Searched refs:map_fd (Results 1 – 11 of 11) sorted by relevance

/external/linux-kselftest/tools/testing/selftests/bpf/
Dtest_progs.c134 int err, prog_fd, map_fd; in test_xdp() local
142 map_fd = bpf_find_map(__func__, obj, "vip2tnl"); in test_xdp()
143 if (map_fd < 0) in test_xdp()
145 bpf_map_update_elem(map_fd, &key4, &value4, 0); in test_xdp()
146 bpf_map_update_elem(map_fd, &key6, &value6, 0); in test_xdp()
193 int err, i, prog_fd, map_fd; in test_l4lb() local
205 map_fd = bpf_find_map(__func__, obj, "vip_map"); in test_l4lb()
206 if (map_fd < 0) in test_l4lb()
208 bpf_map_update_elem(map_fd, &key, &value, 0); in test_l4lb()
210 map_fd = bpf_find_map(__func__, obj, "ch_rings"); in test_l4lb()
[all …]
Dtest_lpm_map.c426 int map_fd; in test_lpm_delete() local
432 map_fd = bpf_create_map(BPF_MAP_TYPE_LPM_TRIE, in test_lpm_delete()
435 assert(map_fd >= 0); in test_lpm_delete()
452 assert(bpf_map_update_elem(map_fd, key, &value, 0) == 0); in test_lpm_delete()
457 assert(bpf_map_update_elem(map_fd, key, &value, 0) == 0); in test_lpm_delete()
462 assert(bpf_map_update_elem(map_fd, key, &value, 0) == 0); in test_lpm_delete()
467 assert(bpf_map_update_elem(map_fd, key, &value, 0) == 0); in test_lpm_delete()
472 assert(bpf_map_lookup_elem(map_fd, key, &value) == -1 && in test_lpm_delete()
478 assert(bpf_map_lookup_elem(map_fd, key, &value) == 0); in test_lpm_delete()
484 assert(bpf_map_delete_elem(map_fd, key) == 0); in test_lpm_delete()
[all …]
Dtest_lru_map.c31 int map_fd; in create_map() local
33 map_fd = bpf_create_map(map_type, sizeof(unsigned long long), in create_map()
36 if (map_fd == -1) in create_map()
39 return map_fd; in create_map()
491 static void do_test_lru_sanity5(unsigned long long last_key, int map_fd) in do_test_lru_sanity5() argument
496 assert(!bpf_map_lookup_elem(map_fd, &last_key, value)); in do_test_lru_sanity5()
501 assert(!bpf_map_update_elem(map_fd, &key, value, BPF_NOEXIST)); in do_test_lru_sanity5()
502 assert(!bpf_map_lookup_elem(map_fd, &key, value)); in do_test_lru_sanity5()
505 assert(bpf_map_lookup_elem(map_fd, &last_key, value)); in do_test_lru_sanity5()
513 int map_fd; in test_lru_sanity5() local
[all …]
/external/compiler-rt/lib/sanitizer_common/
Dsanitizer_coverage_mapping_libcdep.cc99 fd_t map_fd = OpenFile(tmp_path.data(), WrOnly, &err); in CovUpdateMapping() local
100 if (map_fd == kInvalidFd) { in CovUpdateMapping()
106 if (!WriteToFile(map_fd, text.data(), text.length(), nullptr, &err)) { in CovUpdateMapping()
110 CloseFile(map_fd); in CovUpdateMapping()
/external/strace/
Dbpf.c117 uint32_t map_fd; in DEF_BPF_CMD_DECODER() member
125 PRINT_FIELD_FD("{", attr, map_fd, tcp); in DEF_BPF_CMD_DECODER()
137 uint32_t map_fd; in DEF_BPF_CMD_DECODER() member
146 PRINT_FIELD_FD("{", attr, map_fd, tcp); in DEF_BPF_CMD_DECODER()
160 uint32_t map_fd; in DEF_BPF_CMD_DECODER() member
167 PRINT_FIELD_FD("{", attr, map_fd, tcp); in DEF_BPF_CMD_DECODER()
178 uint32_t map_fd; in DEF_BPF_CMD_DECODER() member
186 PRINT_FIELD_FD("{", attr, map_fd, tcp); in DEF_BPF_CMD_DECODER()
/external/strace/tests-m32/
Dbpf.c247 DEF_BPF_INIT_FIRST(BPF_MAP_LOOKUP_ELEM, map_fd, -1)
259 .map_fd = -1, in init_BPF_MAP_LOOKUP_ELEM_attr()
289 .map_fd = -1, in init_BPF_MAP_UPDATE_ELEM_attr()
320 .map_fd = -1, in init_BPF_MAP_DELETE_ELEM_attr()
349 .map_fd = -1, in init_BPF_MAP_GET_NEXT_KEY_attr()
/external/strace/tests-mx32/
Dbpf.c247 DEF_BPF_INIT_FIRST(BPF_MAP_LOOKUP_ELEM, map_fd, -1)
259 .map_fd = -1, in init_BPF_MAP_LOOKUP_ELEM_attr()
289 .map_fd = -1, in init_BPF_MAP_UPDATE_ELEM_attr()
320 .map_fd = -1, in init_BPF_MAP_DELETE_ELEM_attr()
349 .map_fd = -1, in init_BPF_MAP_GET_NEXT_KEY_attr()
/external/strace/tests/
Dbpf.c247 DEF_BPF_INIT_FIRST(BPF_MAP_LOOKUP_ELEM, map_fd, -1)
259 .map_fd = -1, in init_BPF_MAP_LOOKUP_ELEM_attr()
289 .map_fd = -1, in init_BPF_MAP_UPDATE_ELEM_attr()
320 .map_fd = -1, in init_BPF_MAP_DELETE_ELEM_attr()
349 .map_fd = -1, in init_BPF_MAP_GET_NEXT_KEY_attr()
/external/iproute2/lib/
Dbpf.c148 attr.map_fd = fd; in bpf_map_update()
985 int ret, prog_fd, map_fd; in bpf_graft_map() local
1003 map_fd = bpf_obj_get(map_path, type); in bpf_graft_map()
1004 if (map_fd < 0) { in bpf_graft_map()
1007 ret = map_fd; in bpf_graft_map()
1011 ret = bpf_map_selfcheck_pinned(map_fd, &test, &ext, in bpf_graft_map()
1019 ret = bpf_map_update(map_fd, &map_key, &prog_fd, BPF_ANY); in bpf_graft_map()
1023 close(map_fd); in bpf_graft_map()
2135 int map_fd; member
2171 ret = bpf_derive_elf_map_from_fdinfo(aux->map_fd, &tmp, &aux->map); in bpf_tail_call_get_aux()
[all …]
/external/iproute2/include/uapi/linux/
Dbpf.h195 __u32 map_fd; member
/external/kernel-headers/original/uapi/linux/
Dbpf.h245 __u32 map_fd; member