]> git.baikalelectronics.ru Git - kernel.git/commit
icmp: Fix data-races around sysctl.
authorKuniyuki Iwashima <kuniyu@amazon.com>
Wed, 6 Jul 2022 23:40:02 +0000 (16:40 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 8 Jul 2022 11:10:34 +0000 (12:10 +0100)
commit048e9f68e49eeadf630d1ba7ab1b92126cdcbf60
tree00ac31005a3bd8dd7c3cb04c2e909c927967ee1c
parent6fa6f936c1c00ce517382fe1390f915d8c411ce9
icmp: Fix data-races around sysctl.

While reading icmp sysctl variables, they can be changed concurrently.
So, we need to add READ_ONCE() to avoid data-races.

Fixes: b79ef23fca00 ("icmp: add a global rate limitation")
Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/icmp.c