diff options
Diffstat (limited to 'net/core/fib_notifier.c')
-rw-r--r-- | net/core/fib_notifier.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/net/core/fib_notifier.c b/net/core/fib_notifier.c index 0c048bdeb016..614b985c92a4 100644 --- a/net/core/fib_notifier.c +++ b/net/core/fib_notifier.c | |||
@@ -33,6 +33,7 @@ static unsigned int fib_seq_sum(void) | |||
33 | struct net *net; | 33 | struct net *net; |
34 | 34 | ||
35 | rtnl_lock(); | 35 | rtnl_lock(); |
36 | down_read(&net_rwsem); | ||
36 | for_each_net(net) { | 37 | for_each_net(net) { |
37 | rcu_read_lock(); | 38 | rcu_read_lock(); |
38 | list_for_each_entry_rcu(ops, &net->fib_notifier_ops, list) { | 39 | list_for_each_entry_rcu(ops, &net->fib_notifier_ops, list) { |
@@ -43,6 +44,7 @@ static unsigned int fib_seq_sum(void) | |||
43 | } | 44 | } |
44 | rcu_read_unlock(); | 45 | rcu_read_unlock(); |
45 | } | 46 | } |
47 | up_read(&net_rwsem); | ||
46 | rtnl_unlock(); | 48 | rtnl_unlock(); |
47 | 49 | ||
48 | return fib_seq; | 50 | return fib_seq; |