diff options
| author | Kuniyuki Iwashima <kuniyu@amazon.com> | 2022-08-23 10:46:48 -0700 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2022-09-05 10:26:30 +0200 |
| commit | 0b6dccd3077ad91ba6fd368fd77cb6b792faa1ac (patch) | |
| tree | 1b649a04a6900886c4059c6528293d6ed9dfc04d /include | |
| parent | 8121bda0093a1e4ad517d93a5707e2a5615c6f99 (diff) | |
ratelimit: Fix data-races in ___ratelimit().
[ Upstream commit 6bae8ceb90ba76cdba39496db936164fa672b9be ]
While reading rs->interval and rs->burst, they can be changed
concurrently via sysctl (e.g. net_ratelimit_state). Thus, we
need to add READ_ONCE() to their 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>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions
