Lines Matching refs:hslot

143 			       const struct udp_hslot *hslot,  in udp_lib_lport_inuse()  argument
150 sk_for_each(sk2, &hslot->head) { in udp_lib_lport_inuse()
209 static int udp_reuseport_add_sock(struct sock *sk, struct udp_hslot *hslot) in udp_reuseport_add_sock() argument
215 sk_for_each(sk2, &hslot->head) { in udp_reuseport_add_sock()
243 struct udp_hslot *hslot, *hslot2; in udp_lib_get_port() local
265 hslot = udp_hashslot(udptable, net, first); in udp_lib_get_port()
267 spin_lock_bh(&hslot->lock); in udp_lib_get_port()
268 udp_lib_lport_inuse(net, snum, hslot, bitmap, sk, in udp_lib_get_port()
284 spin_unlock_bh(&hslot->lock); in udp_lib_get_port()
289 hslot = udp_hashslot(udptable, net, snum); in udp_lib_get_port()
290 spin_lock_bh(&hslot->lock); in udp_lib_get_port()
291 if (hslot->count > 10) { in udp_lib_get_port()
299 if (hslot->count < hslot2->count) in udp_lib_get_port()
314 if (udp_lib_lport_inuse(net, snum, hslot, NULL, sk, 0)) in udp_lib_get_port()
323 udp_reuseport_add_sock(sk, hslot)) { in udp_lib_get_port()
330 sk_add_node_rcu(sk, &hslot->head); in udp_lib_get_port()
331 hslot->count++; in udp_lib_get_port()
349 spin_unlock_bh(&hslot->lock); in udp_lib_get_port()
471 struct udp_hslot *hslot2, *hslot = &udptable->hash[slot]; in __udp4_lib_lookup() local
476 if (hslot->count > 10) { in __udp4_lib_lookup()
480 if (hslot->count < hslot2->count) in __udp4_lib_lookup()
495 if (hslot->count < hslot2->count) in __udp4_lib_lookup()
509 sk_for_each_rcu(sk, &hslot->head) { in __udp4_lib_lookup()
1790 struct udp_hslot *hslot, *hslot2; in udp_lib_unhash() local
1792 hslot = udp_hashslot(udptable, sock_net(sk), in udp_lib_unhash()
1796 spin_lock_bh(&hslot->lock); in udp_lib_unhash()
1800 hslot->count--; in udp_lib_unhash()
1809 spin_unlock_bh(&hslot->lock); in udp_lib_unhash()
1821 struct udp_hslot *hslot, *hslot2, *nhslot2; in udp_lib_rehash() local
1829 hslot = udp_hashslot(udptable, sock_net(sk), in udp_lib_rehash()
1832 spin_lock_bh(&hslot->lock); in udp_lib_rehash()
1849 spin_unlock_bh(&hslot->lock); in udp_lib_rehash()
2039 struct udp_hslot *hslot = udp_hashslot(udptable, net, hnum); in __udp4_lib_mcast_deliver() local
2040 unsigned int hash2 = 0, hash2_any = 0, use_hash2 = (hslot->count > 10); in __udp4_lib_mcast_deliver()
2052 hslot = &udptable->hash2[hash2]; in __udp4_lib_mcast_deliver()
2056 sk_for_each_entry_offset_rcu(sk, node, &hslot->head, offset) { in __udp4_lib_mcast_deliver()
2261 struct udp_hslot *hslot = &udp_table.hash[slot]; in __udp4_lib_mcast_demux_lookup() local
2264 if (hslot->count > 10) in __udp4_lib_mcast_demux_lookup()
2268 sk_for_each_rcu(sk, &hslot->head) { in __udp4_lib_mcast_demux_lookup()
2680 struct udp_hslot *hslot = &afinfo->udp_table->hash[state->bucket]; in udp_get_first() local
2682 if (hlist_empty(&hslot->head)) in udp_get_first()
2685 spin_lock_bh(&hslot->lock); in udp_get_first()
2686 sk_for_each(sk, &hslot->head) { in udp_get_first()
2692 spin_unlock_bh(&hslot->lock); in udp_get_first()