From f969d69ba9f952e5bdd38278e25e26a3e4a61a70 Mon Sep 17 00:00:00 2001 From: Ralf Baechle Date: Sat, 29 Jan 2000 01:41:54 +0000 Subject: Merge with 2.3.27. --- net/ipv6/README | 2 +- net/ipv6/addrconf.c | 11 ++-------- net/ipv6/af_inet6.c | 53 +++++++++--------------------------------------- net/ipv6/ip6_flowlabel.c | 7 +------ net/ipv6/mcast.c | 6 +----- net/ipv6/ndisc.c | 12 ++--------- net/ipv6/route.c | 21 ++++--------------- 7 files changed, 21 insertions(+), 91 deletions(-) (limited to 'net/ipv6') diff --git a/net/ipv6/README b/net/ipv6/README index ca82fe438..a3f3f575a 100644 --- a/net/ipv6/README +++ b/net/ipv6/README @@ -1,6 +1,6 @@ To join in the work on Linux IPv6 send mail to: - majordomo@nuclecu.unam.mx + majordomo@oss.sgi.com and in the body of the message include: diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index c57c99a35..157fe6c4e 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c @@ -1590,13 +1590,6 @@ done: return len; } -struct proc_dir_entry iface_proc_entry = -{ - 0, 8, "if_inet6", - S_IFREG | S_IRUGO, 1, 0, 0, - 0, NULL, - &iface_proc_info -}; #endif /* CONFIG_PROC_FS */ /* @@ -2008,7 +2001,7 @@ void __init addrconf_init(void) #endif #ifdef CONFIG_PROC_FS - proc_net_register(&iface_proc_entry); + proc_net_create("if_inet6", 0, iface_proc_info); #endif addr_chk_timer.expires = jiffies + ADDR_CHECK_FREQUENCY; @@ -2075,7 +2068,7 @@ void addrconf_cleanup(void) rtnl_unlock(); #ifdef CONFIG_PROC_FS - proc_net_unregister(iface_proc_entry.low_ino); + proc_net_remove("if_inet6"); #endif } #endif /* MODULE */ diff --git a/net/ipv6/af_inet6.c b/net/ipv6/af_inet6.c index 72012bc59..1e056d2ea 100644 --- a/net/ipv6/af_inet6.c +++ b/net/ipv6/af_inet6.c @@ -459,39 +459,6 @@ struct net_proto_family inet6_family_ops = { inet6_create }; -#ifdef CONFIG_PROC_FS -static struct proc_dir_entry proc_net_raw6 = { - PROC_NET_RAW6, 4, "raw6", - S_IFREG | S_IRUGO, 1, 0, 0, - 0, &proc_net_inode_operations, - raw6_get_info -}; -static struct proc_dir_entry proc_net_tcp6 = { - PROC_NET_TCP6, 4, "tcp6", - S_IFREG | S_IRUGO, 1, 0, 0, - 0, &proc_net_inode_operations, - tcp6_get_info -}; -static struct proc_dir_entry proc_net_udp6 = { - PROC_NET_RAW6, 4, "udp6", - S_IFREG | S_IRUGO, 1, 0, 0, - 0, &proc_net_inode_operations, - udp6_get_info -}; -static struct proc_dir_entry proc_net_sockstat6 = { - PROC_NET_SOCKSTAT6, 9, "sockstat6", - S_IFREG | S_IRUGO, 1, 0, 0, - 0, &proc_net_inode_operations, - afinet6_get_info -}; -static struct proc_dir_entry proc_net_snmp6 = { - PROC_NET_SNMP6, 5, "snmp6", - S_IFREG | S_IRUGO, 1, 0, 0, - 0, &proc_net_inode_operations, - afinet6_get_snmp -}; -#endif /* CONFIG_PROC_FS */ - #ifdef MODULE int ipv6_unload(void) { @@ -566,11 +533,11 @@ void __init inet6_proto_init(struct net_proto *pro) /* Create /proc/foo6 entries. */ #ifdef CONFIG_PROC_FS - proc_net_register(&proc_net_raw6); - proc_net_register(&proc_net_tcp6); - proc_net_register(&proc_net_udp6); - proc_net_register(&proc_net_sockstat6); - proc_net_register(&proc_net_snmp6); + proc_net_create("raw6", 0, raw6_get_info); + proc_net_create("tcp6", 0, tcp6_get_info); + proc_net_create("udp6", 0, udp6_get_info); + proc_net_create("sockstat6", 0, afinet6_get_info); + proc_net_create("snmp6", 0, afinet6_get_snmp); #endif /* Now the userspace is allowed to create INET6 sockets. */ @@ -603,11 +570,11 @@ void cleanup_module(void) /* First of all disallow new sockets creation. */ sock_unregister(PF_INET6); #ifdef CONFIG_PROC_FS - proc_net_unregister(proc_net_raw6.low_ino); - proc_net_unregister(proc_net_tcp6.low_ino); - proc_net_unregister(proc_net_udp6.low_ino); - proc_net_unregister(proc_net_sockstat6.low_ino); - proc_net_unregister(proc_net_snmp6.low_ino); + proc_net_remove("raw6"); + proc_net_remove("tcp6"); + proc_net_remove("udp6"); + proc_net_remove("sockstat6"); + proc_net_remove("snmp6"); #endif /* Cleanup code parts. */ sit_cleanup(); diff --git a/net/ipv6/ip6_flowlabel.c b/net/ipv6/ip6_flowlabel.c index cba690104..4dd29b60e 100644 --- a/net/ipv6/ip6_flowlabel.c +++ b/net/ipv6/ip6_flowlabel.c @@ -606,15 +606,10 @@ done: void ip6_flowlabel_init() { -#ifdef CONFIG_PROC_FS - struct proc_dir_entry *ent; -#endif - init_timer(&ip6_fl_gc_timer); ip6_fl_gc_timer.function = ip6_fl_gc; #ifdef CONFIG_PROC_FS - ent = create_proc_entry("net/ip6_flowlabel", 0, 0); - ent->read_proc = ip6_fl_read_proc; + create_proc_read_entry("net/ip6_flowlabel", 0, 0, ip6_fl_read_proc, NULL); #endif } diff --git a/net/ipv6/mcast.c b/net/ipv6/mcast.c index 324c37e9d..1abc90346 100644 --- a/net/ipv6/mcast.c +++ b/net/ipv6/mcast.c @@ -707,9 +707,6 @@ done: int __init igmp6_init(struct net_proto_family *ops) { -#ifdef CONFIG_PROC_FS - struct proc_dir_entry *ent; -#endif struct sock *sk; int err; @@ -738,8 +735,7 @@ int __init igmp6_init(struct net_proto_family *ops) sk->net_pinfo.af_inet6.hop_limit = 1; #ifdef CONFIG_PROC_FS - ent = create_proc_entry("net/igmp6", 0, 0); - ent->read_proc = igmp6_read_proc; + create_proc_read_entry("net/igmp6", 0, 0, igmp6_read_proc, NULL); #endif return 0; diff --git a/net/ipv6/ndisc.c b/net/ipv6/ndisc.c index 47b6c2c2c..dab819da8 100644 --- a/net/ipv6/ndisc.c +++ b/net/ipv6/ndisc.c @@ -1179,18 +1179,10 @@ done: return len; } -struct proc_dir_entry ndisc_proc_entry = -{ - PROC_NET_NDISC, 5, "ndisc", - S_IFREG | S_IRUGO, 1, 0, 0, - 0, NULL, - &ndisc_get_info -}; #endif #endif /* CONFIG_PROC_FS */ - int __init ndisc_init(struct net_proto_family *ops) { struct sock *sk; @@ -1230,7 +1222,7 @@ int __init ndisc_init(struct net_proto_family *ops) #ifdef CONFIG_PROC_FS #ifndef CONFIG_RTNETLINK - proc_net_register(&ndisc_proc_entry); + proc_net_create("ndisc", 0, ndisc_get_info); #endif #endif #ifdef CONFIG_SYSCTL @@ -1244,7 +1236,7 @@ void ndisc_cleanup(void) { #ifdef CONFIG_PROC_FS #ifndef CONFIG_RTNETLINK - proc_net_unregister(ndisc_proc_entry.low_ino); + proc_net_remove("ndisc"); #endif #endif neigh_table_clear(&nd_tbl); diff --git a/net/ipv6/route.c b/net/ipv6/route.c index 8a187184b..431ef0c85 100644 --- a/net/ipv6/route.c +++ b/net/ipv6/route.c @@ -1861,19 +1861,6 @@ static int rt6_proc_stats(char *buffer, char **start, off_t offset, int length, return len; } - -static struct proc_dir_entry proc_rt6_info = { - PROC_NET_RT6, 10, "ipv6_route", - S_IFREG | S_IRUGO, 1, 0, 0, - 0, &proc_net_inode_operations, - rt6_proc_info -}; -static struct proc_dir_entry proc_rt6_stats = { - PROC_NET_RT6_STATS, 9, "rt6_stats", - S_IFREG | S_IRUGO, 1, 0, 0, - 0, &proc_net_inode_operations, - rt6_proc_stats -}; #endif /* CONFIG_PROC_FS */ #ifdef CONFIG_SYSCTL @@ -1936,8 +1923,8 @@ void __init ip6_route_init(void) NULL, NULL); fib6_init(); #ifdef CONFIG_PROC_FS - proc_net_register(&proc_rt6_info); - proc_net_register(&proc_rt6_stats); + proc_net_create("ipv6_route", 0, rt6_proc_info); + proc_net_create("rt6_stats", 0, rt6_proc_stats); #endif } @@ -1945,8 +1932,8 @@ void __init ip6_route_init(void) void ip6_route_cleanup(void) { #ifdef CONFIG_PROC_FS - proc_net_unregister(PROC_NET_RT6); - proc_net_unregister(PROC_NET_RT6_STATS); + proc_net_remove("ipv6_route"); + proc_net_remove("rt6_stats"); #endif rt6_ifdown(NULL); -- cgit v1.2.3