diff options
36 files changed, 44 insertions, 171 deletions
diff --git a/drivers/infiniband/core/ucma.c b/drivers/infiniband/core/ucma.c index 9f3e2beec91d..8002ae642cfe 100644 --- a/drivers/infiniband/core/ucma.c +++ b/drivers/infiniband/core/ucma.c | |||
| @@ -66,12 +66,6 @@ static ctl_table ucma_ctl_table[] = { | |||
| 66 | { } | 66 | { } |
| 67 | }; | 67 | }; |
| 68 | 68 | ||
| 69 | static struct ctl_path ucma_ctl_path[] = { | ||
| 70 | { .procname = "net" }, | ||
| 71 | { .procname = "rdma_ucm" }, | ||
| 72 | { } | ||
| 73 | }; | ||
| 74 | |||
| 75 | struct ucma_file { | 69 | struct ucma_file { |
| 76 | struct mutex mut; | 70 | struct mutex mut; |
| 77 | struct file *filp; | 71 | struct file *filp; |
| @@ -1392,7 +1386,7 @@ static int __init ucma_init(void) | |||
| 1392 | goto err1; | 1386 | goto err1; |
| 1393 | } | 1387 | } |
| 1394 | 1388 | ||
| 1395 | ucma_ctl_table_hdr = register_net_sysctl_table(&init_net, ucma_ctl_path, ucma_ctl_table); | 1389 | ucma_ctl_table_hdr = register_net_sysctl(&init_net, "net/rdma_ucm", ucma_ctl_table); |
| 1396 | if (!ucma_ctl_table_hdr) { | 1390 | if (!ucma_ctl_table_hdr) { |
| 1397 | printk(KERN_ERR "rdma_ucm: couldn't register sysctl paths\n"); | 1391 | printk(KERN_ERR "rdma_ucm: couldn't register sysctl paths\n"); |
| 1398 | ret = -ENOMEM; | 1392 | ret = -ENOMEM; |
diff --git a/net/802/tr.c b/net/802/tr.c index 103e0201b0ab..30a352ed09b1 100644 --- a/net/802/tr.c +++ b/net/802/tr.c | |||
| @@ -643,12 +643,6 @@ static struct ctl_table tr_table[] = { | |||
| 643 | }, | 643 | }, |
| 644 | { }, | 644 | { }, |
| 645 | }; | 645 | }; |
| 646 | |||
| 647 | static __initdata struct ctl_path tr_path[] = { | ||
| 648 | { .procname = "net", }, | ||
| 649 | { .procname = "token-ring", }, | ||
| 650 | { } | ||
| 651 | }; | ||
| 652 | #endif | 646 | #endif |
| 653 | 647 | ||
| 654 | /* | 648 | /* |
| @@ -662,7 +656,7 @@ static int __init rif_init(void) | |||
| 662 | setup_timer(&rif_timer, rif_check_expire, 0); | 656 | setup_timer(&rif_timer, rif_check_expire, 0); |
| 663 | add_timer(&rif_timer); | 657 | add_timer(&rif_timer); |
| 664 | #ifdef CONFIG_SYSCTL | 658 | #ifdef CONFIG_SYSCTL |
| 665 | register_net_sysctl_table(&init_net, tr_path, tr_table); | 659 | register_net_sysctl(&init_net, "net/token-ring", tr_table); |
| 666 | #endif | 660 | #endif |
| 667 | proc_net_fops_create(&init_net, "tr_rif", S_IRUGO, &rif_seq_fops); | 661 | proc_net_fops_create(&init_net, "tr_rif", S_IRUGO, &rif_seq_fops); |
| 668 | return 0; | 662 | return 0; |
diff --git a/net/appletalk/sysctl_net_atalk.c b/net/appletalk/sysctl_net_atalk.c index 5edce8f70cb7..ebb864361f7a 100644 --- a/net/appletalk/sysctl_net_atalk.c +++ b/net/appletalk/sysctl_net_atalk.c | |||
| @@ -42,17 +42,11 @@ static struct ctl_table atalk_table[] = { | |||
| 42 | { }, | 42 | { }, |
| 43 | }; | 43 | }; |
| 44 | 44 | ||
| 45 | static struct ctl_path atalk_path[] = { | ||
| 46 | { .procname = "net", }, | ||
| 47 | { .procname = "appletalk", }, | ||
| 48 | { } | ||
| 49 | }; | ||
| 50 | |||
| 51 | static struct ctl_table_header *atalk_table_header; | 45 | static struct ctl_table_header *atalk_table_header; |
| 52 | 46 | ||
| 53 | void atalk_register_sysctl(void) | 47 | void atalk_register_sysctl(void) |
| 54 | { | 48 | { |
| 55 | atalk_table_header = register_net_sysctl_table(&init_net, atalk_path, atalk_table); | 49 | atalk_table_header = register_net_sysctl(&init_net, "net/appletalk", atalk_table); |
| 56 | } | 50 | } |
| 57 | 51 | ||
| 58 | void atalk_unregister_sysctl(void) | 52 | void atalk_unregister_sysctl(void) |
diff --git a/net/bridge/br_netfilter.c b/net/bridge/br_netfilter.c index 4f4c4a619f68..9d4f09c3520f 100644 --- a/net/bridge/br_netfilter.c +++ b/net/bridge/br_netfilter.c | |||
| @@ -1008,12 +1008,6 @@ static ctl_table brnf_table[] = { | |||
| 1008 | }, | 1008 | }, |
| 1009 | { } | 1009 | { } |
| 1010 | }; | 1010 | }; |
| 1011 | |||
| 1012 | static struct ctl_path brnf_path[] = { | ||
| 1013 | { .procname = "net", }, | ||
| 1014 | { .procname = "bridge", }, | ||
| 1015 | { } | ||
| 1016 | }; | ||
| 1017 | #endif | 1011 | #endif |
| 1018 | 1012 | ||
| 1019 | int __init br_netfilter_init(void) | 1013 | int __init br_netfilter_init(void) |
| @@ -1030,7 +1024,7 @@ int __init br_netfilter_init(void) | |||
| 1030 | return ret; | 1024 | return ret; |
| 1031 | } | 1025 | } |
| 1032 | #ifdef CONFIG_SYSCTL | 1026 | #ifdef CONFIG_SYSCTL |
| 1033 | brnf_sysctl_header = register_net_sysctl_table(&init_net, brnf_path, brnf_table); | 1027 | brnf_sysctl_header = register_net_sysctl(&init_net, "net/bridge", brnf_table); |
| 1034 | if (brnf_sysctl_header == NULL) { | 1028 | if (brnf_sysctl_header == NULL) { |
| 1035 | printk(KERN_WARNING | 1029 | printk(KERN_WARNING |
| 1036 | "br_netfilter: can't register to sysctl.\n"); | 1030 | "br_netfilter: can't register to sysctl.\n"); |
diff --git a/net/core/sysctl_net_core.c b/net/core/sysctl_net_core.c index 9fc2f9d666a9..64924e345a9b 100644 --- a/net/core/sysctl_net_core.c +++ b/net/core/sysctl_net_core.c | |||
| @@ -224,8 +224,7 @@ static __net_init int sysctl_core_net_init(struct net *net) | |||
| 224 | tbl[0].data = &net->core.sysctl_somaxconn; | 224 | tbl[0].data = &net->core.sysctl_somaxconn; |
| 225 | } | 225 | } |
| 226 | 226 | ||
| 227 | net->core.sysctl_hdr = register_net_sysctl_table(net, | 227 | net->core.sysctl_hdr = register_net_sysctl(net, "net/core", tbl); |
| 228 | net_core_path, tbl); | ||
| 229 | if (net->core.sysctl_hdr == NULL) | 228 | if (net->core.sysctl_hdr == NULL) |
| 230 | goto err_reg; | 229 | goto err_reg; |
| 231 | 230 | ||
diff --git a/net/dccp/sysctl.c b/net/dccp/sysctl.c index 329e1390c26d..607ab71b5a0c 100644 --- a/net/dccp/sysctl.c +++ b/net/dccp/sysctl.c | |||
| @@ -98,18 +98,11 @@ static struct ctl_table dccp_default_table[] = { | |||
| 98 | { } | 98 | { } |
| 99 | }; | 99 | }; |
| 100 | 100 | ||
| 101 | static struct ctl_path dccp_path[] = { | ||
| 102 | { .procname = "net", }, | ||
| 103 | { .procname = "dccp", }, | ||
| 104 | { .procname = "default", }, | ||
| 105 | { } | ||
| 106 | }; | ||
| 107 | |||
| 108 | static struct ctl_table_header *dccp_table_header; | 101 | static struct ctl_table_header *dccp_table_header; |
| 109 | 102 | ||
| 110 | int __init dccp_sysctl_init(void) | 103 | int __init dccp_sysctl_init(void) |
| 111 | { | 104 | { |
| 112 | dccp_table_header = register_net_sysctl_table(&init_net, dccp_path, | 105 | dccp_table_header = register_net_sysctl(&init_net, "net/dccp/default", |
| 113 | dccp_default_table); | 106 | dccp_default_table); |
| 114 | 107 | ||
| 115 | return dccp_table_header != NULL ? 0 : -ENOMEM; | 108 | return dccp_table_header != NULL ? 0 : -ENOMEM; |
diff --git a/net/ipv4/ip_fragment.c b/net/ipv4/ip_fragment.c index 6a2f85cd440e..71e5c328176c 100644 --- a/net/ipv4/ip_fragment.c +++ b/net/ipv4/ip_fragment.c | |||
| @@ -782,7 +782,7 @@ static int __net_init ip4_frags_ns_ctl_register(struct net *net) | |||
| 782 | table[2].data = &net->ipv4.frags.timeout; | 782 | table[2].data = &net->ipv4.frags.timeout; |
| 783 | } | 783 | } |
| 784 | 784 | ||
| 785 | hdr = register_net_sysctl_table(net, net_ipv4_ctl_path, table); | 785 | hdr = register_net_sysctl(net, "net/ipv4", table); |
| 786 | if (hdr == NULL) | 786 | if (hdr == NULL) |
| 787 | goto err_reg; | 787 | goto err_reg; |
| 788 | 788 | ||
diff --git a/net/ipv4/netfilter/ip_queue.c b/net/ipv4/netfilter/ip_queue.c index 766485d7d099..09775a1e1348 100644 --- a/net/ipv4/netfilter/ip_queue.c +++ b/net/ipv4/netfilter/ip_queue.c | |||
| @@ -586,7 +586,7 @@ static int __init ip_queue_init(void) | |||
| 586 | #endif | 586 | #endif |
| 587 | register_netdevice_notifier(&ipq_dev_notifier); | 587 | register_netdevice_notifier(&ipq_dev_notifier); |
| 588 | #ifdef CONFIG_SYSCTL | 588 | #ifdef CONFIG_SYSCTL |
| 589 | ipq_sysctl_header = register_net_sysctl_table(&init_net, net_ipv4_ctl_path, ipq_table); | 589 | ipq_sysctl_header = register_net_sysctl(&init_net, "net/ipv4", ipq_table); |
| 590 | #endif | 590 | #endif |
| 591 | status = nf_register_queue_handler(NFPROTO_IPV4, &nfqh); | 591 | status = nf_register_queue_handler(NFPROTO_IPV4, &nfqh); |
| 592 | if (status < 0) { | 592 | if (status < 0) { |
diff --git a/net/ipv4/route.c b/net/ipv4/route.c index adf2105a6e85..5773f5d9e213 100644 --- a/net/ipv4/route.c +++ b/net/ipv4/route.c | |||
| @@ -3354,13 +3354,6 @@ static struct ctl_table ipv4_route_flush_table[] = { | |||
| 3354 | { }, | 3354 | { }, |
| 3355 | }; | 3355 | }; |
| 3356 | 3356 | ||
| 3357 | static __net_initdata struct ctl_path ipv4_route_path[] = { | ||
| 3358 | { .procname = "net", }, | ||
| 3359 | { .procname = "ipv4", }, | ||
| 3360 | { .procname = "route", }, | ||
| 3361 | { }, | ||
| 3362 | }; | ||
| 3363 | |||
| 3364 | static __net_init int sysctl_route_net_init(struct net *net) | 3357 | static __net_init int sysctl_route_net_init(struct net *net) |
| 3365 | { | 3358 | { |
| 3366 | struct ctl_table *tbl; | 3359 | struct ctl_table *tbl; |
| @@ -3373,8 +3366,7 @@ static __net_init int sysctl_route_net_init(struct net *net) | |||
| 3373 | } | 3366 | } |
| 3374 | tbl[0].extra1 = net; | 3367 | tbl[0].extra1 = net; |
| 3375 | 3368 | ||
| 3376 | net->ipv4.route_hdr = | 3369 | net->ipv4.route_hdr = register_net_sysctl(net, "net/ipv4/route", tbl); |
| 3377 | register_net_sysctl_table(net, ipv4_route_path, tbl); | ||
| 3378 | if (net->ipv4.route_hdr == NULL) | 3370 | if (net->ipv4.route_hdr == NULL) |
| 3379 | goto err_reg; | 3371 | goto err_reg; |
| 3380 | return 0; | 3372 | return 0; |
diff --git a/net/ipv4/sysctl_net_ipv4.c b/net/ipv4/sysctl_net_ipv4.c index e7a6fa3d70bb..56e64f7b75d0 100644 --- a/net/ipv4/sysctl_net_ipv4.c +++ b/net/ipv4/sysctl_net_ipv4.c | |||
| @@ -815,8 +815,7 @@ static __net_init int ipv4_sysctl_init_net(struct net *net) | |||
| 815 | 815 | ||
| 816 | tcp_init_mem(net); | 816 | tcp_init_mem(net); |
| 817 | 817 | ||
| 818 | net->ipv4.ipv4_hdr = register_net_sysctl_table(net, | 818 | net->ipv4.ipv4_hdr = register_net_sysctl(net, "net/ipv4", table); |
| 819 | net_ipv4_ctl_path, table); | ||
| 820 | if (net->ipv4.ipv4_hdr == NULL) | 819 | if (net->ipv4.ipv4_hdr == NULL) |
| 821 | goto err_reg; | 820 | goto err_reg; |
| 822 | 821 | ||
| @@ -857,7 +856,7 @@ static __init int sysctl_ipv4_init(void) | |||
| 857 | if (!i->procname) | 856 | if (!i->procname) |
| 858 | return -EINVAL; | 857 | return -EINVAL; |
| 859 | 858 | ||
| 860 | hdr = register_net_sysctl_table(&init_net, net_ipv4_ctl_path, ipv4_table); | 859 | hdr = register_net_sysctl(&init_net, "net/ipv4", ipv4_table); |
| 861 | if (hdr == NULL) | 860 | if (hdr == NULL) |
| 862 | return -ENOMEM; | 861 | return -ENOMEM; |
| 863 | 862 | ||
diff --git a/net/ipv4/xfrm4_policy.c b/net/ipv4/xfrm4_policy.c index 8ef24e16afce..0d3426cb5c4f 100644 --- a/net/ipv4/xfrm4_policy.c +++ b/net/ipv4/xfrm4_policy.c | |||
| @@ -298,8 +298,8 @@ void __init xfrm4_init(int rt_max_size) | |||
| 298 | xfrm4_state_init(); | 298 | xfrm4_state_init(); |
| 299 | xfrm4_policy_init(); | 299 | xfrm4_policy_init(); |
| 300 | #ifdef CONFIG_SYSCTL | 300 | #ifdef CONFIG_SYSCTL |
| 301 | sysctl_hdr = register_net_sysctl_table(&init_net, net_ipv4_ctl_path, | 301 | sysctl_hdr = register_net_sysctl(&init_net, "net/ipv4", |
| 302 | xfrm4_policy_table); | 302 | xfrm4_policy_table); |
| 303 | #endif | 303 | #endif |
| 304 | } | 304 | } |
| 305 | 305 | ||
diff --git a/net/ipv6/netfilter/ip6_queue.c b/net/ipv6/netfilter/ip6_queue.c index 6785f5044acf..3ca9303b3a19 100644 --- a/net/ipv6/netfilter/ip6_queue.c +++ b/net/ipv6/netfilter/ip6_queue.c | |||
| @@ -588,7 +588,7 @@ static int __init ip6_queue_init(void) | |||
| 588 | #endif | 588 | #endif |
| 589 | register_netdevice_notifier(&ipq_dev_notifier); | 589 | register_netdevice_notifier(&ipq_dev_notifier); |
| 590 | #ifdef CONFIG_SYSCTL | 590 | #ifdef CONFIG_SYSCTL |
| 591 | ipq_sysctl_header = register_net_sysctl_table(&init_net, net_ipv6_ctl_path, ipq_table); | 591 | ipq_sysctl_header = register_net_sysctl(&init_net, "net/ipv6", ipq_table); |
| 592 | #endif | 592 | #endif |
| 593 | status = nf_register_queue_handler(NFPROTO_IPV6, &nfqh); | 593 | status = nf_register_queue_handler(NFPROTO_IPV6, &nfqh); |
| 594 | if (status < 0) { | 594 | if (status < 0) { |
diff --git a/net/ipv6/netfilter/nf_conntrack_reasm.c b/net/ipv6/netfilter/nf_conntrack_reasm.c index 754814462950..48a2be1b7c70 100644 --- a/net/ipv6/netfilter/nf_conntrack_reasm.c +++ b/net/ipv6/netfilter/nf_conntrack_reasm.c | |||
| @@ -626,8 +626,8 @@ int nf_ct_frag6_init(void) | |||
| 626 | inet_frags_init(&nf_frags); | 626 | inet_frags_init(&nf_frags); |
| 627 | 627 | ||
| 628 | #ifdef CONFIG_SYSCTL | 628 | #ifdef CONFIG_SYSCTL |
| 629 | nf_ct_frag6_sysctl_header = register_net_sysctl_table(&init_net, nf_net_netfilter_sysctl_path, | 629 | nf_ct_frag6_sysctl_header = register_net_sysctl(&init_net, "net/netfilter", |
| 630 | nf_ct_frag6_sysctl_table); | 630 | nf_ct_frag6_sysctl_table); |
| 631 | if (!nf_ct_frag6_sysctl_header) { | 631 | if (!nf_ct_frag6_sysctl_header) { |
| 632 | inet_frags_fini(&nf_frags); | 632 | inet_frags_fini(&nf_frags); |
| 633 | return -ENOMEM; | 633 | return -ENOMEM; |
diff --git a/net/ipv6/reassembly.c b/net/ipv6/reassembly.c index 42f4f7c0948a..36e04cff1a85 100644 --- a/net/ipv6/reassembly.c +++ b/net/ipv6/reassembly.c | |||
| @@ -646,7 +646,7 @@ static int __net_init ip6_frags_ns_sysctl_register(struct net *net) | |||
| 646 | table[2].data = &net->ipv6.frags.timeout; | 646 | table[2].data = &net->ipv6.frags.timeout; |
| 647 | } | 647 | } |
| 648 | 648 | ||
| 649 | hdr = register_net_sysctl_table(net, net_ipv6_ctl_path, table); | 649 | hdr = register_net_sysctl(net, "net/ipv6", table); |
| 650 | if (hdr == NULL) | 650 | if (hdr == NULL) |
| 651 | goto err_reg; | 651 | goto err_reg; |
| 652 | 652 | ||
diff --git a/net/ipv6/xfrm6_policy.c b/net/ipv6/xfrm6_policy.c index 8ea65e032733..8625fba96db9 100644 --- a/net/ipv6/xfrm6_policy.c +++ b/net/ipv6/xfrm6_policy.c | |||
| @@ -334,8 +334,8 @@ int __init xfrm6_init(void) | |||
| 334 | goto out_policy; | 334 | goto out_policy; |
| 335 | 335 | ||
| 336 | #ifdef CONFIG_SYSCTL | 336 | #ifdef CONFIG_SYSCTL |
| 337 | sysctl_hdr = register_net_sysctl_table(&init_net, net_ipv6_ctl_path, | 337 | sysctl_hdr = register_net_sysctl(&init_net, "net/ipv6", |
| 338 | xfrm6_policy_table); | 338 | xfrm6_policy_table); |
| 339 | #endif | 339 | #endif |
| 340 | out: | 340 | out: |
| 341 | return ret; | 341 | return ret; |
diff --git a/net/ipx/sysctl_net_ipx.c b/net/ipx/sysctl_net_ipx.c index 035880709e84..ad7c03dedaab 100644 --- a/net/ipx/sysctl_net_ipx.c +++ b/net/ipx/sysctl_net_ipx.c | |||
| @@ -28,17 +28,11 @@ static struct ctl_table ipx_table[] = { | |||
| 28 | { }, | 28 | { }, |
| 29 | }; | 29 | }; |
| 30 | 30 | ||
| 31 | static struct ctl_path ipx_path[] = { | ||
| 32 | { .procname = "net", }, | ||
| 33 | { .procname = "ipx", }, | ||
| 34 | { } | ||
| 35 | }; | ||
| 36 | |||
| 37 | static struct ctl_table_header *ipx_table_header; | 31 | static struct ctl_table_header *ipx_table_header; |
| 38 | 32 | ||
| 39 | void ipx_register_sysctl(void) | 33 | void ipx_register_sysctl(void) |
| 40 | { | 34 | { |
| 41 | ipx_table_header = register_net_sysctl_table(&init_net, ipx_path, ipx_table); | 35 | ipx_table_header = register_net_sysctl(&init_net, "net/ipx", ipx_table); |
| 42 | } | 36 | } |
| 43 | 37 | ||
| 44 | void ipx_unregister_sysctl(void) | 38 | void ipx_unregister_sysctl(void) |
diff --git a/net/irda/irsysctl.c b/net/irda/irsysctl.c index 20ced38fc371..de73f6496db5 100644 --- a/net/irda/irsysctl.c +++ b/net/irda/irsysctl.c | |||
| @@ -235,12 +235,6 @@ static ctl_table irda_table[] = { | |||
| 235 | { } | 235 | { } |
| 236 | }; | 236 | }; |
| 237 | 237 | ||
| 238 | static struct ctl_path irda_path[] = { | ||
| 239 | { .procname = "net", }, | ||
| 240 | { .procname = "irda", }, | ||
| 241 | { } | ||
| 242 | }; | ||
| 243 | |||
| 244 | static struct ctl_table_header *irda_table_header; | 238 | static struct ctl_table_header *irda_table_header; |
| 245 | 239 | ||
| 246 | /* | 240 | /* |
| @@ -251,7 +245,7 @@ static struct ctl_table_header *irda_table_header; | |||
| 251 | */ | 245 | */ |
| 252 | int __init irda_sysctl_register(void) | 246 | int __init irda_sysctl_register(void) |
| 253 | { | 247 | { |
| 254 | irda_table_header = register_net_sysctl_table(&init_net, irda_path, irda_table); | 248 | irda_table_header = register_net_sysctl(&init_net, "net/irda", irda_table); |
| 255 | if (!irda_table_header) | 249 | if (!irda_table_header) |
| 256 | return -ENOMEM; | 250 | return -ENOMEM; |
| 257 | 251 | ||
diff --git a/net/netfilter/ipvs/ip_vs_ctl.c b/net/netfilter/ipvs/ip_vs_ctl.c index b8d0df701227..a606d6b1b0e5 100644 --- a/net/netfilter/ipvs/ip_vs_ctl.c +++ b/net/netfilter/ipvs/ip_vs_ctl.c | |||
| @@ -3672,8 +3672,7 @@ int __net_init ip_vs_control_net_init_sysctl(struct net *net) | |||
| 3672 | tbl[idx++].data = &ipvs->sysctl_nat_icmp_send; | 3672 | tbl[idx++].data = &ipvs->sysctl_nat_icmp_send; |
| 3673 | 3673 | ||
| 3674 | 3674 | ||
| 3675 | ipvs->sysctl_hdr = register_net_sysctl_table(net, net_vs_ctl_path, | 3675 | ipvs->sysctl_hdr = register_net_sysctl(net, "net/ipv4/vs", tbl); |
| 3676 | tbl); | ||
| 3677 | if (ipvs->sysctl_hdr == NULL) { | 3676 | if (ipvs->sysctl_hdr == NULL) { |
| 3678 | if (!net_eq(net, &init_net)) | 3677 | if (!net_eq(net, &init_net)) |
| 3679 | kfree(tbl); | 3678 | kfree(tbl); |
diff --git a/net/netfilter/ipvs/ip_vs_lblc.c b/net/netfilter/ipvs/ip_vs_lblc.c index 27c24f156c28..1024466de124 100644 --- a/net/netfilter/ipvs/ip_vs_lblc.c +++ b/net/netfilter/ipvs/ip_vs_lblc.c | |||
| @@ -563,8 +563,7 @@ static int __net_init __ip_vs_lblc_init(struct net *net) | |||
| 563 | ipvs->lblc_ctl_table[0].data = &ipvs->sysctl_lblc_expiration; | 563 | ipvs->lblc_ctl_table[0].data = &ipvs->sysctl_lblc_expiration; |
| 564 | 564 | ||
| 565 | ipvs->lblc_ctl_header = | 565 | ipvs->lblc_ctl_header = |
| 566 | register_net_sysctl_table(net, net_vs_ctl_path, | 566 | register_net_sysctl(net, "net/ipv4/vs", ipvs->lblc_ctl_table); |
| 567 | ipvs->lblc_ctl_table); | ||
| 568 | if (!ipvs->lblc_ctl_header) { | 567 | if (!ipvs->lblc_ctl_header) { |
| 569 | if (!net_eq(net, &init_net)) | 568 | if (!net_eq(net, &init_net)) |
| 570 | kfree(ipvs->lblc_ctl_table); | 569 | kfree(ipvs->lblc_ctl_table); |
diff --git a/net/netfilter/ipvs/ip_vs_lblcr.c b/net/netfilter/ipvs/ip_vs_lblcr.c index 749875611ed6..9261825a6579 100644 --- a/net/netfilter/ipvs/ip_vs_lblcr.c +++ b/net/netfilter/ipvs/ip_vs_lblcr.c | |||
| @@ -757,8 +757,7 @@ static int __net_init __ip_vs_lblcr_init(struct net *net) | |||
| 757 | ipvs->lblcr_ctl_table[0].data = &ipvs->sysctl_lblcr_expiration; | 757 | ipvs->lblcr_ctl_table[0].data = &ipvs->sysctl_lblcr_expiration; |
| 758 | 758 | ||
| 759 | ipvs->lblcr_ctl_header = | 759 | ipvs->lblcr_ctl_header = |
| 760 | register_net_sysctl_table(net, net_vs_ctl_path, | 760 | register_net_sysctl(net, "net/ipv4/vs", ipvs->lblcr_ctl_table); |
| 761 | ipvs->lblcr_ctl_table); | ||
| 762 | if (!ipvs->lblcr_ctl_header) { | 761 | if (!ipvs->lblcr_ctl_header) { |
| 763 | if (!net_eq(net, &init_net)) | 762 | if (!net_eq(net, &init_net)) |
| 764 | kfree(ipvs->lblcr_ctl_table); | 763 | kfree(ipvs->lblcr_ctl_table); |
diff --git a/net/netfilter/nf_conntrack_acct.c b/net/netfilter/nf_conntrack_acct.c index f4f8cda05986..d61e0782a797 100644 --- a/net/netfilter/nf_conntrack_acct.c +++ b/net/netfilter/nf_conntrack_acct.c | |||
| @@ -69,8 +69,8 @@ static int nf_conntrack_acct_init_sysctl(struct net *net) | |||
| 69 | 69 | ||
| 70 | table[0].data = &net->ct.sysctl_acct; | 70 | table[0].data = &net->ct.sysctl_acct; |
| 71 | 71 | ||
| 72 | net->ct.acct_sysctl_header = register_net_sysctl_table(net, | 72 | net->ct.acct_sysctl_header = register_net_sysctl(net, "net/netfilter", |
| 73 | nf_net_netfilter_sysctl_path, table); | 73 | table); |
| 74 | if (!net->ct.acct_sysctl_header) { | 74 | if (!net->ct.acct_sysctl_header) { |
| 75 | printk(KERN_ERR "nf_conntrack_acct: can't register to sysctl.\n"); | 75 | printk(KERN_ERR "nf_conntrack_acct: can't register to sysctl.\n"); |
| 76 | goto out_register; | 76 | goto out_register; |
diff --git a/net/netfilter/nf_conntrack_ecache.c b/net/netfilter/nf_conntrack_ecache.c index 5bd3047ddeec..b924f3a49a8e 100644 --- a/net/netfilter/nf_conntrack_ecache.c +++ b/net/netfilter/nf_conntrack_ecache.c | |||
| @@ -199,8 +199,7 @@ static int nf_conntrack_event_init_sysctl(struct net *net) | |||
| 199 | table[1].data = &net->ct.sysctl_events_retry_timeout; | 199 | table[1].data = &net->ct.sysctl_events_retry_timeout; |
| 200 | 200 | ||
| 201 | net->ct.event_sysctl_header = | 201 | net->ct.event_sysctl_header = |
| 202 | register_net_sysctl_table(net, | 202 | register_net_sysctl(net, "net/netfilter", table); |
| 203 | nf_net_netfilter_sysctl_path, table); | ||
| 204 | if (!net->ct.event_sysctl_header) { | 203 | if (!net->ct.event_sysctl_header) { |
| 205 | printk(KERN_ERR "nf_ct_event: can't register to sysctl.\n"); | 204 | printk(KERN_ERR "nf_ct_event: can't register to sysctl.\n"); |
| 206 | goto out_register; | 205 | goto out_register; |
diff --git a/net/netfilter/nf_conntrack_proto_dccp.c b/net/netfilter/nf_conntrack_proto_dccp.c index a58998d0912f..ef706a485be1 100644 --- a/net/netfilter/nf_conntrack_proto_dccp.c +++ b/net/netfilter/nf_conntrack_proto_dccp.c | |||
| @@ -910,8 +910,8 @@ static __net_init int dccp_net_init(struct net *net) | |||
| 910 | dn->sysctl_table[6].data = &dn->dccp_timeout[CT_DCCP_TIMEWAIT]; | 910 | dn->sysctl_table[6].data = &dn->dccp_timeout[CT_DCCP_TIMEWAIT]; |
| 911 | dn->sysctl_table[7].data = &dn->dccp_loose; | 911 | dn->sysctl_table[7].data = &dn->dccp_loose; |
| 912 | 912 | ||
| 913 | dn->sysctl_header = register_net_sysctl_table(net, | 913 | dn->sysctl_header = register_net_sysctl(net, "net/netfilter", |
| 914 | nf_net_netfilter_sysctl_path, dn->sysctl_table); | 914 | dn->sysctl_table); |
| 915 | if (!dn->sysctl_header) { | 915 | if (!dn->sysctl_header) { |
| 916 | kfree(dn->sysctl_table); | 916 | kfree(dn->sysctl_table); |
| 917 | return -ENOMEM; | 917 | return -ENOMEM; |
diff --git a/net/netfilter/nf_conntrack_standalone.c b/net/netfilter/nf_conntrack_standalone.c index 0c3888de0f55..9b3943252a5e 100644 --- a/net/netfilter/nf_conntrack_standalone.c +++ b/net/netfilter/nf_conntrack_standalone.c | |||
| @@ -468,18 +468,13 @@ static ctl_table nf_ct_netfilter_table[] = { | |||
| 468 | { } | 468 | { } |
| 469 | }; | 469 | }; |
| 470 | 470 | ||
| 471 | static struct ctl_path nf_ct_path[] = { | ||
| 472 | { .procname = "net", }, | ||
| 473 | { } | ||
| 474 | }; | ||
| 475 | |||
| 476 | static int nf_conntrack_standalone_init_sysctl(struct net *net) | 471 | static int nf_conntrack_standalone_init_sysctl(struct net *net) |
| 477 | { | 472 | { |
| 478 | struct ctl_table *table; | 473 | struct ctl_table *table; |
| 479 | 474 | ||
| 480 | if (net_eq(net, &init_net)) { | 475 | if (net_eq(net, &init_net)) { |
| 481 | nf_ct_netfilter_header = | 476 | nf_ct_netfilter_header = |
| 482 | register_net_sysctl_table(&init_net, nf_ct_path, nf_ct_netfilter_table); | 477 | register_net_sysctl(&init_net, "net", nf_ct_netfilter_table); |
| 483 | if (!nf_ct_netfilter_header) | 478 | if (!nf_ct_netfilter_header) |
| 484 | goto out; | 479 | goto out; |
| 485 | } | 480 | } |
| @@ -494,8 +489,7 @@ static int nf_conntrack_standalone_init_sysctl(struct net *net) | |||
| 494 | table[3].data = &net->ct.sysctl_checksum; | 489 | table[3].data = &net->ct.sysctl_checksum; |
| 495 | table[4].data = &net->ct.sysctl_log_invalid; | 490 | table[4].data = &net->ct.sysctl_log_invalid; |
| 496 | 491 | ||
| 497 | net->ct.sysctl_header = register_net_sysctl_table(net, | 492 | net->ct.sysctl_header = register_net_sysctl(net, "net/netfilter", table); |
| 498 | nf_net_netfilter_sysctl_path, table); | ||
| 499 | if (!net->ct.sysctl_header) | 493 | if (!net->ct.sysctl_header) |
| 500 | goto out_unregister_netfilter; | 494 | goto out_unregister_netfilter; |
| 501 | 495 | ||
diff --git a/net/netfilter/nf_conntrack_timestamp.c b/net/netfilter/nf_conntrack_timestamp.c index e8d27afbbdb9..dbb364f62d6f 100644 --- a/net/netfilter/nf_conntrack_timestamp.c +++ b/net/netfilter/nf_conntrack_timestamp.c | |||
| @@ -51,8 +51,8 @@ static int nf_conntrack_tstamp_init_sysctl(struct net *net) | |||
| 51 | 51 | ||
| 52 | table[0].data = &net->ct.sysctl_tstamp; | 52 | table[0].data = &net->ct.sysctl_tstamp; |
| 53 | 53 | ||
| 54 | net->ct.tstamp_sysctl_header = register_net_sysctl_table(net, | 54 | net->ct.tstamp_sysctl_header = register_net_sysctl(net, "net/netfilter", |
| 55 | nf_net_netfilter_sysctl_path, table); | 55 | table); |
| 56 | if (!net->ct.tstamp_sysctl_header) { | 56 | if (!net->ct.tstamp_sysctl_header) { |
| 57 | printk(KERN_ERR "nf_ct_tstamp: can't register to sysctl.\n"); | 57 | printk(KERN_ERR "nf_ct_tstamp: can't register to sysctl.\n"); |
| 58 | goto out_register; | 58 | goto out_register; |
diff --git a/net/netfilter/nf_log.c b/net/netfilter/nf_log.c index 04fca48d901a..703fb26aa48d 100644 --- a/net/netfilter/nf_log.c +++ b/net/netfilter/nf_log.c | |||
| @@ -214,13 +214,6 @@ static const struct file_operations nflog_file_ops = { | |||
| 214 | #endif /* PROC_FS */ | 214 | #endif /* PROC_FS */ |
| 215 | 215 | ||
| 216 | #ifdef CONFIG_SYSCTL | 216 | #ifdef CONFIG_SYSCTL |
| 217 | static struct ctl_path nf_log_sysctl_path[] = { | ||
| 218 | { .procname = "net", }, | ||
| 219 | { .procname = "netfilter", }, | ||
| 220 | { .procname = "nf_log", }, | ||
| 221 | { } | ||
| 222 | }; | ||
| 223 | |||
| 224 | static char nf_log_sysctl_fnames[NFPROTO_NUMPROTO-NFPROTO_UNSPEC][3]; | 217 | static char nf_log_sysctl_fnames[NFPROTO_NUMPROTO-NFPROTO_UNSPEC][3]; |
| 225 | static struct ctl_table nf_log_sysctl_table[NFPROTO_NUMPROTO+1]; | 218 | static struct ctl_table nf_log_sysctl_table[NFPROTO_NUMPROTO+1]; |
| 226 | static struct ctl_table_header *nf_log_dir_header; | 219 | static struct ctl_table_header *nf_log_dir_header; |
| @@ -283,7 +276,7 @@ static __init int netfilter_log_sysctl_init(void) | |||
| 283 | nf_log_sysctl_table[i].extra1 = (void *)(unsigned long) i; | 276 | nf_log_sysctl_table[i].extra1 = (void *)(unsigned long) i; |
| 284 | } | 277 | } |
| 285 | 278 | ||
| 286 | nf_log_dir_header = register_net_sysctl_table(&init_net, nf_log_sysctl_path, | 279 | nf_log_dir_header = register_net_sysctl(&init_net, "net/netfilter/nf_log", |
| 287 | nf_log_sysctl_table); | 280 | nf_log_sysctl_table); |
| 288 | if (!nf_log_dir_header) | 281 | if (!nf_log_dir_header) |
| 289 | return -ENOMEM; | 282 | return -ENOMEM; |
diff --git a/net/netrom/sysctl_net_netrom.c b/net/netrom/sysctl_net_netrom.c index 4ed149e265bf..42f630b9a698 100644 --- a/net/netrom/sysctl_net_netrom.c +++ b/net/netrom/sysctl_net_netrom.c | |||
| @@ -146,15 +146,9 @@ static ctl_table nr_table[] = { | |||
| 146 | { } | 146 | { } |
| 147 | }; | 147 | }; |
| 148 | 148 | ||
| 149 | static struct ctl_path nr_path[] = { | ||
| 150 | { .procname = "net", }, | ||
| 151 | { .procname = "netrom", }, | ||
| 152 | { } | ||
| 153 | }; | ||
| 154 | |||
| 155 | void __init nr_register_sysctl(void) | 149 | void __init nr_register_sysctl(void) |
| 156 | { | 150 | { |
| 157 | nr_table_header = register_net_sysctl_table(&init_net, nr_path, nr_table); | 151 | nr_table_header = register_net_sysctl(&init_net, "net/netrom", nr_table); |
| 158 | } | 152 | } |
| 159 | 153 | ||
| 160 | void nr_unregister_sysctl(void) | 154 | void nr_unregister_sysctl(void) |
diff --git a/net/phonet/sysctl.c b/net/phonet/sysctl.c index aa55db5f383b..696348fd31a1 100644 --- a/net/phonet/sysctl.c +++ b/net/phonet/sysctl.c | |||
| @@ -98,15 +98,9 @@ static struct ctl_table phonet_table[] = { | |||
| 98 | { } | 98 | { } |
| 99 | }; | 99 | }; |
| 100 | 100 | ||
| 101 | static struct ctl_path phonet_ctl_path[] = { | ||
| 102 | { .procname = "net", }, | ||
| 103 | { .procname = "phonet", }, | ||
| 104 | { }, | ||
| 105 | }; | ||
| 106 | |||
| 107 | int __init phonet_sysctl_init(void) | 101 | int __init phonet_sysctl_init(void) |
| 108 | { | 102 | { |
| 109 | phonet_table_hrd = register_net_sysctl_table(&init_net, phonet_ctl_path, phonet_table); | 103 | phonet_table_hrd = register_net_sysctl(&init_net, "net/phonet", phonet_table); |
| 110 | return phonet_table_hrd == NULL ? -ENOMEM : 0; | 104 | return phonet_table_hrd == NULL ? -ENOMEM : 0; |
| 111 | } | 105 | } |
| 112 | 106 | ||
diff --git a/net/rds/ib_sysctl.c b/net/rds/ib_sysctl.c index 0fef3e15777b..7e643bafb4af 100644 --- a/net/rds/ib_sysctl.c +++ b/net/rds/ib_sysctl.c | |||
| @@ -106,13 +106,6 @@ static ctl_table rds_ib_sysctl_table[] = { | |||
| 106 | { } | 106 | { } |
| 107 | }; | 107 | }; |
| 108 | 108 | ||
| 109 | static struct ctl_path rds_ib_sysctl_path[] = { | ||
| 110 | { .procname = "net", }, | ||
| 111 | { .procname = "rds", }, | ||
| 112 | { .procname = "ib", }, | ||
| 113 | { } | ||
| 114 | }; | ||
| 115 | |||
| 116 | void rds_ib_sysctl_exit(void) | 109 | void rds_ib_sysctl_exit(void) |
| 117 | { | 110 | { |
| 118 | if (rds_ib_sysctl_hdr) | 111 | if (rds_ib_sysctl_hdr) |
| @@ -121,7 +114,7 @@ void rds_ib_sysctl_exit(void) | |||
| 121 | 114 | ||
| 122 | int rds_ib_sysctl_init(void) | 115 | int rds_ib_sysctl_init(void) |
| 123 | { | 116 | { |
| 124 | rds_ib_sysctl_hdr = register_net_sysctl_table(&init_net, rds_ib_sysctl_path, rds_ib_sysctl_table); | 117 | rds_ib_sysctl_hdr = register_net_sysctl(&init_net, "net/rds/ib", rds_ib_sysctl_table); |
| 125 | if (!rds_ib_sysctl_hdr) | 118 | if (!rds_ib_sysctl_hdr) |
| 126 | return -ENOMEM; | 119 | return -ENOMEM; |
| 127 | return 0; | 120 | return 0; |
diff --git a/net/rds/iw_sysctl.c b/net/rds/iw_sysctl.c index bcfe36dc55a7..5d5ebd576f3f 100644 --- a/net/rds/iw_sysctl.c +++ b/net/rds/iw_sysctl.c | |||
| @@ -109,13 +109,6 @@ static ctl_table rds_iw_sysctl_table[] = { | |||
| 109 | { } | 109 | { } |
| 110 | }; | 110 | }; |
| 111 | 111 | ||
| 112 | static struct ctl_path rds_iw_sysctl_path[] = { | ||
| 113 | { .procname = "net", }, | ||
| 114 | { .procname = "rds", }, | ||
| 115 | { .procname = "iw", }, | ||
| 116 | { } | ||
| 117 | }; | ||
| 118 | |||
| 119 | void rds_iw_sysctl_exit(void) | 112 | void rds_iw_sysctl_exit(void) |
| 120 | { | 113 | { |
| 121 | if (rds_iw_sysctl_hdr) | 114 | if (rds_iw_sysctl_hdr) |
| @@ -124,7 +117,7 @@ void rds_iw_sysctl_exit(void) | |||
| 124 | 117 | ||
| 125 | int rds_iw_sysctl_init(void) | 118 | int rds_iw_sysctl_init(void) |
| 126 | { | 119 | { |
| 127 | rds_iw_sysctl_hdr = register_net_sysctl_table(&init_net, rds_iw_sysctl_path, rds_iw_sysctl_table); | 120 | rds_iw_sysctl_hdr = register_net_sysctl(&init_net, "net/rds/iw", rds_iw_sysctl_table); |
| 128 | if (!rds_iw_sysctl_hdr) | 121 | if (!rds_iw_sysctl_hdr) |
| 129 | return -ENOMEM; | 122 | return -ENOMEM; |
| 130 | return 0; | 123 | return 0; |
diff --git a/net/rds/sysctl.c b/net/rds/sysctl.c index 30354b8cd584..907214b4c4d0 100644 --- a/net/rds/sysctl.c +++ b/net/rds/sysctl.c | |||
| @@ -92,13 +92,6 @@ static ctl_table rds_sysctl_rds_table[] = { | |||
| 92 | { } | 92 | { } |
| 93 | }; | 93 | }; |
| 94 | 94 | ||
| 95 | static struct ctl_path rds_sysctl_path[] = { | ||
| 96 | { .procname = "net", }, | ||
| 97 | { .procname = "rds", }, | ||
| 98 | { } | ||
| 99 | }; | ||
| 100 | |||
| 101 | |||
| 102 | void rds_sysctl_exit(void) | 95 | void rds_sysctl_exit(void) |
| 103 | { | 96 | { |
| 104 | if (rds_sysctl_reg_table) | 97 | if (rds_sysctl_reg_table) |
| @@ -110,7 +103,7 @@ int rds_sysctl_init(void) | |||
| 110 | rds_sysctl_reconnect_min = msecs_to_jiffies(1); | 103 | rds_sysctl_reconnect_min = msecs_to_jiffies(1); |
| 111 | rds_sysctl_reconnect_min_jiffies = rds_sysctl_reconnect_min; | 104 | rds_sysctl_reconnect_min_jiffies = rds_sysctl_reconnect_min; |
| 112 | 105 | ||
| 113 | rds_sysctl_reg_table = register_net_sysctl_table(&init_net, rds_sysctl_path, rds_sysctl_rds_table); | 106 | rds_sysctl_reg_table = register_net_sysctl(&init_net,"net/rds", rds_sysctl_rds_table); |
| 114 | if (!rds_sysctl_reg_table) | 107 | if (!rds_sysctl_reg_table) |
| 115 | return -ENOMEM; | 108 | return -ENOMEM; |
| 116 | return 0; | 109 | return 0; |
diff --git a/net/rose/sysctl_net_rose.c b/net/rose/sysctl_net_rose.c index 02b73979535b..94ca9c2ccd69 100644 --- a/net/rose/sysctl_net_rose.c +++ b/net/rose/sysctl_net_rose.c | |||
| @@ -118,15 +118,9 @@ static ctl_table rose_table[] = { | |||
| 118 | { } | 118 | { } |
| 119 | }; | 119 | }; |
| 120 | 120 | ||
| 121 | static struct ctl_path rose_path[] = { | ||
| 122 | { .procname = "net", }, | ||
| 123 | { .procname = "rose", }, | ||
| 124 | { } | ||
| 125 | }; | ||
| 126 | |||
| 127 | void __init rose_register_sysctl(void) | 121 | void __init rose_register_sysctl(void) |
| 128 | { | 122 | { |
| 129 | rose_table_header = register_net_sysctl_table(&init_net, rose_path, rose_table); | 123 | rose_table_header = register_net_sysctl(&init_net, "net/rose", rose_table); |
| 130 | } | 124 | } |
| 131 | 125 | ||
| 132 | void rose_unregister_sysctl(void) | 126 | void rose_unregister_sysctl(void) |
diff --git a/net/sctp/sysctl.c b/net/sctp/sysctl.c index 1e385b452047..e5fe639c89e7 100644 --- a/net/sctp/sysctl.c +++ b/net/sctp/sysctl.c | |||
| @@ -275,18 +275,12 @@ static ctl_table sctp_table[] = { | |||
| 275 | { /* sentinel */ } | 275 | { /* sentinel */ } |
| 276 | }; | 276 | }; |
| 277 | 277 | ||
| 278 | static struct ctl_path sctp_path[] = { | ||
| 279 | { .procname = "net", }, | ||
| 280 | { .procname = "sctp", }, | ||
| 281 | { } | ||
| 282 | }; | ||
| 283 | |||
| 284 | static struct ctl_table_header * sctp_sysctl_header; | 278 | static struct ctl_table_header * sctp_sysctl_header; |
| 285 | 279 | ||
| 286 | /* Sysctl registration. */ | 280 | /* Sysctl registration. */ |
| 287 | void sctp_sysctl_register(void) | 281 | void sctp_sysctl_register(void) |
| 288 | { | 282 | { |
| 289 | sctp_sysctl_header = register_net_sysctl_table(&init_net, sctp_path, sctp_table); | 283 | sctp_sysctl_header = register_net_sysctl(&init_net, "net/sctp", sctp_table); |
| 290 | } | 284 | } |
| 291 | 285 | ||
| 292 | /* Sysctl deregistration. */ | 286 | /* Sysctl deregistration. */ |
diff --git a/net/unix/sysctl_net_unix.c b/net/unix/sysctl_net_unix.c index 4f6979c06f84..b34b5b9792f0 100644 --- a/net/unix/sysctl_net_unix.c +++ b/net/unix/sysctl_net_unix.c | |||
| @@ -26,12 +26,6 @@ static ctl_table unix_table[] = { | |||
| 26 | { } | 26 | { } |
| 27 | }; | 27 | }; |
| 28 | 28 | ||
| 29 | static struct ctl_path unix_path[] = { | ||
| 30 | { .procname = "net", }, | ||
| 31 | { .procname = "unix", }, | ||
| 32 | { }, | ||
| 33 | }; | ||
| 34 | |||
| 35 | int __net_init unix_sysctl_register(struct net *net) | 29 | int __net_init unix_sysctl_register(struct net *net) |
| 36 | { | 30 | { |
| 37 | struct ctl_table *table; | 31 | struct ctl_table *table; |
| @@ -41,7 +35,7 @@ int __net_init unix_sysctl_register(struct net *net) | |||
| 41 | goto err_alloc; | 35 | goto err_alloc; |
| 42 | 36 | ||
| 43 | table[0].data = &net->unx.sysctl_max_dgram_qlen; | 37 | table[0].data = &net->unx.sysctl_max_dgram_qlen; |
| 44 | net->unx.ctl = register_net_sysctl_table(net, unix_path, table); | 38 | net->unx.ctl = register_net_sysctl(net, "net/unix", table); |
| 45 | if (net->unx.ctl == NULL) | 39 | if (net->unx.ctl == NULL) |
| 46 | goto err_reg; | 40 | goto err_reg; |
| 47 | 41 | ||
diff --git a/net/x25/sysctl_net_x25.c b/net/x25/sysctl_net_x25.c index 08337cb488d4..43239527a205 100644 --- a/net/x25/sysctl_net_x25.c +++ b/net/x25/sysctl_net_x25.c | |||
| @@ -73,15 +73,9 @@ static struct ctl_table x25_table[] = { | |||
| 73 | { 0, }, | 73 | { 0, }, |
| 74 | }; | 74 | }; |
| 75 | 75 | ||
| 76 | static struct ctl_path x25_path[] = { | ||
| 77 | { .procname = "net", }, | ||
| 78 | { .procname = "x25", }, | ||
| 79 | { } | ||
| 80 | }; | ||
| 81 | |||
| 82 | void __init x25_register_sysctl(void) | 76 | void __init x25_register_sysctl(void) |
| 83 | { | 77 | { |
| 84 | x25_table_header = register_net_sysctl_table(&init_net, x25_path, x25_table); | 78 | x25_table_header = register_net_sysctl(&init_net, "net/x25", x25_table); |
| 85 | } | 79 | } |
| 86 | 80 | ||
| 87 | void x25_unregister_sysctl(void) | 81 | void x25_unregister_sysctl(void) |
diff --git a/net/xfrm/xfrm_sysctl.c b/net/xfrm/xfrm_sysctl.c index 05640bc9594b..380976f74c4c 100644 --- a/net/xfrm/xfrm_sysctl.c +++ b/net/xfrm/xfrm_sysctl.c | |||
| @@ -54,7 +54,7 @@ int __net_init xfrm_sysctl_init(struct net *net) | |||
| 54 | table[2].data = &net->xfrm.sysctl_larval_drop; | 54 | table[2].data = &net->xfrm.sysctl_larval_drop; |
| 55 | table[3].data = &net->xfrm.sysctl_acq_expires; | 55 | table[3].data = &net->xfrm.sysctl_acq_expires; |
| 56 | 56 | ||
| 57 | net->xfrm.sysctl_hdr = register_net_sysctl_table(net, net_core_path, table); | 57 | net->xfrm.sysctl_hdr = register_net_sysctl(net, "net/core", table); |
| 58 | if (!net->xfrm.sysctl_hdr) | 58 | if (!net->xfrm.sysctl_hdr) |
| 59 | goto out_register; | 59 | goto out_register; |
| 60 | return 0; | 60 | return 0; |
