]> git.baikalelectronics.ru Git - kernel.git/commit
ipv4: Fix data-races around sysctl_fib_notify_on_flag_change.
authorKuniyuki Iwashima <kuniyu@amazon.com>
Fri, 22 Jul 2022 18:22:05 +0000 (11:22 -0700)
committerDavid S. Miller <davem@davemloft.net>
Mon, 25 Jul 2022 11:42:10 +0000 (12:42 +0100)
commit95980e9f004abf47f6bd3c4c2864ed72c5f3b469
tree66d7648a2edd38f2996da441df019b0632adb5ce
parentef5147f037302fc6b6c42980ce5c0eb632978d6a
ipv4: Fix data-races around sysctl_fib_notify_on_flag_change.

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

Fixes: 1d4352c9675c ("net: ipv4: Emit notification when fib hardware flags are changed")
Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/fib_trie.c