mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-08 03:40:35 +09:00
net: add missing READ_ONCE(sk->sk_sndbuf) annotation
[ Upstream commit74bc084327] In a prior commit, I forgot to change sk_getsockopt() when reading sk->sk_sndbuf locklessly. Fixes:e292f05e0d("tcp: annotate sk->sk_sndbuf lockless reads") Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
9cd3adc26e
commit
ec4b7532d7
@@ -1258,7 +1258,7 @@ int sock_getsockopt(struct socket *sock, int level, int optname,
|
||||
break;
|
||||
|
||||
case SO_SNDBUF:
|
||||
v.val = sk->sk_sndbuf;
|
||||
v.val = READ_ONCE(sk->sk_sndbuf);
|
||||
break;
|
||||
|
||||
case SO_RCVBUF:
|
||||
|
||||
Reference in New Issue
Block a user