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

1234

/net/openvswitch/
H A Dflow_table.c28 #include <linux/hash.h>
287 static struct hlist_head *find_bucket(struct table_instance *ti, u32 hash) argument
289 hash = jhash_1word(hash, ti->hash_seed);
291 (hash & (ti->n_buckets - 1)));
298 head = find_bucket(ti, flow->hash);
363 /* Make sure number of hash bytes are multiple of u32. */
418 u32 hash; local
422 hash = flow_hash(&masked_key, key_start, key_end);
423 head = find_bucket(ti, hash);
[all...]
/net/sched/
H A Dsch_fq_codel.c33 * This is a Stochastic model (as we use a hash, several flows
59 u32 perturbation; /* hash perturbation */
74 unsigned int hash; local
77 hash = jhash_3words((__force u32)keys.dst,
81 return reciprocal_scale(hash, q->flows_cnt);
H A Dsch_hhf.c33 * Conceptually, a multi-stage filter comprises k independent hash functions
34 * and k counter arrays. Packets are indexed into k counter arrays by k hash
39 * due to hash collision with other small flows; however, with high
77 * - T is a fixed-size hash-table with 1024 entries. Hash collision is
83 * Hence, instead of having four hash functions, we chop the 32-bit
84 * skb-hash into three 10-bit chunks, and the remaining 10-bit chunk is
114 u32 hash_id; /* hash of flow-id (e.g. TCP 5-tuple) */
116 struct list_head flowchain; /* chaining under hash collision */
129 u32 perturbation; /* hash perturbation */
183 unsigned int hash; local
196 seek_list(const u32 hash, struct list_head *head, struct hhf_sched_data *q) argument
266 u32 tmp_hash, hash; local
[all...]
H A Dsch_sfb.c34 * This permits us to split one 32bit hash (provided per packet by rxhash or
48 /* We use a double buffering right before hash change
49 * (Section 4.4 of SFB reference : moving hash functions)
88 * We store in skb_cb the two hash values.
102 * If using 'internal' SFB flow classifier, hash comes from skb rxhash
103 * If using external classifier, hash comes from the classid.
132 u32 hash = sfbhash & SFB_BUCKET_MASK; local
135 if (b[hash].qlen < 0xFFFF)
136 b[hash].qlen++;
161 u32 hash local
333 u32 hash = sfbhash & SFB_BUCKET_MASK; local
368 u32 hash = sfbhash & SFB_BUCKET_MASK; local
[all...]
H A Dsch_sfq.c57 When hash collisions occur, several flows are considered as one.
74 - number of hash buckets to 65536.
110 unsigned short hash; /* hash value (index in ht[]) */ member in struct:sfq_slot
120 unsigned int divisor; /* number of slots in hash table */
177 unsigned int hash; local
179 hash = jhash_3words((__force u32)keys->dst,
182 return hash & (q->divisor - 1);
344 q->ht[slot->hash] = SFQ_EMPTY_SLOT;
372 unsigned int hash; local
582 unsigned int hash = sfq_hash(q, skb); local
[all...]
/net/sctp/
H A Dinput.c708 /* Insert endpoint into the hash table. */
725 /* Add an endpoint to the hash. Local BH-safe. */
733 /* Remove endpoint from the hash table. */
751 /* Remove endpoint from the hash. Local BH-safe. */
766 int hash; local
768 hash = sctp_ep_hashfn(net, ntohs(laddr->v4.sin_port));
769 head = &sctp_ep_hashtable[hash];
785 /* Insert association into the hash table. */
805 /* Add an association to the hash. Local BH-safe. */
816 /* Remove association from the hash tabl
857 int hash; local
[all...]
/net/tipc/
H A Dname_table.c86 * @ns_list: links to adjacent name sequences in hash chain
114 static int hash(int x) function
472 seq_head = &table.types[hash(type)];
494 seq = tipc_nameseq_create(type, &table.types[hash(type)]);
727 seq = tipc_nameseq_create(type, &table.types[hash(type)]);
894 i = hash(type);
/net/batman-adv/
H A Dbridge_loop_avoidance.c19 #include "hash.h"
43 uint32_t hash = 0; local
45 hash = batadv_hash_bytes(hash, &claim->addr, sizeof(claim->addr));
46 hash = batadv_hash_bytes(hash, &claim->vid, sizeof(claim->vid));
48 hash += (hash << 3);
49 hash ^= (hash >> 1
60 uint32_t hash = 0; local
145 struct batadv_hashtable *hash = bat_priv->bla.claim_hash; local
185 struct batadv_hashtable *hash = bat_priv->bla.backbone_hash; local
221 struct batadv_hashtable *hash; local
467 struct batadv_hashtable *hash; local
996 struct batadv_hashtable *hash; local
1050 struct batadv_hashtable *hash; local
1098 struct batadv_hashtable *hash; local
1152 struct batadv_hashtable *hash; local
1361 struct batadv_hashtable *hash = bat_priv->bla.backbone_hash; local
1635 struct batadv_hashtable *hash = bat_priv->bla.claim_hash; local
1679 struct batadv_hashtable *hash = bat_priv->bla.backbone_hash; local
[all...]
H A Dbat_iv_ogm.c866 struct batadv_hashtable *hash = bat_priv->orig_hash; local
875 for (i = 0; i < hash->size; i++) {
876 head = &hash->table[i];
1802 struct batadv_hashtable *hash = bat_priv->orig_hash; local
1815 for (i = 0; i < hash->size; i++) {
1816 head = &hash->table[i];
H A Dnetwork-coding.c21 #include "hash.h"
114 * batadv_nc_mesh_init - initialise coding hash table and start house keeping
346 * batadv_nc_purge_orig_hash - traverse entire originator hash to check if they
352 struct batadv_hashtable *hash = bat_priv->orig_hash; local
357 if (!hash)
361 for (i = 0; i < hash->size; i++) {
362 head = &hash->table[i];
373 * batadv_nc_purge_paths - traverse all nc paths part of the hash and remove
376 * @hash: hash tabl
382 batadv_nc_purge_paths(struct batadv_priv *bat_priv, struct batadv_hashtable *hash, bool (*to_purge)(struct batadv_priv *, struct batadv_nc_path *)) argument
454 uint32_t hash = 0; local
504 batadv_nc_hash_find(struct batadv_hashtable *hash, void *data) argument
629 batadv_nc_process_nc_paths(struct batadv_priv *bat_priv, struct batadv_hashtable *hash, bool (*process_fn)(struct batadv_priv *, struct batadv_nc_path *, struct batadv_nc_packet *)) argument
915 batadv_nc_get_path(struct batadv_priv *bat_priv, struct batadv_hashtable *hash, uint8_t *src, uint8_t *dst) argument
1240 struct batadv_hashtable *hash = bat_priv->nc.coding_hash; local
1707 struct batadv_hashtable *hash = bat_priv->nc.decoding_hash; local
1852 struct batadv_hashtable *hash = bat_priv->orig_hash; local
[all...]
/net/bluetooth/
H A Dsmp.c152 u8 hash[3]; local
162 err = smp_ah(tfm, irk, &bdaddr->b[3], hash);
166 return !memcmp(bdaddr->b, hash, 3);
/net/bridge/
H A Dbr_multicast.c90 struct net_bridge_mdb_htable *mdb, struct br_ip *dst, int hash)
94 hlist_for_each_entry_rcu(mp, &mdb->mhash[hash], hlist[mdb->ver]) {
514 struct br_ip *group, int hash)
524 hlist_for_each_entry(mp, &mdb->mhash[hash], hlist[mdb->ver]) {
535 br_info(br, "Multicast hash table "
545 br_warn(br, "Multicast hash table maximum of %d "
559 br_info(br, "Multicast hash table "
569 "hash table, disabling snooping: %s, %d, %d\n",
591 int hash; local
602 hash
89 __br_mdb_ip_get( struct net_bridge_mdb_htable *mdb, struct br_ip *dst, int hash) argument
512 br_multicast_get_group( struct net_bridge *br, struct net_bridge_port *port, struct br_ip *group, int hash) argument
[all...]
/net/ipv4/
H A Dfib_semantics.c160 struct fnhe_hash_bucket *hash; local
163 hash = rcu_dereference_protected(nh->nh_exceptions, 1);
164 if (!hash)
169 fnhe = rcu_dereference_protected(hash[i].chain, 1);
183 kfree(hash);
305 unsigned int hash; local
307 hash = fib_info_hashfn(nfi);
308 head = &fib_info_hash[hash];
337 unsigned int hash; local
341 hash
701 fib_info_hash_free(struct hlist_head *hash, int bytes) argument
976 unsigned int hash; local
1100 unsigned int hash = fib_laddr_hashfn(local); local
1123 unsigned int hash = fib_devindex_hashfn(dev->ifindex); local
1234 unsigned int hash; local
[all...]
H A Dip_tunnel.c143 Tunnel hash table:
157 unsigned int hash; local
161 hash = ip_tunnel_hash(key, remote);
162 head = &itn->tunnels[hash];
194 hash = ip_tunnel_hash(key, 0);
195 head = &itn->tunnels[hash];
542 /* Get length and hash before making space in skb */
H A Dping.c57 struct hlist_nulls_head hash[PING_HTABLE_SIZE]; member in struct:ping_table
71 pr_debug("hash(%d) = %d\n", num, res);
79 return &table->hash[ping_hashfn(net, num, PING_HTABLE_MASK)];
1003 .hash = ping_hash,
1023 hslot = &ping_table.hash[state->bucket];
1220 INIT_HLIST_NULLS_HEAD(&ping_table.hash[i], i);
H A Draw.c159 static int raw_v4_input(struct sk_buff *skb, const struct iphdr *iph, int hash) argument
167 head = &raw_v4_hashinfo.ht[hash];
183 /* Not releasing hash table! */
198 int hash; local
201 hash = protocol & (RAW_HTABLE_SIZE - 1);
202 raw_sk = sk_head(&raw_v4_hashinfo.ht[hash]);
207 if (raw_sk && !raw_v4_input(skb, ip_hdr(skb), hash))
277 int hash; local
282 hash = protocol & (RAW_HTABLE_SIZE - 1);
285 raw_sk = sk_head(&raw_v4_hashinfo.ht[hash]);
[all...]
H A Dtcp_metrics.c9 #include <linux/hash.h>
27 struct net *net, unsigned int hash);
149 unsigned int hash)
161 tm = __tcp_get_metrics(saddr, daddr, net, hash);
174 oldest = rcu_dereference(net->ipv4.tcp_metrics_hash[hash].chain);
192 tm->tcpm_next = net->ipv4.tcp_metrics_hash[hash].chain;
193 rcu_assign_pointer(net->ipv4.tcp_metrics_hash[hash].chain, tm);
212 struct net *net, unsigned int hash)
217 for (tm = rcu_dereference(net->ipv4.tcp_metrics_hash[hash].chain); tm;
232 unsigned int hash; local
146 tcpm_new(struct dst_entry *dst, struct inetpeer_addr *saddr, struct inetpeer_addr *daddr, unsigned int hash) argument
210 __tcp_get_metrics(const struct inetpeer_addr *saddr, const struct inetpeer_addr *daddr, struct net *net, unsigned int hash) argument
271 unsigned int hash; local
319 unsigned int hash; local
927 __parse_nl_addr(struct genl_info *info, struct inetpeer_addr *addr, unsigned int *hash, int optional, int v4, int v6) argument
953 parse_nl_addr(struct genl_info *info, struct inetpeer_addr *addr, unsigned int *hash, int optional) argument
972 unsigned int hash; local
1058 unsigned int hash; local
[all...]
/net/ipv6/
H A Dip6_gre.c35 #include <linux/hash.h>
81 /* Tunnel hash table */
84 4 hash tables:
102 u32 hash = ipv6_addr_hash(addr); local
104 return hash_32(hash, HASH_SIZE_SHIFT);
H A Dip6_output.c543 u32 hash, id; local
547 hash = __ipv6_addr_jhash(&rt->rt6i_dst.addr, ip6_idents_hashrnd);
548 hash = __ipv6_addr_jhash(&rt->rt6i_src.addr, hash);
550 id = ip_idents_reserve(hash, 1);
H A Dip6_tunnel.c42 #include <linux/hash.h>
82 u32 hash = ipv6_addr_hash(addr1) ^ ipv6_addr_hash(addr2); local
84 return hash_32(hash, HASH_SIZE_SHIFT);
132 * Locking : hash tables are protected by RCU and RTNL
183 unsigned int hash = HASH(remote, local); local
187 for_each_ip6_tunnel_rcu(ip6n->tnls_r_l[hash]) {
227 * ip6_tnl_link - add tunnel to hash table
241 * ip6_tnl_unlink - remove tunnel from hash table
H A Draw.c164 __u8 hash; local
170 hash = nexthdr & (RAW_HTABLE_SIZE - 1);
173 sk = sk_head(&raw_v6_hashinfo.ht[hash]);
216 /* Not releasing hash table! */
362 int hash; local
366 hash = nexthdr & (RAW_HTABLE_SIZE - 1);
369 sk = sk_head(&raw_v6_hashinfo.ht[hash]);
1219 .hash = raw_hash_sk,
H A Dudp.c111 unsigned int hash, mix = net_hash_mix(net); local
114 hash = jhash_1word(0, mix);
116 hash = jhash_1word((__force u32)addr6->s6_addr32[3], mix);
118 hash = jhash2((__force u32 *)addr6->s6_addr32, 4, mix);
120 return hash ^ port;
131 /* precompute partial secondary hash */
226 u32 hash = 0; local
239 hash = udp6_ehashfn(net, daddr, hnum,
246 if (reciprocal_scale(hash, matches) == 0)
248 hash
283 u32 hash = 0; local
[all...]
/net/l2tp/
H A Dl2tp_core.c46 #include <linux/hash.h>
163 /* Session hash global list for L2TPv3.
166 * hash on the session_id, rather than a simple bitmask.
241 /* Session hash list.
244 * session_ids. So we do a real hash on the session_id, rather than a
283 int hash; local
288 for (hash = 0; hash < L2TP_HASH_SIZE; hash++) {
289 hlist_for_each_entry(session, &tunnel->session_hlist[hash], hlis
309 int hash; local
1240 int hash; local
1831 int hash; local
[all...]
/net/netfilter/
H A Dnf_conntrack_core.c78 /* return true if we need to recompute hashes (in case hash table was resized) */
133 /* The direction must be ignored, so we hash everything up to the
143 static u32 __hash_bucket(u32 hash, unsigned int size) argument
145 return reciprocal_scale(hash, size);
148 static u32 hash_bucket(u32 hash, const struct net *net) argument
150 return __hash_bucket(hash, net->ct.htable_size);
331 unsigned int hash, reply_hash; local
340 hash = hash_conntrack(net, zone,
344 } while (nf_conntrack_double_lock(net, hash, reply_hash, sequence));
347 nf_conntrack_double_unlock(hash, reply_has
409 ____nf_conntrack_find(struct net *net, u16 zone, const struct nf_conntrack_tuple *tuple, u32 hash) argument
445 __nf_conntrack_find_get(struct net *net, u16 zone, const struct nf_conntrack_tuple *tuple, u32 hash) argument
480 __nf_conntrack_hash_insert(struct nf_conn *ct, unsigned int hash, unsigned int reply_hash) argument
496 unsigned int hash, reply_hash; local
569 unsigned int hash, reply_hash; local
694 unsigned int hash = hash_conntrack(net, zone, tuple); local
729 unsigned int hash, sequence; local
793 __nf_conntrack_alloc(struct net *net, u16 zone, const struct nf_conntrack_tuple *orig, const struct nf_conntrack_tuple *repl, gfp_t gfp, u32 hash) argument
897 init_conntrack(struct net *net, struct nf_conn *tmpl, const struct nf_conntrack_tuple *tuple, struct nf_conntrack_l3proto *l3proto, struct nf_conntrack_l4proto *l4proto, struct sk_buff *skb, unsigned int dataoff, u32 hash) argument
1016 u32 hash; local
1422 nf_ct_free_hashtable(void *hash, unsigned int size) argument
1527 struct hlist_nulls_head *hash; local
1553 struct hlist_nulls_head *hash, *old_hash; local
[all...]
H A Dxt_hashlimit.c42 MODULE_DESCRIPTION("Xtables: per hash-bucket rate-limit match");
61 /* hash table crap */
105 u_int32_t rnd; /* random seed for hash */
114 struct hlist_head hash[0]; /* hashtable itself */ member in struct:xt_hashlimit_htable
129 u_int32_t hash = jhash2((const u32 *)dst, local
133 * Instead of returning hash % ht->cfg.size (implying a divide)
134 * we return the high 32 bits of the (hash * ht->cfg.size) that will
135 * give results between [0 and cfg.size-1] and same hash distribution,
138 return reciprocal_scale(hash, ht->cfg.size);
146 u_int32_t hash local
[all...]

Completed in 2373 milliseconds

1234