Searched defs:hash (Results 76 - 98 of 98) sorted by relevance

1234

/net/batman-adv/
H A Dtranslation-table.c23 #include "hash.h"
31 /* hash class keys */
57 * batadv_choose_tt - return the index of the tt entry in the hash table
59 * @size: the size of the hash table
61 * Returns the hash index where the object represented by 'data' should be
67 uint32_t hash = 0; local
70 hash = batadv_hash_bytes(hash, &tt->addr, ETH_ALEN);
71 hash = batadv_hash_bytes(hash,
90 batadv_tt_hash_find(struct batadv_hashtable *hash, const uint8_t *addr, unsigned short vid) argument
905 struct batadv_hashtable *hash = bat_priv->tt.local_hash; local
1104 struct batadv_hashtable *hash = bat_priv->tt.local_hash; local
1121 struct batadv_hashtable *hash; local
1576 struct batadv_hashtable *hash = bat_priv->tt.global_hash; local
1808 struct batadv_hashtable *hash = bat_priv->tt.global_hash; local
1874 struct batadv_hashtable *hash = bat_priv->tt.global_hash; local
1913 struct batadv_hashtable *hash; local
2053 struct batadv_hashtable *hash = bat_priv->tt.global_hash; local
2129 struct batadv_hashtable *hash = bat_priv->tt.local_hash; local
2297 batadv_tt_tvlv_generate(struct batadv_priv *bat_priv, struct batadv_hashtable *hash, void *tvlv_buff, uint16_t tt_len, int (*valid_cb)(const void *, const void *), void *cb_data) argument
3119 struct batadv_hashtable *hash = bat_priv->tt.local_hash; local
3158 struct batadv_hashtable *hash = bat_priv->tt.local_hash; local
[all...]
H A Dtypes.h205 * @batadv_dat_addr_t: address of the orig node in the distributed hash
497 * @local_hash: local translation table hash table
498 * @global_hash: global translation table hash table
539 * @claim_hash: hash table containing mesh nodes this host has claimed
540 * @backbone_hash: hash table containing all detected backbone gateways
615 * @hash: hashtable representing the local ARP cache
621 struct batadv_hashtable *hash; member in struct:batadv_priv_dat
741 * @orig_hash: hash table containing mesh participants (orig nodes)
1166 * @hash_entry: hlist node for batadv_priv_dat::hash
/net/bridge/
H A Dbr_private.h223 struct hlist_head hash[BR_HASH_SIZE]; member in struct:net_bridge
/net/ceph/
H A Dosd_client.c1621 s64 hash = ceph_decode_64(p); local
1622 if (hash != -1) {
1623 pr_warn("ceph_object_locator::hash is set\n");
/net/core/
H A Dneighbour.c65 Neighbour hash table buckets are protected with rwlock tbl->lock.
67 - All the scans/updates to hash buckets MUST be made under this lock.
364 unsigned int i, hash; local
382 hash = tbl->hash(n->primary_key, n->dev,
385 hash >>= (32 - new_nht->hash_shift);
391 new_nht->hash_buckets[hash],
393 rcu_assign_pointer(new_nht->hash_buckets[hash], n);
414 hash_val = tbl->hash(pkey, dev, nht->hash_rnd) >> (32 - nht->hash_shift);
444 hash_val = tbl->hash(pke
[all...]
H A Ddev.c81 #include <linux/hash.h>
139 /* Instead of increasing this, you should create a hash table. */
193 unsigned int hash = full_name_hash(name, strnlen(name, IFNAMSIZ)); local
195 return &net->dev_name_head[hash_32(hash, NETDEV_HASHBITS)];
359 * MUST BE last in hash buckets and checking protocol handlers
3095 u32 hash; local
3124 hash = skb_get_hash(skb);
3125 if (!hash)
3134 rflow = &flow_table->flows[hash & flow_table->mask];
3137 next_cpu = sock_flow_table->ents[hash
3924 u32 hash = skb_get_hash_raw(skb); local
4423 unsigned int hash = napi_id % HASH_SIZE(napi_hash); local
7038 struct hlist_head *hash; local
[all...]
/net/decnet/
H A Daf_decnet.c253 unsigned int hash = addr->sdn_objnum; local
255 if (hash == 0) {
256 hash = addr->sdn_objnamel;
258 hash ^= addr->sdn_objname[i];
259 hash ^= (hash << 3);
263 return &dn_sk_hash[hash & DN_SK_HASH_MASK];
1129 * the newly created socket on the wrong hash queue.
H A Ddn_route.c24 * Steve Whitehouse : Dave Miller's dynamic hash table sizing and
333 static int dn_insert_route(struct dn_route *rt, unsigned int hash, struct dn_route **rp) argument
339 rthp = &dn_rt_hash_table[hash].chain;
341 spin_lock_bh(&dn_rt_hash_table[hash].lock);
343 lockdep_is_held(&dn_rt_hash_table[hash].lock))) != NULL) {
348 dn_rt_hash_table[hash].chain);
349 rcu_assign_pointer(dn_rt_hash_table[hash].chain, rth);
352 spin_unlock_bh(&dn_rt_hash_table[hash].lock);
361 rcu_assign_pointer(rt->dst.dn_next, dn_rt_hash_table[hash].chain);
362 rcu_assign_pointer(dn_rt_hash_table[hash]
982 unsigned int hash; local
1257 unsigned int hash = dn_hash(flp->saddr, flp->daddr); local
1321 unsigned int hash; local
1532 unsigned int hash = dn_hash(cb->src, cb->dst); local
[all...]
/net/ipv4/
H A Dcipso_ipv4.c59 * probably be turned into a hash table or something similar so we
76 u32 hash; member in struct:cipso_v4_map_cache_entry
224 * @key: the hash key
228 * The CIPSO tag hashing function. Returns a 32-bit hash value.
323 u32 hash; local
328 hash = cipso_v4_map_cache_hash(key, key_len);
329 bkt = hash & (CIPSO_V4_CACHE_BUCKETS - 1);
332 if (entry->hash == hash &&
404 entry->hash
[all...]
H A Ddevinet.c53 #include <linux/hash.h>
120 u32 hash = inet_addr_hash(net, ifa->ifa_local); local
123 hlist_add_head_rcu(&ifa->hash, &inet_addr_lst[hash]);
129 hlist_del_init_rcu(&ifa->hash);
142 u32 hash = inet_addr_hash(net, addr); local
147 hlist_for_each_entry_rcu(ifa, &inet_addr_lst[hash], hash) {
613 hlist_for_each_entry_rcu(ifa, &inet_addr_lst[i], hash) {
648 hlist_for_each_entry_safe(ifa, n, &inet_addr_lst[i], hash) {
[all...]
H A Digmp.c1245 u32 hash; local
1249 hash = ip_mc_hash(im);
1250 im->next_hash = mc_hash[hash];
1251 rcu_assign_pointer(mc_hash[hash], im);
1255 /* do not use a hash table for small number of items */
1265 hash = ip_mc_hash(im);
1266 im->next_hash = mc_hash[hash];
1267 RCU_INIT_POINTER(mc_hash[hash], im);
2400 u32 hash = hash_32((__force u32)mc_addr, MC_HASH_SZ_LOG); local
2402 for (im = rcu_dereference(mc_hash[hash]);
[all...]
H A Droute.c57 * Ilia Sotnikov : Removed TOS from hash calculations
472 u32 ip_idents_reserve(u32 hash, int segs) argument
474 struct ip_ident_bucket *bucket = ip_idents + hash % IP_IDENTS_SZ;
489 u32 hash, id; local
493 hash = jhash_3words((__force u32)iph->daddr,
497 id = ip_idents_reserve(hash, segs);
585 static struct fib_nh_exception *fnhe_oldest(struct fnhe_hash_bucket *hash) argument
589 oldest = rcu_dereference(hash->chain);
624 struct fnhe_hash_bucket *hash; local
633 hash
1247 struct fnhe_hash_bucket *hash = rcu_dereference(nh->nh_exceptions); local
[all...]
H A Dtcp.c1959 * socket sitting in hash tables.
2898 struct crypto_hash *hash; local
2900 hash = crypto_alloc_hash("md5", 0, CRYPTO_ALG_ASYNC);
2901 if (IS_ERR_OR_NULL(hash))
2903 per_cpu(tcp_md5sig_pool, cpu).md5_desc.tfm = hash;
2960 /* options aren't included in the hash */
3080 * hash tables.
H A Dudp.c167 * Note: we still hold spinlock of primary hash chain, so no other writer
205 * @hash2_nulladdr: AF-dependent hash value in secondary hash chains,
243 * Iterate on all possible values of snum for this hash.
334 /* precompute partial secondary hash */
433 u32 hash = 0; local
446 hash = udp_ehashfn(net, daddr, hnum,
452 if (reciprocal_scale(hash, matches) == 0)
454 hash = next_pseudo_random32(hash);
489 u32 hash = 0; local
[all...]
/net/sunrpc/auth_gss/
H A Dauth_gss.c91 struct hlist_node hash; member in struct:gss_auth
995 INIT_HLIST_NODE(&gss_auth->hash);
1100 if (hash_hashed(&gss_auth->hash)) {
1102 hash_del(&gss_auth->hash);
1135 hash,
1154 hash_add(gss_auth_hash_table, &new->hash, hashval);
H A Dsvcauth_gss.c283 int hash = rsi_hash(item); local
285 ch = sunrpc_cache_lookup(cd, &item->h, hash);
295 int hash = rsi_hash(new); local
298 &old->h, hash);
540 int hash = rsc_hash(item); local
542 ch = sunrpc_cache_lookup(cd, &item->h, hash);
552 int hash = rsc_hash(new); local
555 &old->h, hash);
/net/sunrpc/
H A Dcache.c54 struct cache_head *key, int hash)
59 head = &detail->hash_table[hash];
139 struct cache_head *new, struct cache_head *old, int hash)
170 head = &detail->hash_table[hash];
507 * All deferred requests are stored in a hash table,
529 hlist_del_init(&dreq->hash);
538 int hash = DFR_HASH(item); local
541 hlist_add_head(&dreq->hash, &cache_defer_hash[hash]);
593 if (!hlist_unhashed(&sleeper.handle.hash)) {
53 sunrpc_cache_lookup(struct cache_detail *detail, struct cache_head *key, int hash) argument
138 sunrpc_cache_update(struct cache_detail *detail, struct cache_head *new, struct cache_head *old, int hash) argument
664 int hash = DFR_HASH(item); local
1293 unsigned int hash, entry; variable
1322 int hash = (*pos >> 32); local
[all...]
/net/unix/
H A Daf_unix.c130 unsigned long hash = (unsigned long)addr; local
132 hash ^= hash >> 16;
133 hash ^= hash >> 8;
134 hash %= UNIX_HASH_SIZE;
135 return &unix_socket_table[UNIX_HASH_SIZE + hash];
138 #define UNIX_ABSTRACT(sk) (unix_sk(sk)->addr->hash < UNIX_HASH_SIZE)
160 * hash table is protected with spinlock unix_table_lock
166 unsigned int hash local
263 __unix_find_socket_byname(struct net *net, struct sockaddr_un *sunname, int len, int type, unsigned int hash) argument
284 unix_find_socket_byname(struct net *net, struct sockaddr_un *sunname, int len, int type, unsigned int hash) argument
773 unix_find_other(struct net *net, struct sockaddr_un *sunname, int len, int type, unsigned int hash, int *error) argument
865 unsigned int hash; local
974 unsigned int hash; local
1072 unsigned int hash; local
1456 unsigned int hash; local
[all...]
/net/netfilter/ipvs/
H A Dip_vs_ctl.c263 * Returns hash value for virtual service
286 * Returns hash value of fwmark for virtual service lookup
300 unsigned int hash; local
312 hash = ip_vs_svc_hashkey(svc->net, svc->af, svc->protocol,
314 hlist_add_head_rcu(&svc->s_list, &ip_vs_svc_table[hash]);
319 hash = ip_vs_svc_fwm_hashkey(svc->net, svc->fwmark);
320 hlist_add_head_rcu(&svc->f_list, &ip_vs_svc_fwm_table[hash]);
363 unsigned int hash; local
367 hash = ip_vs_svc_hashkey(net, af, protocol, vaddr, vport);
369 hlist_for_each_entry_rcu(svc, &ip_vs_svc_table[hash], s_lis
390 unsigned int hash; local
519 unsigned int hash; local
551 unsigned int hash; local
[all...]
/net/netlink/
H A Daf_netlink.c63 #include <linux/hash.h>
113 /* Protects netlink socket hash table mutations */
1026 u32 hash; local
1028 hash = rhashtable_hashfn(&table->hash, &portid, sizeof(portid));
1030 return rhashtable_lookup_compare(&table->hash, hash,
1090 if (BITS_PER_LONG > 32 && unlikely(table->hash.nelems >= UINT_MAX))
1095 rhashtable_insert(&table->hash, &nlk_sk(sk)->node, GFP_KERNEL);
1108 if (rhashtable_remove(&table->hash,
[all...]
/net/xfrm/
H A Dxfrm_policy.c352 /* calculate policy hash thresholds */
379 unsigned int hash; local
384 hash = __sel_hash(sel, family, hmask, dbits, sbits);
386 return (hash == hmask + 1 ?
388 net->xfrm.policy_bydst[dir].table + hash);
397 unsigned int hash; local
402 hash = __addr_hash(daddr, saddr, family, hmask, dbits, sbits);
404 return net->xfrm.policy_bydst[dir].table + hash;
/net/bluetooth/
H A Dhci_core.c3478 u8 *hash, u8 *randomizer)
3492 memcpy(data->hash192, hash, sizeof(data->hash192));
3477 hci_add_remote_oob_data(struct hci_dev *hdev, bdaddr_t *bdaddr, u8 *hash, u8 *randomizer) argument
/net/ipv6/
H A Daddrconf.c66 #include <linux/hash.h>
132 * Configured unicast address hash table
813 unsigned int hash; local
882 /* Add to big hash table */
883 hash = inet6_addr_hash(addr);
885 hlist_add_head_rcu(&ifa->addr_lst, &inet6_addr_lst[hash]);
1561 unsigned int hash = inet6_addr_hash(addr); local
1565 hlist_for_each_entry_rcu(ifp, &inet6_addr_lst[hash], addr_lst) {
1591 unsigned int hash = inet6_addr_hash(addr); local
1594 hlist_for_each_entry(ifp, &inet6_addr_lst[hash], addr_ls
1660 unsigned int hash = inet6_addr_hash(addr); local
3673 unsigned int hash = inet6_addr_hash(addr); local
[all...]

Completed in 311 milliseconds

1234