tcp: annotate data-races around fastopenq.max_qlen
[ Upstream commit 70f360dd7042cb843635ece9d28335a4addff9eb ]
This field can be read locklessly.
Fixes: 1536e2857b
("tcp: Add a TCP_FASTOPEN socket option to get a max backlog on its listner")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Link: https://lore.kernel.org/r/20230719212857.3943972-12-edumazet@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:

committed by
Greg Kroah-Hartman

parent
d01afbfc2f
commit
e0ac63e194
@@ -473,7 +473,7 @@ static inline void fastopen_queue_tune(struct sock *sk, int backlog)
|
||||
struct request_sock_queue *queue = &inet_csk(sk)->icsk_accept_queue;
|
||||
int somaxconn = READ_ONCE(sock_net(sk)->core.sysctl_somaxconn);
|
||||
|
||||
queue->fastopenq.max_qlen = min_t(unsigned int, backlog, somaxconn);
|
||||
WRITE_ONCE(queue->fastopenq.max_qlen, min_t(unsigned int, backlog, somaxconn));
|
||||
}
|
||||
|
||||
static inline void tcp_move_syn(struct tcp_sock *tp,
|
||||
|
Reference in New Issue
Block a user