Lines Matching refs:next_key

39 	long long key, next_key, first_key, value;  in test_hashmap()  local
102 assert(bpf_map_get_next_key(fd, &key, &next_key) == 0 && in test_hashmap()
103 (next_key == first_key)); in test_hashmap()
104 assert(bpf_map_get_next_key(fd, &next_key, &next_key) == 0 && in test_hashmap()
105 (next_key == 1 || next_key == 2) && in test_hashmap()
106 (next_key != first_key)); in test_hashmap()
107 assert(bpf_map_get_next_key(fd, &next_key, &next_key) == -1 && in test_hashmap()
119 assert(bpf_map_get_next_key(fd, NULL, &next_key) == -1 && in test_hashmap()
121 assert(bpf_map_get_next_key(fd, &key, &next_key) == -1 && in test_hashmap()
151 long long key, next_key, first_key; in test_hashmap_percpu() local
214 while (!bpf_map_get_next_key(fd, &key, &next_key)) { in test_hashmap_percpu()
216 assert(next_key == first_key); in test_hashmap_percpu()
219 assert((expected_key_mask & next_key) == next_key); in test_hashmap_percpu()
220 expected_key_mask &= ~next_key; in test_hashmap_percpu()
222 assert(bpf_map_lookup_elem(fd, &next_key, value) == 0); in test_hashmap_percpu()
227 key = next_key; in test_hashmap_percpu()
244 assert(bpf_map_get_next_key(fd, NULL, &next_key) == -1 && in test_hashmap_percpu()
246 assert(bpf_map_get_next_key(fd, &key, &next_key) == -1 && in test_hashmap_percpu()
277 long long key, value, next_key; in test_hashmap_walk() local
283 &next_key) == 0; i++) { in test_hashmap_walk()
284 key = next_key; in test_hashmap_walk()
292 next_key_valid = bpf_map_get_next_key(fd, &key, &next_key) == 0; in test_hashmap_walk()
296 key = next_key; in test_hashmap_walk()
302 &next_key) == 0; i++) { in test_hashmap_walk()
303 key = next_key; in test_hashmap_walk()
347 int key, next_key, fd; in test_arraymap() local
384 assert(bpf_map_get_next_key(fd, NULL, &next_key) == 0 && in test_arraymap()
385 next_key == 0); in test_arraymap()
386 assert(bpf_map_get_next_key(fd, &key, &next_key) == 0 && in test_arraymap()
387 next_key == 0); in test_arraymap()
388 assert(bpf_map_get_next_key(fd, &next_key, &next_key) == 0 && in test_arraymap()
389 next_key == 1); in test_arraymap()
390 assert(bpf_map_get_next_key(fd, &next_key, &next_key) == -1 && in test_arraymap()
404 int key, next_key, fd, i; in test_arraymap_percpu() local
443 assert(bpf_map_get_next_key(fd, NULL, &next_key) == 0 && in test_arraymap_percpu()
444 next_key == 0); in test_arraymap_percpu()
445 assert(bpf_map_get_next_key(fd, &key, &next_key) == 0 && in test_arraymap_percpu()
446 next_key == 0); in test_arraymap_percpu()
447 assert(bpf_map_get_next_key(fd, &next_key, &next_key) == 0 && in test_arraymap_percpu()
448 next_key == 1); in test_arraymap_percpu()
449 assert(bpf_map_get_next_key(fd, &next_key, &next_key) == -1 && in test_arraymap_percpu()