/linux-master/tools/testing/selftests/bpf/prog_tests/ |
H A D | bloom_filter_map.c | 16 fd = bpf_map_create(BPF_MAP_TYPE_BLOOM_FILTER, NULL, 4, sizeof(value), 100, NULL); 17 if (!ASSERT_LT(fd, 0, "bpf_map_create bloom filter invalid key size")) 21 fd = bpf_map_create(BPF_MAP_TYPE_BLOOM_FILTER, NULL, 0, 0, 100, NULL); 22 if (!ASSERT_LT(fd, 0, "bpf_map_create bloom filter invalid value size 0")) 26 fd = bpf_map_create(BPF_MAP_TYPE_BLOOM_FILTER, NULL, 0, INT32_MAX, 100, NULL); 27 if (!ASSERT_LT(fd, 0, "bpf_map_create bloom filter invalid value too large")) 31 fd = bpf_map_create(BPF_MAP_TYPE_BLOOM_FILTER, NULL, 0, sizeof(value), 0, NULL); 32 if (!ASSERT_LT(fd, 0, "bpf_map_create bloom filter invalid max entries size")) 37 fd = bpf_map_create(BPF_MAP_TYPE_BLOOM_FILTER, NULL, 0, sizeof(value), 100, &opts); 38 if (!ASSERT_LT(fd, 0, "bpf_map_create bloo [all...] |
H A D | map_btf.c | 30 map_fd_arr[i] = bpf_map_create(BPF_MAP_TYPE_PERCPU_ARRAY, NULL, 4, 4, 256, NULL);
|
H A D | cgroup_attach_multi.c | 18 map_fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, NULL, 4, 8, 1, NULL); 24 cgroup_storage_fd = bpf_map_create(BPF_MAP_TYPE_CGROUP_STORAGE, NULL, 31 percpu_cgroup_storage_fd = bpf_map_create(
|
H A D | map_in_map.c | 36 fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, NULL, 4, 4, 1, NULL);
|
H A D | bpf_obj_pinning.c | 75 map_fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, map_name, 4, 4, 1, NULL); 250 map_fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, map_name, 4, 4, 1, NULL);
|
H A D | sockmap_ktls.c | 153 map = bpf_map_create(map_type, NULL, sizeof(int), sizeof(int), 1, NULL); 154 if (!ASSERT_GE(map, 0, "bpf_map_create"))
|
H A D | ringbuf_multi.c | 62 proto_fd = bpf_map_create(BPF_MAP_TYPE_RINGBUF, NULL, 0, 0, page_size, NULL); 63 if (CHECK(proto_fd < 0, "bpf_map_create", "bpf_map_create failed\n"))
|
H A D | test_bpffs.c | 89 map = bpf_map_create(BPF_MAP_TYPE_ARRAY, NULL, 4, 4, 1, NULL);
|
/linux-master/samples/bpf/ |
H A D | test_cgrp2_array_pin.c | 67 array_fd = bpf_map_create(BPF_MAP_TYPE_CGROUP_ARRAY, NULL,
|
H A D | sock_example.c | 41 map_fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, NULL, sizeof(key), sizeof(value),
|
H A D | fds_example.c | 83 fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, NULL, sizeof(uint32_t),
|
H A D | test_cgrp2_attach.c | 97 map_fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, NULL,
|
H A D | test_lru_dist.c | 102 lru->map_fd = bpf_map_create(BPF_MAP_TYPE_HASH, NULL, 209 map_fd = bpf_map_create(map_type, NULL, sizeof(unsigned long long),
|
/linux-master/tools/testing/selftests/bpf/ |
H A D | test_cgroup_storage.c | 57 map_fd = bpf_map_create(BPF_MAP_TYPE_CGROUP_STORAGE, NULL, sizeof(key), 64 percpu_map_fd = bpf_map_create(BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE, NULL,
|
H A D | test_maps.c | 42 fd = bpf_map_create(BPF_MAP_TYPE_HASH, NULL, sizeof(key), sizeof(value), 2, &map_opts); 139 fd = bpf_map_create(BPF_MAP_TYPE_HASH, NULL, i, j, 2, &map_opts); 160 fd = bpf_map_create(BPF_MAP_TYPE_PERCPU_HASH, NULL, sizeof(key), 273 fd = bpf_map_create(BPF_MAP_TYPE_HASH, NULL, sizeof(key), sizeof(value), 366 fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, NULL, sizeof(key), sizeof(value), 2, NULL); 421 fd = bpf_map_create(BPF_MAP_TYPE_PERCPU_ARRAY, NULL, sizeof(key), 484 fd = bpf_map_create(BPF_MAP_TYPE_PERCPU_ARRAY, NULL, sizeof(key), 516 fd = bpf_map_create(BPF_MAP_TYPE_DEVMAP, NULL, sizeof(key), sizeof(value), 2, NULL); 530 fd = bpf_map_create(BPF_MAP_TYPE_DEVMAP_HASH, NULL, sizeof(key), sizeof(value), 2, NULL); 550 fd = bpf_map_create(BPF_MAP_TYPE_QUEU [all...] |
H A D | test_lpm_map.c | 237 map = bpf_map_create(BPF_MAP_TYPE_LPM_TRIE, NULL, 347 map_fd_ipv4 = bpf_map_create(BPF_MAP_TYPE_LPM_TRIE, NULL, 352 map_fd_ipv6 = bpf_map_create(BPF_MAP_TYPE_LPM_TRIE, NULL, 434 map_fd = bpf_map_create(BPF_MAP_TYPE_LPM_TRIE, NULL, 544 map_fd = bpf_map_create(BPF_MAP_TYPE_LPM_TRIE, NULL, key_size, sizeof(value), 100, &opts); 756 map_fd = bpf_map_create(BPF_MAP_TYPE_LPM_TRIE, NULL, key_size, value_size, 100, &opts);
|
H A D | test_verifier.c | 553 fd = bpf_map_create(type, NULL, size_key, size_value, max_elem, &opts); 609 mfd = bpf_map_create(BPF_MAP_TYPE_PROG_ARRAY, NULL, sizeof(int), 643 inner_map_fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, NULL, sizeof(int), 653 outer_map_fd = bpf_map_create(BPF_MAP_TYPE_ARRAY_OF_MAPS, NULL, 673 fd = bpf_map_create(type, NULL, sizeof(struct bpf_cgroup_storage_key), 815 fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, "test_map", 4, 8, 1, &opts); 834 fd = bpf_map_create(BPF_MAP_TYPE_SK_STORAGE, "test_map", 4, 8, 0, &opts); 854 fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, "test_map", 4, 16, 1, &opts); 873 fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, "test_map", 4, 24, 1, &opts);
|
/linux-master/tools/testing/selftests/bpf/map_tests/ |
H A D | sk_storage_map.c | 151 map_fd = bpf_map_create(BPF_MAP_TYPE_SK_STORAGE, "sk_storage_map", 4, 8, 0, &map_opts); 155 "bpf_map_create()", "errno:%d\n", errno); 474 map_fd = bpf_map_create(BPF_MAP_TYPE_SK_STORAGE, "sk_storage_map", 4, 8, 0, &map_opts); 475 CHECK(map_fd == -1, "bpf_map_create(good_xattr)", 565 err = bpf_map_create(BPF_MAP_TYPE_SK_STORAGE, "sk_storage_map", 4, 8, 0, &bad_xattr); 566 CHECK(!err || errno != EINVAL, "bpf_map_create(bad_xattr)", 571 err = bpf_map_create(BPF_MAP_TYPE_SK_STORAGE, "sk_storage_map", 4, 8, 0, &bad_xattr); 572 CHECK(!err || errno != EINVAL, "bpf_map_create(bad_xattr)", 575 err = bpf_map_create(BPF_MAP_TYPE_SK_STORAGE, "sk_storage_map", 4, 8, 1, &map_opts); 576 CHECK(!err || errno != EINVAL, "bpf_map_create(bad_xatt [all...] |
H A D | map_in_map_batch_ops.c | 41 map_fd = bpf_map_create(map_type, map_name, sizeof(__u32), 44 "inner bpf_map_create() failed", 72 outer_map_fd = bpf_map_create(map_type, "outer_map", sizeof(__u32), 76 "outer bpf_map_create()",
|
H A D | lpm_trie_map_batch_ops.c | 80 map_fd = bpf_map_create(BPF_MAP_TYPE_LPM_TRIE, "lpm_trie_map", 83 CHECK(map_fd == -1, "bpf_map_create()", "error:%s\n",
|
H A D | array_map_batch_ops.c | 83 map_fd = bpf_map_create(is_pcpu ? BPF_MAP_TYPE_PERCPU_ARRAY : BPF_MAP_TYPE_ARRAY, 86 "bpf_map_create()", "error:%s\n", strerror(errno));
|
H A D | map_percpu_stats.c | 151 map_fd = bpf_map_create(BPF_MAP_TYPE_HASH, "small", 4, 4, 4, NULL); 152 CHECK(map_fd < 0, "bpf_map_create()", "error:%s (name=%s)\n", 348 map_fd = bpf_map_create(type, name, key_size, val_size, max_entries, map_opts); 349 CHECK(map_fd < 0, "bpf_map_create()", "error:%s (name=%s)\n",
|
/linux-master/tools/testing/selftests/bpf/benchs/ |
H A D | bench_local_storage.c | 147 fd = bpf_map_create(BPF_MAP_TYPE_HASH, NULL, sizeof(int), 150 fd = bpf_map_create(BPF_MAP_TYPE_TASK_STORAGE, NULL, sizeof(int),
|
/linux-master/tools/lib/bpf/ |
H A D | features.c | 67 map = bpf_map_create(BPF_MAP_TYPE_ARRAY, "libbpf_global", sizeof(int), 32, 1, &map_opts); 222 fd = bpf_map_create(BPF_MAP_TYPE_ARRAY, "libbpf_mmap", sizeof(int), sizeof(int), 1, &opts); 285 map = bpf_map_create(BPF_MAP_TYPE_ARRAY, "libbpf_det_bind", sizeof(int), 32, 1, &map_opts);
|
H A D | libbpf_probes.c | 374 fd_inner = bpf_map_create(BPF_MAP_TYPE_HASH, NULL, 388 fd = bpf_map_create(map_type, NULL, key_size, value_size, max_entries, &opts);
|