Lines Matching refs:hslot
137 const struct udp_hslot *hslot, in udp_lib_lport_inuse() argument
148 sk_nulls_for_each(sk2, node, &hslot->head) { in udp_lib_lport_inuse()
214 struct udp_hslot *hslot, *hslot2; in udp_lib_get_port() local
236 hslot = udp_hashslot(udptable, net, first); in udp_lib_get_port()
238 spin_lock_bh(&hslot->lock); in udp_lib_get_port()
239 udp_lib_lport_inuse(net, snum, hslot, bitmap, sk, in udp_lib_get_port()
255 spin_unlock_bh(&hslot->lock); in udp_lib_get_port()
259 hslot = udp_hashslot(udptable, net, snum); in udp_lib_get_port()
260 spin_lock_bh(&hslot->lock); in udp_lib_get_port()
261 if (hslot->count > 10) { in udp_lib_get_port()
269 if (hslot->count < hslot2->count) in udp_lib_get_port()
285 if (udp_lib_lport_inuse(net, snum, hslot, NULL, sk, in udp_lib_get_port()
294 sk_nulls_add_node_rcu(sk, &hslot->head); in udp_lib_get_port()
295 hslot->count++; in udp_lib_get_port()
307 spin_unlock_bh(&hslot->lock); in udp_lib_get_port()
500 struct udp_hslot *hslot2, *hslot = &udptable->hash[slot]; in __udp4_lib_lookup() local
505 if (hslot->count > 10) { in __udp4_lib_lookup()
509 if (hslot->count < hslot2->count) in __udp4_lib_lookup()
519 if (hslot->count < hslot2->count) in __udp4_lib_lookup()
532 sk_nulls_for_each_rcu(sk, node, &hslot->head) { in __udp4_lib_lookup()
1385 struct udp_hslot *hslot, *hslot2; in udp_lib_unhash() local
1387 hslot = udp_hashslot(udptable, sock_net(sk), in udp_lib_unhash()
1391 spin_lock_bh(&hslot->lock); in udp_lib_unhash()
1393 hslot->count--; in udp_lib_unhash()
1402 spin_unlock_bh(&hslot->lock); in udp_lib_unhash()
1414 struct udp_hslot *hslot, *hslot2, *nhslot2; in udp_lib_rehash() local
1420 hslot = udp_hashslot(udptable, sock_net(sk), in udp_lib_rehash()
1423 spin_lock_bh(&hslot->lock); in udp_lib_rehash()
1436 spin_unlock_bh(&hslot->lock); in udp_lib_rehash()
1664 struct udp_hslot *hslot = udp_hashslot(udptable, net, hnum); in __udp4_lib_mcast_deliver() local
1667 unsigned int hash2 = 0, hash2_any = 0, use_hash2 = (hslot->count > 10); in __udp4_lib_mcast_deliver()
1675 hslot = &udp_table.hash2[hash2]; in __udp4_lib_mcast_deliver()
1679 spin_lock(&hslot->lock); in __udp4_lib_mcast_deliver()
1680 sk_nulls_for_each_entry_offset(sk, node, &hslot->head, offset) { in __udp4_lib_mcast_deliver()
1695 spin_unlock(&hslot->lock); in __udp4_lib_mcast_deliver()
1873 struct udp_hslot *hslot = &udp_table.hash[slot]; in __udp4_lib_mcast_demux_lookup() local
1876 if (hslot->count > 10) in __udp4_lib_mcast_demux_lookup()
1883 sk_nulls_for_each_rcu(sk, node, &hslot->head) { in __udp4_lib_mcast_demux_lookup()
2296 struct udp_hslot *hslot = &state->udp_table->hash[state->bucket]; in udp_get_first() local
2298 if (hlist_nulls_empty(&hslot->head)) in udp_get_first()
2301 spin_lock_bh(&hslot->lock); in udp_get_first()
2302 sk_nulls_for_each(sk, node, &hslot->head) { in udp_get_first()
2308 spin_unlock_bh(&hslot->lock); in udp_get_first()