]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
netrom: Fix a data-race around sysctl_netrom_transport_requested_window_size
authorJason Xing <kernelxing@tencent.com>
Mon, 4 Mar 2024 08:20:42 +0000 (16:20 +0800)
committerSasha Levin <sashal@kernel.org>
Fri, 15 Mar 2024 14:48:21 +0000 (10:48 -0400)
commit0d43a58900e5a2bfcc9de47e16c6c501c0bef853
tree62b6a199cebd9a6d6febef6914b93fca1774630d
parent0a30016e892bccabea30af218782c4b6ce0970af
netrom: Fix a data-race around sysctl_netrom_transport_requested_window_size

[ Upstream commit a2e706841488f474c06e9b33f71afc947fb3bf56 ]

We need to protect the reader reading the sysctl value because the
value can be changed concurrently.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Signed-off-by: Jason Xing <kernelxing@tencent.com>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/netrom/af_netrom.c