]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
tcp: Fix a data-race around sysctl_tcp_rfc1337.
authorKuniyuki Iwashima <kuniyu@amazon.com>
Mon, 18 Jul 2022 17:26:51 +0000 (10:26 -0700)
committerStefan Bader <stefan.bader@canonical.com>
Fri, 16 Sep 2022 08:53:26 +0000 (10:53 +0200)
commit032ed611c0b5dfa564efa9a3be0d2c01d40b1cb3
tree856fc1655dc7273914de770756b309e6cb55a067
parent55eee7a56487d9e52f7aa52f8db889e6e778c8b3
tcp: Fix a data-race around sysctl_tcp_rfc1337.

BugLink: https://bugs.launchpad.net/bugs/1988479
[ Upstream commit 0b484c91911e758e53656d570de58c2ed81ec6f2 ]

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

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
net/ipv4/tcp_minisocks.c