Lines Matching refs:map
33 struct bpf_map map; member
228 static void *trie_lookup_elem(struct bpf_map *map, void *_key) in trie_lookup_elem() argument
230 struct lpm_trie *trie = container_of(map, struct lpm_trie, map); in trie_lookup_elem()
289 size += trie->map.value_size; in lpm_trie_node_alloc()
291 node = bpf_map_kmalloc_node(&trie->map, size, GFP_NOWAIT | __GFP_NOWARN, in lpm_trie_node_alloc()
292 trie->map.numa_node); in lpm_trie_node_alloc()
300 trie->map.value_size); in lpm_trie_node_alloc()
306 static int trie_update_elem(struct bpf_map *map, in trie_update_elem() argument
309 struct lpm_trie *trie = container_of(map, struct lpm_trie, map); in trie_update_elem()
328 if (trie->n_entries == trie->map.max_entries) { in trie_update_elem()
437 static int trie_delete_elem(struct bpf_map *map, void *_key) in trie_delete_elem() argument
439 struct lpm_trie *trie = container_of(map, struct lpm_trie, map); in trie_delete_elem()
569 bpf_map_init_from_attr(&trie->map, attr); in trie_alloc()
576 return &trie->map; in trie_alloc()
579 static void trie_free(struct bpf_map *map) in trie_free() argument
581 struct lpm_trie *trie = container_of(map, struct lpm_trie, map); in trie_free()
618 static int trie_get_next_key(struct bpf_map *map, void *_key, void *_next_key) in trie_get_next_key() argument
621 struct lpm_trie *trie = container_of(map, struct lpm_trie, map); in trie_get_next_key()
716 static int trie_check_btf(const struct bpf_map *map, in trie_check_btf() argument