]> git.baikalelectronics.ru Git - kernel.git/commit
net: Fix a data-race around netdev_budget_usecs.
authorKuniyuki Iwashima <kuniyu@amazon.com>
Tue, 23 Aug 2022 17:46:55 +0000 (10:46 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 24 Aug 2022 12:46:58 +0000 (13:46 +0100)
commit59f937ddc697f12a78e8b24358547f8cbf847f60
treefa4046a28fd1b138945ad4e81880029d5b22a793
parentc14f7ed4a341e63a0fa56f5b429e0d655ee08397
net: Fix a data-race around netdev_budget_usecs.

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

Fixes: 74cb56bd48c3 ("Replace 2 jiffies with sysctl netdev_budget_usecs to enable softirq tuning")
Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/dev.c