diff mbox series

[RFC,22/25] net: Move subsys_initcall() registered pernet_operations from net/sched to pernet_sys list

Message ID 151094344496.20009.9608805382234734305.stgit@localhost.localdomain
State RFC, archived
Delegated to: David Miller
Headers show
Series [RFC,01/25] net: Assign net to net_namespace_list in setup_net() | expand

Commit Message

Kirill Tkhai Nov. 17, 2017, 6:30 p.m. UTC
psched_net_ops only creates and destroyes /proc entry,
and safe to be executed in parallel with any foreigh
pernet_operations.

tcf_action_net_ops initializes and destructs tcf_action_net::egdev_ht,
which is not touched by foreign pernet_operations.

So, move them to pernet_sys list.

Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
---
 net/sched/act_api.c |    2 +-
 net/sched/sch_api.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/net/sched/act_api.c b/net/sched/act_api.c
index 4d33a50a8a6d..f1de2146e6e0 100644
--- a/net/sched/act_api.c
+++ b/net/sched/act_api.c
@@ -1470,7 +1470,7 @@  static int __init tc_action_init(void)
 {
 	int err;
 
-	err = register_pernet_subsys(&tcf_action_net_ops);
+	err = register_pernet_sys(&tcf_action_net_ops);
 	if (err)
 		return err;
 
diff --git a/net/sched/sch_api.c b/net/sched/sch_api.c
index b6c4f536876b..68938ca4bbe1 100644
--- a/net/sched/sch_api.c
+++ b/net/sched/sch_api.c
@@ -2008,7 +2008,7 @@  static int __init pktsched_init(void)
 {
 	int err;
 
-	err = register_pernet_subsys(&psched_net_ops);
+	err = register_pernet_sys(&psched_net_ops);
 	if (err) {
 		pr_err("pktsched_init: "
 		       "cannot initialize per netns operations\n");