Skip to content

Commit 9a79c65

Browse files
JasonXingkuba-moo
authored andcommitted
tcp/dccp: complete lockless accesses to sk->sk_max_ack_backlog
Since commit 099ecf5 ("net: annotate lockless accesses to sk->sk_max_ack_backlog") decided to handle the sk_max_ack_backlog locklessly, there is one more function mostly called in TCP/DCCP cases. So this patch completes it:) Signed-off-by: Jason Xing <kernelxing@tencent.com> Reviewed-by: Eric Dumazet <edumazet@google.com> Link: https://lore.kernel.org/r/20240331090521.71965-1-kerneljasonxing@gmail.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent f9a4506 commit 9a79c65

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/net/inet_connection_sock.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ static inline int inet_csk_reqsk_queue_len(const struct sock *sk)
281281

282282
static inline int inet_csk_reqsk_queue_is_full(const struct sock *sk)
283283
{
284-
return inet_csk_reqsk_queue_len(sk) >= sk->sk_max_ack_backlog;
284+
return inet_csk_reqsk_queue_len(sk) >= READ_ONCE(sk->sk_max_ack_backlog);
285285
}
286286

287287
bool inet_csk_reqsk_queue_drop(struct sock *sk, struct request_sock *req);

0 commit comments

Comments
 (0)