Home
last modified time | relevance | path

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

/linux/tools/testing/selftests/bpf/
H A Dtest_lpm_map.c334 struct bpf_lpm_trie_key_u8 *key_ipv4; in test_lpm_ipaddr() local
342 key_size_ipv4 = sizeof(*key_ipv4) + sizeof(__u32); in test_lpm_ipaddr()
344 key_ipv4 = alloca(key_size_ipv4); in test_lpm_ipaddr()
359 key_ipv4->prefixlen = 16; in test_lpm_ipaddr()
360 inet_pton(AF_INET, "192.168.0.0", key_ipv4->data); in test_lpm_ipaddr()
361 assert(bpf_map_update_elem(map_fd_ipv4, key_ipv4, &value, 0) == 0); in test_lpm_ipaddr()
364 key_ipv4->prefixlen = 24; in test_lpm_ipaddr()
365 inet_pton(AF_INET, "192.168.0.0", key_ipv4->data); in test_lpm_ipaddr()
366 assert(bpf_map_update_elem(map_fd_ipv4, key_ipv4, &value, 0) == 0); in test_lpm_ipaddr()
369 key_ipv4->prefixlen = 24; in test_lpm_ipaddr()
[all …]