inet6_hashtables.c (0f495f7617229772403e683033abc473f0f0553c) inet6_hashtables.c (2a61776366bd17db9ac8c93ec32b8e0ae6b11cf2)
1// SPDX-License-Identifier: GPL-2.0-or-later
2/*
3 * INET An implementation of the TCP/IP protocol suite for the LINUX
4 * operating system. INET is implemented using the BSD Socket
5 * interface as the means of communication with the user level.
6 *
7 * Generic INET6 transport hashtables
8 *

--- 100 unchanged lines hidden (view full) ---

109 if (READ_ONCE(sk->sk_incoming_cpu) == raw_smp_processor_id())
110 score++;
111 }
112 return score;
113}
114
115INDIRECT_CALLABLE_DECLARE(inet6_ehashfn_t udp6_ehashfn);
116
1// SPDX-License-Identifier: GPL-2.0-or-later
2/*
3 * INET An implementation of the TCP/IP protocol suite for the LINUX
4 * operating system. INET is implemented using the BSD Socket
5 * interface as the means of communication with the user level.
6 *
7 * Generic INET6 transport hashtables
8 *

--- 100 unchanged lines hidden (view full) ---

109 if (READ_ONCE(sk->sk_incoming_cpu) == raw_smp_processor_id())
110 score++;
111 }
112 return score;
113}
114
115INDIRECT_CALLABLE_DECLARE(inet6_ehashfn_t udp6_ehashfn);
116
117/**
118 * inet6_lookup_reuseport() - execute reuseport logic on AF_INET6 socket if necessary.
119 * @net: network namespace.
120 * @sk: AF_INET6 socket, must be in TCP_LISTEN state for TCP or TCP_CLOSE for UDP.
121 * @skb: context for a potential SK_REUSEPORT program.
122 * @doff: header offset.
123 * @saddr: source address.
124 * @sport: source port.
125 * @daddr: destination address.
126 * @hnum: destination port in host byte order.
127 * @ehashfn: hash function used to generate the fallback hash.
128 *
129 * Return: NULL if sk doesn't have SO_REUSEPORT set, otherwise a pointer to
130 * the selected sock or an error.
131 */
117struct sock *inet6_lookup_reuseport(struct net *net, struct sock *sk,
118 struct sk_buff *skb, int doff,
119 const struct in6_addr *saddr,
120 __be16 sport,
121 const struct in6_addr *daddr,
122 unsigned short hnum,
123 inet6_ehashfn_t *ehashfn)
124{

--- 221 unchanged lines hidden ---
132struct sock *inet6_lookup_reuseport(struct net *net, struct sock *sk,
133 struct sk_buff *skb, int doff,
134 const struct in6_addr *saddr,
135 __be16 sport,
136 const struct in6_addr *daddr,
137 unsigned short hnum,
138 inet6_ehashfn_t *ehashfn)
139{

--- 221 unchanged lines hidden ---