]> git.baikalelectronics.ru Git - kernel.git/commit
tcp: Fix data-races around sysctl_tcp_moderate_rcvbuf.
authorKuniyuki Iwashima <kuniyu@amazon.com>
Wed, 20 Jul 2022 16:50:18 +0000 (09:50 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 22 Jul 2022 11:06:17 +0000 (12:06 +0100)
commit4cb69a9d96e068da38c4ce225da4c69e7022d70f
tree1c5eccb931a4222e45ac290ef3c7334db3a0df50
parent7b8512603083cf7666210748820e9b22a8977b2a
tcp: Fix data-races around sysctl_tcp_moderate_rcvbuf.

While reading sysctl_tcp_moderate_rcvbuf, it can be changed
concurrently.  Thus, we need to add READ_ONCE() to its readers.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/tcp_input.c
net/mptcp/protocol.c