]> git.itanic.dy.fi Git - linux-stable/commit
net: Fix a data-race around sysctl_somaxconn.
authorKuniyuki Iwashima <kuniyu@amazon.com>
Tue, 23 Aug 2022 17:47:00 +0000 (10:47 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 24 Aug 2022 12:46:58 +0000 (13:46 +0100)
commit3c9ba81d72047f2e81bb535d42856517b613aba7
tree7ec90a2dd4a26d38004c039257620480dc404d31
parent05e49cfc89e4f325eebbc62d24dd122e55f94c23
net: Fix a data-race around sysctl_somaxconn.

While reading sysctl_somaxconn, 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>
net/socket.c