Home
last modified time | relevance | path

Searched refs:ht (Results 1 – 25 of 133) sorted by relevance

123456

/linux-6.6.21/lib/ !
Drhashtable.c37 static u32 head_hashfn(struct rhashtable *ht, in head_hashfn() argument
41 return rht_head_hashfn(ht, tbl, he, ht->p); in head_hashfn()
47 int lockdep_rht_mutex_is_held(struct rhashtable *ht) in lockdep_rht_mutex_is_held() argument
49 return (debug_locks) ? lockdep_is_held(&ht->mutex) : 1; in lockdep_rht_mutex_is_held()
122 static union nested_table *nested_table_alloc(struct rhashtable *ht, in nested_table_alloc() argument
147 static struct bucket_table *nested_bucket_table_alloc(struct rhashtable *ht, in nested_bucket_table_alloc() argument
164 if (!nested_table_alloc(ht, (union nested_table __rcu **)tbl->buckets, in nested_bucket_table_alloc()
175 static struct bucket_table *bucket_table_alloc(struct rhashtable *ht, in bucket_table_alloc() argument
189 tbl = nested_bucket_table_alloc(ht, nbuckets, gfp); in bucket_table_alloc()
211 static struct bucket_table *rhashtable_last_table(struct rhashtable *ht, in rhashtable_last_table() argument
[all …]
Dtest_rhashtable.c115 static int insert_retry(struct rhashtable *ht, struct test_obj *obj, in insert_retry() argument
123 err = rhashtable_insert_fast(ht, &obj->node, params); in insert_retry()
137 static int __init test_rht_lookup(struct rhashtable *ht, struct test_obj *array, in test_rht_lookup() argument
152 obj = rhashtable_lookup_fast(ht, &key, test_rht_params); in test_rht_lookup()
175 static void test_bucket_stats(struct rhashtable *ht, unsigned int entries) in test_bucket_stats() argument
181 rhashtable_walk_enter(ht, &hti); in test_bucket_stats()
202 total, atomic_read(&ht->nelems), entries, chain_len); in test_bucket_stats()
204 if (total != atomic_read(&ht->nelems) || total != entries) in test_bucket_stats()
208 static s64 __init test_rhashtable(struct rhashtable *ht, struct test_obj *array, in test_rhashtable() argument
226 err = insert_retry(ht, obj, test_rht_params); in test_rhashtable()
[all …]
/linux-6.6.21/include/linux/ !
Drhashtable.h113 static inline void *rht_obj(const struct rhashtable *ht, in rht_obj() argument
116 return (char *)he - ht->p.head_offset; in rht_obj()
125 static inline unsigned int rht_key_get_hash(struct rhashtable *ht, in rht_key_get_hash() argument
133 hash = ht->p.hashfn(key, ht->key_len, hash_rnd); in rht_key_get_hash()
144 unsigned int key_len = ht->p.key_len; in rht_key_get_hash()
156 struct rhashtable *ht, const struct bucket_table *tbl, in rht_key_hashfn() argument
159 unsigned int hash = rht_key_get_hash(ht, key, params, tbl->hash_rnd); in rht_key_hashfn()
165 struct rhashtable *ht, const struct bucket_table *tbl, in rht_head_hashfn() argument
168 const char *ptr = rht_obj(ht, he); in rht_head_hashfn()
172 ht->p.key_len, in rht_head_hashfn()
[all …]
Drhashtable-types.h34 struct rhashtable *ht; member
98 struct rhashtable ht; member
121 struct rhashtable *ht; member
130 int rhashtable_init(struct rhashtable *ht,
Dhashtable.h34 static inline void __hash_init(struct hlist_head *ht, unsigned int sz) in __hash_init() argument
39 INIT_HLIST_HEAD(&ht[i]); in __hash_init()
81 static inline bool __hash_empty(struct hlist_head *ht, unsigned int sz) in __hash_empty() argument
86 if (!hlist_empty(&ht[i])) in __hash_empty()
/linux-6.6.21/drivers/gpu/drm/ !
Ddrm_hashtab.c45 int drm_ht_create(struct drm_open_hash *ht, unsigned int order) in drm_ht_create() argument
49 ht->order = order; in drm_ht_create()
50 ht->table = NULL; in drm_ht_create()
51 if (size <= PAGE_SIZE / sizeof(*ht->table)) in drm_ht_create()
52 ht->table = kcalloc(size, sizeof(*ht->table), GFP_KERNEL); in drm_ht_create()
54 ht->table = vzalloc(array_size(size, sizeof(*ht->table))); in drm_ht_create()
55 if (!ht->table) { in drm_ht_create()
62 void drm_ht_verbose_list(struct drm_open_hash *ht, unsigned long key) in drm_ht_verbose_list() argument
69 hashed_key = hash_long(key, ht->order); in drm_ht_verbose_list()
71 h_list = &ht->table[hashed_key]; in drm_ht_verbose_list()
[all …]
Ddrm_legacy.h52 int drm_ht_create(struct drm_open_hash *ht, unsigned int order);
53 int drm_ht_insert_item(struct drm_open_hash *ht, struct drm_hash_item *item);
54 int drm_ht_just_insert_please(struct drm_open_hash *ht, struct drm_hash_item *item,
57 int drm_ht_find_item(struct drm_open_hash *ht, unsigned long key, struct drm_hash_item **item);
59 void drm_ht_verbose_list(struct drm_open_hash *ht, unsigned long key);
60 int drm_ht_remove_key(struct drm_open_hash *ht, unsigned long key);
61 int drm_ht_remove_item(struct drm_open_hash *ht, struct drm_hash_item *item);
62 void drm_ht_remove(struct drm_open_hash *ht);
/linux-6.6.21/kernel/ !
Dsmpboot.c87 struct smp_hotplug_thread *ht; member
109 struct smp_hotplug_thread *ht = td->ht; in smpboot_thread_fn() local
118 if (ht->cleanup && td->status != HP_THREAD_NONE) in smpboot_thread_fn()
119 ht->cleanup(td->cpu, cpu_online(td->cpu)); in smpboot_thread_fn()
127 if (ht->park && td->status == HP_THREAD_ACTIVE) { in smpboot_thread_fn()
129 ht->park(td->cpu); in smpboot_thread_fn()
144 if (ht->setup) in smpboot_thread_fn()
145 ht->setup(td->cpu); in smpboot_thread_fn()
152 if (ht->unpark) in smpboot_thread_fn()
153 ht->unpark(td->cpu); in smpboot_thread_fn()
[all …]
/linux-6.6.21/net/sched/ !
Dcls_u32.c83 struct tc_u_knode __rcu *ht[]; member
113 struct tc_u_hnode *ht = rcu_dereference_bh(tp->root); in u32_classify() local
125 n = rcu_dereference_bh(ht->ht[sel]); in u32_classify()
170 ht = rcu_dereference_bh(n->ht_down); in u32_classify()
171 if (!ht) { in u32_classify()
202 ht = rcu_dereference_bh(n->ht_down); in u32_classify()
204 if (ht->divisor) { in u32_classify()
211 sel = ht->divisor & u32_hash_fold(*data, &n->sel, in u32_classify()
244 ht = rcu_dereference_bh(n->ht_up); in u32_classify()
258 struct tc_u_hnode *ht; in u32_lookup_ht() local
[all …]
Dcls_fw.c30 struct fw_filter __rcu *ht[HTSIZE]; member
63 for (f = rcu_dereference_bh(head->ht[fw_hash(id)]); f; in fw_classify()
99 f = rtnl_dereference(head->ht[fw_hash(handle)]); in fw_get()
143 while ((f = rtnl_dereference(head->ht[h])) != NULL) { in fw_destroy()
144 RCU_INIT_POINTER(head->ht[h], in fw_destroy()
169 fp = &head->ht[fw_hash(f->id)]; in fw_delete()
185 if (rcu_access_pointer(head->ht[h])) { in fw_delete()
287 fp = &head->ht[fw_hash(fnew->id)]; in fw_change()
333 RCU_INIT_POINTER(f->next, head->ht[fw_hash(handle)]); in fw_change()
334 rcu_assign_pointer(head->ht[fw_hash(handle)], f); in fw_change()
[all …]
Dcls_route.c43 struct route4_filter __rcu *ht[16 + 16 + 1]; member
166 for (f = rcu_dereference_bh(b->ht[route4_hash_from(id)]); in route4_classify()
172 for (f = rcu_dereference_bh(b->ht[route4_hash_iif(iif)]); in route4_classify()
178 for (f = rcu_dereference_bh(b->ht[route4_hash_wild()]); in route4_classify()
234 for (f = rtnl_dereference(b->ht[h2]); in route4_get()
294 while ((f = rtnl_dereference(b->ht[h2])) != NULL) { in route4_destroy()
298 RCU_INIT_POINTER(b->ht[h2], next); in route4_destroy()
330 fp = &b->ht[from_hash(h >> 16)]; in route4_delete()
352 rt = rtnl_dereference(b->ht[i]); in route4_delete()
445 for (fp = rtnl_dereference(b->ht[h2]); in route4_set_parms()
[all …]
Dsch_sfq.c126 sfq_index *ht; /* Hash table ('divisor' slots) */ member
321 q->ht[slot->hash] = SFQ_EMPTY_SLOT; in sfq_drop()
365 x = q->ht[hash]; in sfq_enqueue()
371 q->ht[hash] = x; in sfq_enqueue()
507 q->ht[slot->hash] = SFQ_EMPTY_SLOT; in sfq_dequeue()
558 q->ht[slot->hash] = SFQ_EMPTY_SLOT; in sfq_rehash()
564 sfq_index x = q->ht[hash]; in sfq_rehash()
577 q->ht[hash] = x; in sfq_rehash()
729 sfq_free(q->ht); in sfq_destroy()
770 q->ht = sfq_alloc(sizeof(q->ht[0]) * q->divisor); in sfq_init()
[all …]
/linux-6.6.21/drivers/net/ethernet/mellanox/mlx5/core/en/tc/ !
Dact_stats.c11 struct rhashtable ht; member
43 err = rhashtable_init(&handle->ht, &act_counters_ht_params); in mlx5e_tc_act_stats_create()
56 rhashtable_destroy(&handle->ht); in mlx5e_tc_act_stats_free()
66 struct rhashtable *ht = &handle->ht; in mlx5e_tc_act_stats_add() local
82 old_act_stats = rhashtable_lookup_get_insert_fast(ht, in mlx5e_tc_act_stats_add()
115 struct rhashtable *ht = &handle->ht; in mlx5e_tc_act_stats_del_flow() local
118 act_stats = rhashtable_lookup_fast(ht, in mlx5e_tc_act_stats_del_flow()
122 rhashtable_remove_fast(ht, &act_stats->hash, in mlx5e_tc_act_stats_del_flow()
170 struct rhashtable *ht = &handle->ht; in mlx5e_tc_act_stats_fill_stats() local
176 item = rhashtable_lookup(ht, &fl_act->cookie, act_counters_ht_params); in mlx5e_tc_act_stats_fill_stats()
/linux-6.6.21/drivers/net/wireless/mediatek/mt76/ !
Dmt76x02_phy.c104 mt76x02_tx_power_mask(t->ofdm[4], t->ofdm[6], t->ht[0], in mt76x02_phy_set_txpower()
105 t->ht[2])); in mt76x02_phy_set_txpower()
107 mt76x02_tx_power_mask(t->ht[4], t->ht[6], t->ht[8], in mt76x02_phy_set_txpower()
108 t->ht[10])); in mt76x02_phy_set_txpower()
110 mt76x02_tx_power_mask(t->ht[12], t->ht[14], t->ht[0], in mt76x02_phy_set_txpower()
111 t->ht[2])); in mt76x02_phy_set_txpower()
113 mt76x02_tx_power_mask(t->ht[4], t->ht[6], 0, 0)); in mt76x02_phy_set_txpower()
115 mt76x02_tx_power_mask(t->ofdm[7], t->vht[0], t->ht[7], in mt76x02_phy_set_txpower()
118 mt76x02_tx_power_mask(t->ht[14], 0, t->vht[0], t->vht[1])); in mt76x02_phy_set_txpower()
120 mt76x02_tx_power_mask(t->ht[7], 0, t->vht[0], t->vht[1])); in mt76x02_phy_set_txpower()
/linux-6.6.21/net/netfilter/ !
Dxt_hashlimit.c184 hash_dst(const struct xt_hashlimit_htable *ht, const struct dsthash_dst *dst) in hash_dst() argument
188 ht->rnd); in hash_dst()
195 return reciprocal_scale(hash, ht->cfg.size); in hash_dst()
199 dsthash_find(const struct xt_hashlimit_htable *ht, in dsthash_find() argument
203 u_int32_t hash = hash_dst(ht, dst); in dsthash_find()
205 if (!hlist_empty(&ht->hash[hash])) { in dsthash_find()
206 hlist_for_each_entry_rcu(ent, &ht->hash[hash], node) in dsthash_find()
217 dsthash_alloc_init(struct xt_hashlimit_htable *ht, in dsthash_alloc_init() argument
222 spin_lock(&ht->lock); in dsthash_alloc_init()
227 ent = dsthash_find(ht, dst); in dsthash_alloc_init()
[all …]
Dnft_set_hash.c25 struct rhashtable ht; member
91 he = rhashtable_lookup(&priv->ht, &arg, nft_rhash_params); in nft_rhash_lookup()
109 he = rhashtable_lookup(&priv->ht, &arg, nft_rhash_params); in nft_rhash_get()
132 he = rhashtable_lookup(&priv->ht, &arg, nft_rhash_params); in nft_rhash_update()
140 prev = rhashtable_lookup_get_insert_key(&priv->ht, &arg, &he->node, in nft_rhash_update()
176 prev = rhashtable_lookup_get_insert_key(&priv->ht, &arg, &he->node, in nft_rhash_insert()
218 he = rhashtable_lookup(&priv->ht, &arg, nft_rhash_params); in nft_rhash_deactivate()
234 rhashtable_remove_fast(&priv->ht, &he->node, nft_rhash_params); in nft_rhash_remove()
248 he = rhashtable_lookup(&priv->ht, &arg, nft_rhash_params); in nft_rhash_delete()
265 rhashtable_walk_enter(&priv->ht, &hti); in nft_rhash_walk()
[all …]
/linux-6.6.21/drivers/net/wireless/mediatek/mt76/mt76x2/ !
Deeprom.c321 t->ht[0] = t->ht[1] = mt76x02_rate_power_val(val); in mt76x2_get_rate_power()
322 t->ht[2] = t->ht[3] = mt76x02_rate_power_val(val >> 8); in mt76x2_get_rate_power()
325 t->ht[4] = t->ht[5] = mt76x02_rate_power_val(val); in mt76x2_get_rate_power()
326 t->ht[6] = t->ht[7] = mt76x02_rate_power_val(val >> 8); in mt76x2_get_rate_power()
329 t->ht[8] = t->ht[9] = mt76x02_rate_power_val(val); in mt76x2_get_rate_power()
330 t->ht[10] = t->ht[11] = mt76x02_rate_power_val(val >> 8); in mt76x2_get_rate_power()
333 t->ht[12] = t->ht[13] = mt76x02_rate_power_val(val); in mt76x2_get_rate_power()
334 t->ht[14] = t->ht[15] = mt76x02_rate_power_val(val >> 8); in mt76x2_get_rate_power()
/linux-6.6.21/drivers/net/ethernet/mellanox/mlx5/core/ipoib/ !
Dipoib_vlan.c88 struct mlx5i_pkey_qpn_ht *ht = ipriv->qpn_htbl; in mlx5i_pkey_add_qpn() local
98 spin_lock_bh(&ht->ht_lock); in mlx5i_pkey_add_qpn()
99 hlist_add_head(&new_node->hlist, &ht->buckets[key]); in mlx5i_pkey_add_qpn()
100 spin_unlock_bh(&ht->ht_lock); in mlx5i_pkey_add_qpn()
109 struct mlx5i_pkey_qpn_ht *ht = ipriv->qpn_htbl; in mlx5i_pkey_del_qpn() local
112 node = mlx5i_find_qpn_to_netdev_node(ht->buckets, qpn); in mlx5i_pkey_del_qpn()
118 spin_lock_bh(&ht->ht_lock); in mlx5i_pkey_del_qpn()
120 spin_unlock_bh(&ht->ht_lock); in mlx5i_pkey_del_qpn()
/linux-6.6.21/tools/include/linux/ !
Dhashtable.h31 static inline void __hash_init(struct hlist_head *ht, unsigned int sz) in __hash_init() argument
36 INIT_HLIST_HEAD(&ht[i]); in __hash_init()
69 static inline bool __hash_empty(struct hlist_head *ht, unsigned int sz) in __hash_empty() argument
74 if (!hlist_empty(&ht[i])) in __hash_empty()
/linux-6.6.21/net/hsr/ !
Dhsr_main.h61 static inline void set_hsr_tag_path(struct hsr_tag *ht, u16 path) in set_hsr_tag_path() argument
63 ht->path_and_LSDU_size = in set_hsr_tag_path()
64 htons((ntohs(ht->path_and_LSDU_size) & 0x0FFF) | (path << 12)); in set_hsr_tag_path()
67 static inline void set_hsr_tag_LSDU_size(struct hsr_tag *ht, u16 LSDU_size) in set_hsr_tag_LSDU_size() argument
69 ht->path_and_LSDU_size = htons((ntohs(ht->path_and_LSDU_size) & in set_hsr_tag_LSDU_size()
/linux-6.6.21/drivers/md/ !
Ddm-cache-policy-smq.c585 static int h_init(struct smq_hash_table *ht, struct entry_space *es, unsigned int nr_entries) in h_init() argument
589 ht->es = es; in h_init()
591 ht->hash_bits = __ffs(nr_buckets); in h_init()
593 ht->buckets = vmalloc(array_size(nr_buckets, sizeof(*ht->buckets))); in h_init()
594 if (!ht->buckets) in h_init()
598 ht->buckets[i] = INDEXER_NULL; in h_init()
603 static void h_exit(struct smq_hash_table *ht) in h_exit() argument
605 vfree(ht->buckets); in h_exit()
608 static struct entry *h_head(struct smq_hash_table *ht, unsigned int bucket) in h_head() argument
610 return to_entry(ht->es, ht->buckets[bucket]); in h_head()
[all …]
/linux-6.6.21/drivers/net/wireless/mediatek/mt76/mt76x0/ !
Deeprom.c182 t->ht[0] = t->ht[1] = s6_to_s8(val); in mt76x0_get_tx_power_per_rate()
183 t->ht[2] = t->ht[3] = s6_to_s8(val >> 8); in mt76x0_get_tx_power_per_rate()
188 t->ht[4] = t->ht[5] = s6_to_s8(val); in mt76x0_get_tx_power_per_rate()
189 t->ht[6] = t->ht[7] = s6_to_s8(val >> 8); in mt76x0_get_tx_power_per_rate()
/linux-6.6.21/arch/mips/kernel/ !
Dkgdb.c212 struct hard_trap_info *ht; in compute_signal() local
214 for (ht = hard_trap_info; ht->tt && ht->signo; ht++) in compute_signal()
215 if (ht->tt == tt) in compute_signal()
216 return ht->signo; in compute_signal()
/linux-6.6.21/drivers/net/wireless/intel/iwlwifi/dvm/ !
Drxon.c166 if (ctx->ht.enabled) in iwlagn_update_qos()
603 if (!ctx->ht.enabled) { in _iwl_set_rxon_ht()
614 rxon->flags |= cpu_to_le32(ctx->ht.protection << in _iwl_set_rxon_ht()
624 if (ctx->ht.protection == in _iwl_set_rxon_ht()
631 switch (ctx->ht.extension_chan_offset) { in _iwl_set_rxon_ht()
646 switch (ctx->ht.extension_chan_offset) { in _iwl_set_rxon_ht()
675 le32_to_cpu(rxon->flags), ctx->ht.protection, in _iwl_set_rxon_ht()
676 ctx->ht.extension_chan_offset); in _iwl_set_rxon_ht()
1138 ctx->ht.extension_chan_offset = in iwlagn_config_ht40()
1140 ctx->ht.is_40mhz = true; in iwlagn_config_ht40()
[all …]
/linux-6.6.21/arch/powerpc/kernel/ !
Dkgdb.c94 struct hard_trap_info *ht; in computeSignal() local
96 for (ht = hard_trap_info; ht->tt && ht->signo; ht++) in computeSignal()
97 if (ht->tt == tt) in computeSignal()
98 return ht->signo; in computeSignal()

123456