aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/af_inet6.c
diff options
context:
space:
mode:
authorDaniel Lezcano <dlezcano@fr.ibm.com>2008-03-21 07:14:45 -0400
committerDavid S. Miller <davem@davemloft.net>2008-03-21 07:14:45 -0400
commit6f8b13bcb3369a5df2e63acc422bed6098f5b8c4 (patch)
tree715d53b85e86b26c113b417e269602d1cb8ca436 /net/ipv6/af_inet6.c
parent0c96d8c50bffb7f02690dd8a8cf1adb8e07e100f (diff)
[NETNS][IPV6] tcp6 - make proc per namespace
Make the proc for tcp6 to be per namespace. Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/af_inet6.c')
-rw-r--r--net/ipv6/af_inet6.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/net/ipv6/af_inet6.c b/net/ipv6/af_inet6.c
index e3e09147d134..f52bdaed8a1b 100644
--- a/net/ipv6/af_inet6.c
+++ b/net/ipv6/af_inet6.c
@@ -859,15 +859,25 @@ static int inet6_net_init(struct net *net)
859 err = udp6_proc_init(net); 859 err = udp6_proc_init(net);
860 if (err) 860 if (err)
861 goto out; 861 goto out;
862 err = tcp6_proc_init(net);
863 if (err)
864 goto proc_tcp6_fail;
862out: 865out:
863#endif 866#endif
864 return err; 867 return err;
868
869#ifdef CONFIG_PROC_FS
870proc_tcp6_fail:
871 udp6_proc_exit(net);
872 goto out;
873#endif
865} 874}
866 875
867static void inet6_net_exit(struct net *net) 876static void inet6_net_exit(struct net *net)
868{ 877{
869#ifdef CONFIG_PROC_FS 878#ifdef CONFIG_PROC_FS
870 udp6_proc_exit(net); 879 udp6_proc_exit(net);
880 tcp6_proc_exit(net);
871#endif 881#endif
872} 882}
873 883
@@ -951,8 +961,6 @@ static int __init inet6_init(void)
951 err = -ENOMEM; 961 err = -ENOMEM;
952 if (raw6_proc_init()) 962 if (raw6_proc_init())
953 goto proc_raw6_fail; 963 goto proc_raw6_fail;
954 if (tcp6_proc_init())
955 goto proc_tcp6_fail;
956 if (udplite6_proc_init()) 964 if (udplite6_proc_init())
957 goto proc_udplite6_fail; 965 goto proc_udplite6_fail;
958 if (ipv6_misc_proc_init()) 966 if (ipv6_misc_proc_init())
@@ -1037,8 +1045,6 @@ proc_anycast6_fail:
1037proc_misc6_fail: 1045proc_misc6_fail:
1038 udplite6_proc_exit(); 1046 udplite6_proc_exit();
1039proc_udplite6_fail: 1047proc_udplite6_fail:
1040 tcp6_proc_exit();
1041proc_tcp6_fail:
1042 raw6_proc_exit(); 1048 raw6_proc_exit();
1043proc_raw6_fail: 1049proc_raw6_fail:
1044#endif 1050#endif
@@ -1098,7 +1104,6 @@ static void __exit inet6_exit(void)
1098 ac6_proc_exit(); 1104 ac6_proc_exit();
1099 ipv6_misc_proc_exit(); 1105 ipv6_misc_proc_exit();
1100 udplite6_proc_exit(); 1106 udplite6_proc_exit();
1101 tcp6_proc_exit();
1102 raw6_proc_exit(); 1107 raw6_proc_exit();
1103#endif 1108#endif
1104 ipv6_netfilter_fini(); 1109 ipv6_netfilter_fini();