Home
last modified time | relevance | path

Searched refs:map_type (Results 1 – 25 of 79) sorted by relevance

1234

/linux/tools/testing/selftests/bpf/
A Dtest_lru_map.c33 map_fd = bpf_create_map(map_type, sizeof(unsigned long long), in create_map()
68 map.map_type = BPF_MAP_TYPE_ARRAY; in bpf_map_lookup_elem_with_ref_bit()
159 static void test_lru_sanity0(int map_type, int map_flags) in test_lru_sanity0() argument
173 lru_map_fd = create_map(map_type, map_flags, 2); in test_lru_sanity0()
277 lru_map_fd = create_map(map_type, map_flags, map_size); in test_lru_sanity1()
354 lru_map_fd = create_map(map_type, map_flags, map_size); in test_lru_sanity2()
380 if (map_type == BPF_MAP_TYPE_LRU_PERCPU_HASH) { in test_lru_sanity2()
517 lru_map_fd = create_map(map_type, map_flags, in test_lru_sanity4()
593 map_fd = create_map(map_type, map_flags, 1); in test_lru_sanity5()
709 lru_map_fd = create_map(map_type, map_flags, 2); in test_lru_sanity7()
[all …]
/linux/tools/testing/selftests/bpf/prog_tests/
A Dbtf.c70 enum bpf_map_type map_type; member
137 .map_type = BPF_MAP_TYPE_ARRAY,
192 .map_type = BPF_MAP_TYPE_ARRAY,
217 .map_type = BPF_MAP_TYPE_ARRAY,
258 .map_type = BPF_MAP_TYPE_ARRAY,
303 .map_type = BPF_MAP_TYPE_ARRAY,
4106 create_attr.map_type = test->map_type; in do_test_raw()
4947 enum bpf_map_type map_type; member
5178 create_attr.map_type = test->map_type; in do_test_pprint()
5339 pprint_test_template[0].map_type = pprint_tests_meta[i].map_type; in test_pprint()
[all …]
A Dsockmap_basic.c85 static void test_sockmap_create_update_free(enum bpf_map_type map_type) in test_sockmap_create_update_free() argument
94 map = bpf_create_map(map_type, sizeof(int), sizeof(int), 1, 0); in test_sockmap_create_update_free()
111 static void test_skmsg_helpers(enum bpf_map_type map_type) in test_skmsg_helpers() argument
140 static void test_sockmap_update(enum bpf_map_type map_type) in test_sockmap_update() argument
160 if (map_type == BPF_MAP_TYPE_SOCKMAP) in test_sockmap_update()
199 static void test_sockmap_copy(enum bpf_map_type map_type) in test_sockmap_copy() argument
215 if (map_type == BPF_MAP_TYPE_SOCKMAP) { in test_sockmap_copy()
A Dsockmap_ktls.c95 static void run_tests(int family, enum bpf_map_type map_type) in run_tests() argument
100 map = bpf_create_map(map_type, sizeof(int), sizeof(int), 1, 0); in run_tests()
109 map_type == BPF_MAP_TYPE_SOCKMAP ? "SOCKMAP" : "SOCKHASH"); in run_tests()
A Dmap_init.c38 static struct test_map_init *setup(enum bpf_map_type map_type, int map_sz, in setup() argument
48 err = bpf_map__set_type(skel->maps.hashmap1, map_type); in setup()
A Dlookup_and_delete.c44 static struct test_lookup_and_delete *setup_prog(enum bpf_map_type map_type, in setup_prog() argument
54 err = bpf_map__set_type(skel->maps.hash_map, map_type); in setup_prog()
/linux/include/trace/events/
A Dxdp.h94 enum bpf_map_type map_type,
97 TP_ARGS(dev, xdp, tgt, err, map_type, map_id, index),
112 if (map_type == BPF_MAP_TYPE_DEVMAP || map_type == BPF_MAP_TYPE_DEVMAP_HASH) {
144 enum bpf_map_type map_type,
146 TP_ARGS(dev, xdp, tgt, err, map_type, map_id, index)
153 enum bpf_map_type map_type,
155 TP_ARGS(dev, xdp, tgt, err, map_type, map_id, index)
175 enum bpf_map_type map_type,
177 TP_ARGS(dev, xdp, tgt, err, map_type, map_id, index)
184 enum bpf_map_type map_type,
[all …]
/linux/samples/bpf/
A Dtest_lru_dist.c212 map_fd = bpf_create_map(map_type, sizeof(unsigned long long), in create_map()
320 lru_map_fd = create_map(map_type, map_flags, in test_parallel_lru_dist()
323 lru_map_fd = create_map(map_type, map_flags, in test_parallel_lru_dist()
335 static void test_lru_loss0(int map_type, int map_flags) in test_lru_loss0() argument
349 map_fd = create_map(map_type, map_flags, 900 * nr_cpus); in test_lru_loss0()
351 map_fd = create_map(map_type, map_flags, 900); in test_lru_loss0()
389 static void test_lru_loss1(int map_type, int map_flags) in test_lru_loss1() argument
401 map_fd = create_map(map_type, map_flags, 1000 * nr_cpus); in test_lru_loss1()
403 map_fd = create_map(map_type, map_flags, 1000); in test_lru_loss1()
477 map_fd = create_map(map_type, map_flags, in test_parallel_lru_loss()
[all …]
/linux/kernel/bpf/
A Dmap_iter.c117 if (map->map_type == BPF_MAP_TYPE_PERCPU_HASH || in bpf_iter_attach_map()
118 map->map_type == BPF_MAP_TYPE_LRU_PERCPU_HASH || in bpf_iter_attach_map()
119 map->map_type == BPF_MAP_TYPE_PERCPU_ARRAY) in bpf_iter_attach_map()
121 else if (map->map_type != BPF_MAP_TYPE_HASH && in bpf_iter_attach_map()
122 map->map_type != BPF_MAP_TYPE_LRU_HASH && in bpf_iter_attach_map()
123 map->map_type != BPF_MAP_TYPE_ARRAY) in bpf_iter_attach_map()
A Dsyscall.c109 u32 type = attr->map_type; in find_and_alloc_map()
131 map->map_type = type; in find_and_alloc_map()
186 map->map_type == BPF_MAP_TYPE_SOCKMAP) { in bpf_map_update_value()
217 map->map_type == BPF_MAP_TYPE_STACK || in bpf_map_update_value()
257 map->map_type == BPF_MAP_TYPE_STACK || in bpf_map_copy_value()
362 map->map_type = attr->map_type; in bpf_map_init_from_attr()
580 map->map_type, in bpf_map_show_fdinfo()
797 if (map->map_type != BPF_MAP_TYPE_HASH && in map_check_btf()
817 if (map->map_type != BPF_MAP_TYPE_HASH && in map_check_btf()
819 map->map_type != BPF_MAP_TYPE_ARRAY) in map_check_btf()
[all …]
A Dmap_in_map.c48 inner_map_meta->map_type = inner_map->map_type; in bpf_map_meta_alloc()
82 return meta0->map_type == meta1->map_type && in bpf_map_meta_equal()
A Dhashtab.c200 return htab->map.map_type == BPF_MAP_TYPE_LRU_HASH || in htab_is_lru()
201 htab->map.map_type == BPF_MAP_TYPE_LRU_PERCPU_HASH; in htab_is_lru()
206 return htab->map.map_type == BPF_MAP_TYPE_PERCPU_HASH || in htab_is_percpu()
207 htab->map.map_type == BPF_MAP_TYPE_LRU_PERCPU_HASH; in htab_is_percpu()
403 bool lru = (attr->map_type == BPF_MAP_TYPE_LRU_HASH || in htab_map_alloc_check()
404 attr->map_type == BPF_MAP_TYPE_LRU_PERCPU_HASH); in htab_map_alloc_check()
466 bool lru = (attr->map_type == BPF_MAP_TYPE_LRU_HASH || in htab_map_alloc()
467 attr->map_type == BPF_MAP_TYPE_LRU_PERCPU_HASH); in htab_map_alloc()
830 if (htab->map.map_type == BPF_MAP_TYPE_PERCPU_HASH) in htab_elem_free()
2016 if (map->map_type == BPF_MAP_TYPE_PERCPU_HASH || in bpf_iter_init_hash_map()
[all …]
A Darraymap.c53 bool percpu = attr->map_type == BPF_MAP_TYPE_PERCPU_ARRAY; in array_map_alloc_check()
64 if (attr->map_type != BPF_MAP_TYPE_ARRAY && in array_map_alloc_check()
68 if (attr->map_type != BPF_MAP_TYPE_PERF_EVENT_ARRAY && in array_map_alloc_check()
83 bool percpu = attr->map_type == BPF_MAP_TYPE_PERCPU_ARRAY; in array_map_alloc()
320 if (array->map.map_type == BPF_MAP_TYPE_PERCPU_ARRAY) { in array_map_update_elem()
402 if (array->map.map_type == BPF_MAP_TYPE_PERCPU_ARRAY) in array_map_free()
464 if (map->map_type != BPF_MAP_TYPE_ARRAY || in array_map_check_btf()
614 if (map->map_type == BPF_MAP_TYPE_PERCPU_ARRAY) { in bpf_iter_init_array_map()
660 is_percpu = map->map_type == BPF_MAP_TYPE_PERCPU_ARRAY; in bpf_for_each_array_elem()
A Ddevmap.c132 if (attr->map_type == BPF_MAP_TYPE_DEVMAP_HASH) { in dev_map_init_map()
139 if (attr->map_type == BPF_MAP_TYPE_DEVMAP_HASH) { in dev_map_init_map()
207 if (dtab->map.map_type == BPF_MAP_TYPE_DEVMAP_HASH) { in dev_map_free()
610 if (map->map_type == BPF_MAP_TYPE_DEVMAP) { in dev_map_enqueue_multi()
728 if (map->map_type == BPF_MAP_TYPE_DEVMAP) { in dev_map_redirect_multi()
1101 if (dtab->map.map_type == BPF_MAP_TYPE_DEVMAP_HASH) { in dev_map_notification()
/linux/tools/lib/bpf/
A Dlibbpf_probes.c202 bool bpf_probe_map_type(enum bpf_map_type map_type, __u32 ifindex) in bpf_probe_map_type() argument
214 switch (map_type) { in bpf_probe_map_type()
274 if (map_type == BPF_MAP_TYPE_ARRAY_OF_MAPS || in bpf_probe_map_type()
275 map_type == BPF_MAP_TYPE_HASH_OF_MAPS) { in bpf_probe_map_type()
286 fd = bpf_create_map_in_map(map_type, NULL, sizeof(__u32), in bpf_probe_map_type()
291 attr.map_type = map_type; in bpf_probe_map_type()
A Dbpf.c96 attr.map_type = create_attr->map_type; in libbpf__bpf_create_map_xattr()
109 if (attr.map_type == BPF_MAP_TYPE_STRUCT_OPS) in libbpf__bpf_create_map_xattr()
124 p.map_type = create_attr->map_type; in bpf_create_map_xattr()
135 if (p.map_type == BPF_MAP_TYPE_STRUCT_OPS) in bpf_create_map_xattr()
144 int bpf_create_map_node(enum bpf_map_type map_type, const char *name, in bpf_create_map_node() argument
151 map_attr.map_type = map_type; in bpf_create_map_node()
164 int bpf_create_map(enum bpf_map_type map_type, int key_size, in bpf_create_map() argument
169 map_attr.map_type = map_type; in bpf_create_map()
185 map_attr.map_type = map_type; in bpf_create_map_name()
203 attr.map_type = map_type; in bpf_create_map_in_map_node()
[all …]
A Dbpf.h39 enum bpf_map_type map_type; member
57 LIBBPF_API int bpf_create_map_node(enum bpf_map_type map_type, const char *name,
60 LIBBPF_API int bpf_create_map_name(enum bpf_map_type map_type, const char *name,
63 LIBBPF_API int bpf_create_map(enum bpf_map_type map_type, int key_size,
65 LIBBPF_API int bpf_create_map_in_map_node(enum bpf_map_type map_type,
69 LIBBPF_API int bpf_create_map_in_map(enum bpf_map_type map_type,
/linux/fs/cifs/
A Dcifs_unicode.c18 int map_type; in cifs_remap() local
21 map_type = SFM_MAP_UNI_RSVD; in cifs_remap()
23 map_type = SFU_MAP_UNI_RSVD; in cifs_remap()
25 map_type = NO_MAP_UNI_RSVD; in cifs_remap()
27 return map_type; in cifs_remap()
179 const struct nls_table *codepage, int map_type) in cifs_from_utf16() argument
214 charlen = cifs_mapchar(tmp, ftmp, codepage, map_type); in cifs_from_utf16()
220 charlen = cifs_mapchar(&to[outlen], ftmp, codepage, map_type); in cifs_from_utf16()
A Dsmb2misc.c449 int map_type; in cifs_convert_path_to_utf16() local
452 map_type = SFM_MAP_UNI_RSVD; in cifs_convert_path_to_utf16()
454 map_type = SFU_MAP_UNI_RSVD; in cifs_convert_path_to_utf16()
456 map_type = NO_MAP_UNI_RSVD; in cifs_convert_path_to_utf16()
471 cifs_sb->local_nls, map_type); in cifs_convert_path_to_utf16()
/linux/tools/bpf/bpftool/
A Dfeature.c530 probe_map_type(enum bpf_map_type map_type, const char *define_prefix, in probe_map_type() argument
538 res = bpf_probe_map_type(map_type, ifindex); in probe_map_type()
544 if (!map_type_name[map_type]) { in probe_map_type()
545 p_info("map type name not found (type %d)", map_type); in probe_map_type()
549 if (strlen(map_type_name[map_type]) > maxlen) { in probe_map_type()
554 sprintf(feat_name, "have_%s_map_type", map_type_name[map_type]); in probe_map_type()
555 sprintf(define_name, "%s_map_type", map_type_name[map_type]); in probe_map_type()
557 sprintf(plain_desc, "%s%s", plain_comment, map_type_name[map_type]); in probe_map_type()
/linux/drivers/pci/
A Dp2pdma.c453 enum pci_p2pdma_map_type map_type = PCI_P2PDMA_MAP_THRU_HOST_BRIDGE; in calc_map_type_and_dist() local
513 map_type = PCI_P2PDMA_MAP_BUS_ADDR; in calc_map_type_and_dist()
532 map_type = PCI_P2PDMA_MAP_NOT_SUPPORTED; in calc_map_type_and_dist()
539 xa_mk_value(map_type), GFP_KERNEL); in calc_map_type_and_dist()
541 return map_type; in calc_map_type_and_dist()
927 enum pci_p2pdma_map_type map_type; in pci_p2pdma_unmap_sg_attrs() local
929 map_type = pci_p2pdma_map_type(sg_page(sg)->pgmap, dev); in pci_p2pdma_unmap_sg_attrs()
931 if (map_type == PCI_P2PDMA_MAP_THRU_HOST_BRIDGE) in pci_p2pdma_unmap_sg_attrs()
/linux/drivers/media/tuners/
A Dtda18271-priv.h179 enum tda18271_map_type map_type,
182 enum tda18271_map_type map_type,
/linux/drivers/gpu/drm/i915/gem/selftests/
A Di915_gem_migrate.c13 enum i915_map_type map_type = in igt_fill_check_buffer() local
19 cur = i915_gem_object_pin_map(obj, map_type); in igt_fill_check_buffer()
/linux/scripts/
A Dbpf_doc.py639 def map_type(self, t): member in PrinterHelpers
673 print('static %s %s(*%s)(' % (self.map_type(proto['ret_type']),
682 one_arg = '{}{}'.format(comma, self.map_type(t))
/linux/drivers/net/netdevsim/
A Dbpf.c461 if (offmap->map.map_type == BPF_MAP_TYPE_ARRAY) in nsim_map_delete_elem()
491 if (WARN_ON(offmap->map.map_type != BPF_MAP_TYPE_ARRAY && in nsim_bpf_map_alloc()
492 offmap->map.map_type != BPF_MAP_TYPE_HASH)) in nsim_bpf_map_alloc()
508 if (offmap->map.map_type == BPF_MAP_TYPE_ARRAY) { in nsim_bpf_map_alloc()

Completed in 59 milliseconds

1234