net: Convert /proc creating and destroying pernet_operations
authorKirill Tkhai <ktkhai@virtuozzo.com>
Mon, 26 Feb 2018 12:59:19 +0000 (15:59 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 27 Feb 2018 16:01:35 +0000 (11:01 -0500)
These pernet_operations just create and destroy /proc entries,
and they can safely marked as async:

pppoe_net_ops
vlan_net_ops
canbcm_pernet_ops
kcm_net_ops
pfkey_net_ops
pppol2tp_net_ops
phonet_net_ops

Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ppp/pppoe.c
net/8021q/vlan.c
net/can/bcm.c
net/kcm/kcmproc.c
net/key/af_key.c
net/l2tp/l2tp_ppp.c
net/phonet/pn_dev.c

index bd89d1c559cef5329a7b7dfa238d04d4bf54811c..c10e6181a2f0d0758eb1e43b60c19e85efd0b98a 100644 (file)
@@ -1161,6 +1161,7 @@ static struct pernet_operations pppoe_net_ops = {
        .exit = pppoe_exit_net,
        .id   = &pppoe_net_id,
        .size = sizeof(struct pppoe_net),
+       .async = true,
 };
 
 static int __init pppoe_init(void)
index bad01b14a4ad6b5d4e61ac5e0ed93022755223ab..bd0ed39f65fbb20621ef73513872e1b21c3dade1 100644 (file)
@@ -729,6 +729,7 @@ static struct pernet_operations vlan_net_ops = {
        .exit = vlan_exit_net,
        .id   = &vlan_net_id,
        .size = sizeof(struct vlan_net),
+       .async = true,
 };
 
 static int __init vlan_proto_init(void)
index ac5e5e34fee32e94e7ad7592f537223e5db29b4f..26730d39e048343f4c3ac0dcc4f4f26545cd0e0b 100644 (file)
@@ -1717,6 +1717,7 @@ static void canbcm_pernet_exit(struct net *net)
 static struct pernet_operations canbcm_pernet_ops __read_mostly = {
        .init = canbcm_pernet_init,
        .exit = canbcm_pernet_exit,
+       .async = true,
 };
 
 static int __init bcm_module_init(void)
index 9d5649e4e8b7cc3b6e54e745f0cf9d98bf097929..2c1c8b3e44522741d53c1dea9b4459945787f1b4 100644 (file)
@@ -433,6 +433,7 @@ static void kcm_proc_exit_net(struct net *net)
 static struct pernet_operations kcm_net_ops = {
        .init = kcm_proc_init_net,
        .exit = kcm_proc_exit_net,
+       .async = true,
 };
 
 int __init kcm_proc_init(void)
index 7e2e7188e7f4a28aa45c26848364ab0c297161a2..3ac08ab26207d09a41a17da44de8a8299572be45 100644 (file)
@@ -3863,6 +3863,7 @@ static struct pernet_operations pfkey_net_ops = {
        .exit = pfkey_net_exit,
        .id   = &pfkey_net_id,
        .size = sizeof(struct netns_pfkey),
+       .async = true,
 };
 
 static void __exit ipsec_pfkey_exit(void)
index 99a03c72db4f8d9af4043945d2a618da3b198726..0c4f49a6a0cb1e6b94bf22c35ea4ef0dc6d4e1b4 100644 (file)
@@ -1770,6 +1770,7 @@ static struct pernet_operations pppol2tp_net_ops = {
        .init = pppol2tp_init_net,
        .exit = pppol2tp_exit_net,
        .id   = &pppol2tp_net_id,
+       .async = true,
 };
 
 /*****************************************************************************
index 77787512fc32cbd0a0cb842a88a31c6711218b8c..9454e839379310592e7c04c5555b2fa9555d31d5 100644 (file)
@@ -342,6 +342,7 @@ static struct pernet_operations phonet_net_ops = {
        .exit = phonet_exit_net,
        .id   = &phonet_net_id,
        .size = sizeof(struct phonet_net),
+       .async = true,
 };
 
 /* Initialize Phonet devices list */