Home
last modified time | relevance | path

Searched refs:bpf_map_lookup_elem (Results 1 – 12 of 12) sorted by relevance

/tools/testing/selftests/bpf/
Dtest_lru_map.c49 assert(!bpf_map_lookup_elem(map1, &next_key, value1)); in map_subset()
50 ret = bpf_map_lookup_elem(map0, &next_key, value0); in map_subset()
138 assert(bpf_map_lookup_elem(lru_map_fd, &key, value) == -1 && in test_lru_sanity0()
152 assert(bpf_map_lookup_elem(lru_map_fd, &key, value) == -1 && in test_lru_sanity0()
159 assert(!bpf_map_lookup_elem(lru_map_fd, &key, value)); in test_lru_sanity0()
169 assert(bpf_map_lookup_elem(lru_map_fd, &key, value) == -1); in test_lru_sanity0()
223 assert(!bpf_map_lookup_elem(lru_map_fd, &key, value)); in test_lru_sanity1()
324 assert(bpf_map_lookup_elem(lru_map_fd, &key, value)); in test_lru_sanity2()
327 assert(!bpf_map_lookup_elem(lru_map_fd, &key, value)); in test_lru_sanity2()
406 assert(!bpf_map_lookup_elem(lru_map_fd, &key, value)); in test_lru_sanity3()
[all …]
Dtest_lpm_map.c214 r = bpf_map_lookup_elem(map, key, value); in test_lpm_map()
303 assert(bpf_map_lookup_elem(map_fd_ipv4, key_ipv4, &value) == 0); in test_lpm_ipaddr()
307 assert(bpf_map_lookup_elem(map_fd_ipv4, key_ipv4, &value) == 0); in test_lpm_ipaddr()
311 assert(bpf_map_lookup_elem(map_fd_ipv6, key_ipv6, &value) == 0); in test_lpm_ipaddr()
315 assert(bpf_map_lookup_elem(map_fd_ipv6, key_ipv6, &value) == 0); in test_lpm_ipaddr()
320 assert(bpf_map_lookup_elem(map_fd_ipv4, key_ipv4, &value) == -1 && in test_lpm_ipaddr()
324 assert(bpf_map_lookup_elem(map_fd_ipv4, key_ipv4, &value) == -1 && in test_lpm_ipaddr()
328 assert(bpf_map_lookup_elem(map_fd_ipv6, key_ipv6, &value) == -1 && in test_lpm_ipaddr()
Dtest_maps.c58 assert(bpf_map_lookup_elem(fd, &key, &value) == 0 && value == 1234); in test_hashmap()
62 assert(bpf_map_lookup_elem(fd, &key, &value) == -1 && errno == ENOENT); in test_hashmap()
177 assert(bpf_map_lookup_elem(fd, &key, value) == 0 && in test_hashmap_percpu()
182 assert(bpf_map_lookup_elem(fd, &key, value) == -1 && errno == ENOENT); in test_hashmap_percpu()
215 assert(bpf_map_lookup_elem(fd, &next_key, value) == 0); in test_hashmap_percpu()
266 assert(bpf_map_lookup_elem(fd, &key, &value) == 0); in test_hashmap_walk()
274 assert(bpf_map_lookup_elem(fd, &key, &value) == 0); in test_hashmap_walk()
285 assert(bpf_map_lookup_elem(fd, &key, &value) == 0); in test_hashmap_walk()
315 assert(bpf_map_lookup_elem(fd, &key, &value) == 0 && value == 1234); in test_arraymap()
319 assert(bpf_map_lookup_elem(fd, &key, &value) == 0 && value == 0); in test_arraymap()
[all …]
Dtest_obj_id.c32 value = bpf_map_lookup_elem(&test_map_id, &key); in test_obj_id()
Dtest_l4lb.c226 real_pos = bpf_map_lookup_elem(&ch_rings, &key); in get_packet_dst()
230 *real = bpf_map_lookup_elem(&reals, &key); in get_packet_dst()
413 vip_info = bpf_map_lookup_elem(&vip_map, &vip); in process_packet()
416 vip_info = bpf_map_lookup_elem(&vip_map, &vip); in process_packet()
429 cval = bpf_map_lookup_elem(&ctl_array, &v6_intf_pos); in process_packet()
436 cval = bpf_map_lookup_elem(&ctl_array, &v4_intf_pos); in process_packet()
443 data_stats = bpf_map_lookup_elem(&stats, &vip_num); in process_packet()
Dtest_xdp.c43 rxcnt_count = bpf_map_lookup_elem(&rxcnt, &protocol); in count_tx()
108 tnl = bpf_map_lookup_elem(&vip2tnl, &vip); in handle_ipv4()
178 tnl = bpf_map_lookup_elem(&vip2tnl, &vip); in handle_ipv6()
Dtest_progs.c234 bpf_map_lookup_elem(map_fd, &stats_key, stats); in test_l4lb()
451 err = bpf_map_lookup_elem(map_fd, &array_key, &array_value); in test_bpf_obj_id()
Dbpf_helpers.h12 static void *(*bpf_map_lookup_elem)(void *map, void *key) = variable
/tools/perf/tests/
Dbpf-script-example.c14 static void *(*bpf_map_lookup_elem)(void *map, void *key) = variable
38 int *flag = bpf_map_lookup_elem(&flip_table, &ind); in bpf_func__SyS_epoll_wait()
Dbpf-script-test-relocation.c14 static void *(*bpf_map_lookup_elem)(void *map, void *key) = variable
/tools/lib/bpf/
Dbpf.h53 int bpf_map_lookup_elem(int fd, const void *key, void *value);
Dbpf.c184 int bpf_map_lookup_elem(int fd, const void *key, void *value) in bpf_map_lookup_elem() function