Searched refs:htab (Results 1 - 18 of 18) sorted by relevance

/linux-master/tools/testing/selftests/bpf/progs/
H A Darena_htab.c26 struct htab __arena *htab; local
29 htab = bpf_alloc(sizeof(*htab));
30 cast_kern(htab);
31 htab_init(htab);
35 htab_update_elem(htab, i, i);
39 htab_update_elem(htab, i, i);
40 cast_user(htab);
41 htab_for_user = htab;
[all...]
H A Dhtab_update.c14 } htab SEC(".maps");
27 update_err = bpf_map_update_elem(&htab, &key, &value, 0);
H A Dsample_map_ret0.c10 } htab SEC(".maps");
26 value = bpf_map_lookup_elem(&htab, &key);
H A Dhtab_reuse.c19 } htab SEC(".maps");
H A Dhtab_mem_bench.c21 } htab SEC(".maps");
31 bpf_map_update_elem(&htab, &ctx->from, zeroed_value, flags);
49 bpf_map_delete_elem(&htab, &ctx->from);
/linux-master/tools/testing/selftests/bpf/prog_tests/
H A Darena_htab.c16 static void test_arena_htab_common(struct htab *htab) argument
20 printf("htab %p buckets %p n_buckets %d\n", htab, htab->buckets, htab->n_buckets);
21 ASSERT_OK_PTR(htab->buckets, "htab->buckets shouldn't be NULL");
22 for (i = 0; htab->buckets && i < 16; i += 4) {
24 * Walk htab bucket
37 struct htab *htab; local
69 struct htab *htab; local
[all...]
H A Dhtab_update.c39 err = bpf_map_update_elem(bpf_map__fd(skel->maps.htab), &key, &value, 0);
86 ctx.fd = bpf_map__fd(skel->maps.htab);
H A Dhtab_reuse.c74 ctx.fd = bpf_map__fd(skel->maps.htab);
/linux-master/tools/testing/selftests/bpf/
H A Dbpf_arena_htab.h13 struct htab { struct
17 typedef struct htab __arena htab_t;
19 static inline htab_bucket_t *__select_bucket(htab_t *htab, __u32 hash) argument
21 htab_bucket_t *b = htab->buckets;
24 return &b[hash & (htab->n_buckets - 1)];
27 static inline arena_list_head_t *select_bucket(htab_t *htab, __u32 hash) argument
29 return &__select_bucket(htab, hash)->head;
56 __weak int htab_lookup_elem(htab_t *htab __arg_arena, int key)
61 cast_kern(htab);
62 head = select_bucket(htab, ke
93 htab_init(htab_t *htab) argument
[all...]
H A Dtest_offload.py1211 htab = maps[0] if maps[0]["type"] == "hash" else maps[1]
1271 start_test("Test map delete (htab)...")
1273 bpftool("map delete id %d key %s" % (htab["id"], int2str("I", i)))
1278 (htab["id"], int2str("I", i)), fail=False)
/linux-master/kernel/bpf/
H A Dhashtab.c111 /* each htab element is struct htab_elem + key + value */
132 static inline bool htab_is_prealloc(const struct bpf_htab *htab) argument
134 return !(htab->map.map_flags & BPF_F_NO_PREALLOC);
137 static void htab_init_buckets(struct bpf_htab *htab) argument
141 for (i = 0; i < htab->n_buckets; i++) {
142 INIT_HLIST_NULLS_HEAD(&htab->buckets[i].head, i);
143 raw_spin_lock_init(&htab->buckets[i].raw_lock);
144 lockdep_set_class(&htab->buckets[i].raw_lock,
145 &htab->lockdep_key);
150 static inline int htab_lock_bucket(const struct bpf_htab *htab, argument
173 htab_unlock_bucket(const struct bpf_htab *htab, struct bucket *b, u32 hash, unsigned long flags) argument
186 htab_is_lru(const struct bpf_htab *htab) argument
192 htab_is_percpu(const struct bpf_htab *htab) argument
214 get_htab_elem(struct bpf_htab *htab, int i) argument
219 htab_has_extra_elems(struct bpf_htab *htab) argument
224 htab_free_prealloced_timers(struct bpf_htab *htab) argument
243 htab_free_prealloced_fields(struct bpf_htab *htab) argument
272 htab_free_elems(struct bpf_htab *htab) argument
302 prealloc_lru_pop(struct bpf_htab *htab, void *key, u32 hash) argument
318 prealloc_init(struct bpf_htab *htab) argument
377 prealloc_destroy(struct bpf_htab *htab) argument
387 alloc_extra_elems(struct bpf_htab *htab) argument
479 struct bpf_htab *htab; local
624 __select_bucket(struct bpf_htab *htab, u32 hash) argument
629 select_bucket(struct bpf_htab *htab, u32 hash) argument
677 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
781 check_and_free_fields(struct bpf_htab *htab, struct htab_elem *elem) argument
802 struct bpf_htab *htab = arg; local
834 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
890 htab_elem_free(struct bpf_htab *htab, struct htab_elem *l) argument
898 htab_put_fd_value(struct bpf_htab *htab, struct htab_elem *l) argument
909 is_map_full(struct bpf_htab *htab) argument
917 inc_elem_count(struct bpf_htab *htab) argument
927 dec_elem_count(struct bpf_htab *htab) argument
938 free_htab_elem(struct bpf_htab *htab, struct htab_elem *l) argument
952 pcpu_copy_value(struct bpf_htab *htab, void __percpu *pptr, void *value, bool onallcpus) argument
969 pcpu_init_value(struct bpf_htab *htab, void __percpu *pptr, void *value, bool onallcpus) argument
992 fd_htab_map_needs_adjust(const struct bpf_htab *htab) argument
998 alloc_htab_elem(struct bpf_htab *htab, void *key, void *value, u32 key_size, u32 hash, bool percpu, bool onallcpus, struct htab_elem *old_elem) argument
1079 check_flags(struct bpf_htab *htab, struct htab_elem *l_old, u64 map_flags) argument
1097 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
1190 htab_lru_push_free(struct bpf_htab *htab, struct htab_elem *elem) argument
1200 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
1269 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
1324 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
1406 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
1442 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
1476 delete_all_elements(struct bpf_htab *htab) argument
1497 htab_free_malloced_timers(struct bpf_htab *htab) argument
1518 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
1532 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
1589 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
1686 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
1978 struct bpf_htab *htab; member in struct:bpf_iter_seq_hash_map_info
1988 const struct bpf_htab *htab = info->htab; local
2164 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
2219 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
2387 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
2480 struct bpf_htab *htab = container_of(map, struct bpf_htab, map); local
[all...]
/linux-master/net/core/
H A Dsock_map.c862 static struct bpf_shtab_bucket *sock_hash_select_bucket(struct bpf_shtab *htab, argument
865 return &htab->buckets[hash & (htab->buckets_num - 1)];
885 struct bpf_shtab *htab = container_of(map, struct bpf_shtab, map); local
893 bucket = sock_hash_select_bucket(htab, hash);
899 static void sock_hash_free_elem(struct bpf_shtab *htab, argument
902 atomic_dec(&htab->count);
909 struct bpf_shtab *htab = container_of(map, struct bpf_shtab, map); local
914 bucket = sock_hash_select_bucket(htab, elem->hash);
926 sock_hash_free_elem(htab, ele
933 struct bpf_shtab *htab = container_of(map, struct bpf_shtab, map); local
957 sock_hash_alloc_elem(struct bpf_shtab *htab, void *key, u32 key_size, u32 hash, struct sock *sk, struct bpf_shtab_elem *old) argument
987 struct bpf_shtab *htab = container_of(map, struct bpf_shtab, map); local
1052 struct bpf_shtab *htab = container_of(map, struct bpf_shtab, map); local
1091 struct bpf_shtab *htab; local
1139 struct bpf_shtab *htab = container_of(map, struct bpf_shtab, map); local
1300 struct bpf_shtab *htab; member in struct:sock_hash_seq_info
1307 const struct bpf_shtab *htab = info->htab; local
1417 struct bpf_shtab *htab = container_of(map, struct bpf_shtab, map); local
[all...]
/linux-master/arch/powerpc/platforms/ps3/
H A DMakefile2 obj-y += setup.o mm.o time.o hvcall.o htab.o repository.o
/linux-master/drivers/s390/char/
H A Dsclp_rw.h75 unsigned short htab; member in struct:sclp_buffer
H A Dsclp_rw.c41 sclp_make_buffer(void *page, unsigned short columns, unsigned short htab) argument
59 buffer->htab = htab;
228 /* "go to (next htab-boundary + 1, same line)" */
235 } while (buffer->current_length % buffer->htab);
/linux-master/arch/powerpc/kvm/
H A Dbook3s_32_mmu_host.c46 static ulong htab; variable
110 ulong pteg = htab;
122 dprintk_mmu("htab: %lx | hash: %x | htabmask: %x | pteg: %lx\n",
123 htab, hash, htabmask, pteg);
380 htab = (ulong)__va(sdr1 & 0xffff0000);
/linux-master/tools/testing/selftests/bpf/benchs/
H A Dbench_htab_mem.c180 map = ctx.skel->maps.htab;
343 .name = "htab-mem",
/linux-master/net/xfrm/
H A Dxfrm_policy.c4183 struct xfrm_policy_hash *htab; local
4189 htab = &net->xfrm.policy_bydst[dir];
4190 htab->table = xfrm_hash_alloc(sz);
4191 if (!htab->table)
4193 htab->hmask = hmask;
4194 htab->dbits4 = 32;
4195 htab->sbits4 = 32;
4196 htab->dbits6 = 128;
4197 htab->sbits6 = 128;
4214 struct xfrm_policy_hash *htab; local
4239 struct xfrm_policy_hash *htab; local
[all...]

Completed in 233 milliseconds