aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/sysctl_net_ipv4.c
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2012-04-19 09:44:49 -0400
committerDavid S. Miller <davem@davemloft.net>2012-04-20 21:22:30 -0400
commitec8f23ce0f4005b74013d4d122e0d540397a93c9 (patch)
treec2f22aa08ad4c0197d3cb41b91cf8d436794fde1 /net/ipv4/sysctl_net_ipv4.c
parentf99e8f715a5c7ebad5410b1e9b4d744ddb284f54 (diff)
net: Convert all sysctl registrations to register_net_sysctl
This results in code with less boiler plate that is a bit easier to read. Additionally stops us from using compatibility code in the sysctl core, hastening the day when the compatibility code can be removed. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Acked-by: Pavel Emelyanov <xemul@parallels.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/sysctl_net_ipv4.c')
-rw-r--r--net/ipv4/sysctl_net_ipv4.c5
1 files changed, 2 insertions, 3 deletions
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