Browse Source

net: proc: change proc_net_remove to remove_proc_entry

proc_net_remove is only used to remove proc entries
that under /proc/net,it's not a general function for
removing proc entries of netns. if we want to remove
some proc entries which under /proc/net/stat/, we still
need to call remove_proc_entry.

this patch use remove_proc_entry to replace proc_net_remove.
we can remove proc_net_remove after this patch.

Signed-off-by: Gao feng <gaofeng@cn.fujitsu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
imx_3.10.17_1.0.0_ga
Gao feng 8 years ago
committed by David S. Miller
parent
commit
ece31ffd53
60 changed files with 112 additions and 112 deletions
  1. +1
    -1
      drivers/connector/connector.c
  2. +1
    -1
      drivers/net/hamradio/bpqether.c
  3. +1
    -1
      drivers/net/hamradio/scc.c
  4. +1
    -1
      drivers/net/hamradio/yam.c
  5. +1
    -1
      drivers/net/ppp/pppoe.c
  6. +1
    -1
      net/8021q/vlanproc.c
  7. +1
    -1
      net/atm/proc.c
  8. +3
    -3
      net/ax25/af_ax25.c
  9. +1
    -1
      net/bluetooth/af_bluetooth.c
  10. +1
    -1
      net/can/bcm.c
  11. +1
    -1
      net/can/proc.c
  12. +6
    -6
      net/core/dev.c
  13. +1
    -1
      net/core/dev_addr_lists.c
  14. +2
    -2
      net/core/pktgen.c
  15. +1
    -1
      net/core/sock.c
  16. +2
    -2
      net/dccp/probe.c
  17. +1
    -1
      net/decnet/af_decnet.c
  18. +1
    -1
      net/decnet/dn_dev.c
  19. +1
    -1
      net/decnet/dn_neigh.c
  20. +1
    -1
      net/decnet/dn_route.c
  21. +1
    -1
      net/ipv4/arp.c
  22. +5
    -5
      net/ipv4/fib_trie.c
  23. +3
    -3
      net/ipv4/igmp.c
  24. +3
    -3
      net/ipv4/ipmr.c
  25. +4
    -4
      net/ipv4/netfilter/nf_conntrack_l3proto_ipv4_compat.c
  26. +1
    -1
      net/ipv4/ping.c
  27. +5
    -5
      net/ipv4/proc.c
  28. +1
    -1
      net/ipv4/raw.c
  29. +1
    -1
      net/ipv4/tcp_ipv4.c
  30. +2
    -2
      net/ipv4/tcp_probe.c
  31. +1
    -1
      net/ipv4/udp.c
  32. +1
    -1
      net/ipv6/addrconf.c
  33. +1
    -1
      net/ipv6/anycast.c
  34. +1
    -1
      net/ipv6/ip6_flowlabel.c
  35. +3
    -3
      net/ipv6/ip6mr.c
  36. +3
    -3
      net/ipv6/mcast.c
  37. +5
    -5
      net/ipv6/proc.c
  38. +1
    -1
      net/ipv6/raw.c
  39. +2
    -2
      net/ipv6/route.c
  40. +1
    -1
      net/key/af_key.c
  41. +1
    -1
      net/l2tp/l2tp_ppp.c
  42. +1
    -1
      net/netfilter/ipvs/ip_vs_app.c
  43. +2
    -2
      net/netfilter/ipvs/ip_vs_conn.c
  44. +3
    -3
      net/netfilter/ipvs/ip_vs_ctl.c
  45. +1
    -1
      net/netfilter/nf_conntrack_expect.c
  46. +2
    -2
      net/netfilter/nf_conntrack_standalone.c
  47. +5
    -5
      net/netfilter/x_tables.c
  48. +3
    -3
      net/netfilter/xt_hashlimit.c
  49. +1
    -1
      net/netfilter/xt_recent.c
  50. +1
    -1
      net/netlink/af_netlink.c
  51. +3
    -3
      net/netrom/af_netrom.c
  52. +1
    -1
      net/packet/af_packet.c
  53. +2
    -2
      net/phonet/pn_dev.c
  54. +4
    -4
      net/rose/af_rose.c
  55. +2
    -2
      net/rxrpc/af_rxrpc.c
  56. +1
    -1
      net/sched/sch_api.c
  57. +2
    -2
      net/sctp/probe.c
  58. +1
    -1
      net/unix/af_unix.c
  59. +1
    -1
      net/wireless/wext-proc.c
  60. +1
    -1
      net/xfrm/xfrm_proc.c

+ 1
- 1
drivers/connector/connector.c View File

@ -287,7 +287,7 @@ static void cn_fini(void)
cn_already_initialized = 0;
proc_net_remove(&init_net, "connector");
remove_proc_entry("connector", init_net.proc_net);
cn_queue_free_dev(dev->cbdev);
netlink_kernel_release(dev->nls);


+ 1
- 1
drivers/net/hamradio/bpqether.c View File

@ -611,7 +611,7 @@ static void __exit bpq_cleanup_driver(void)
unregister_netdevice_notifier(&bpq_dev_notifier);
proc_net_remove(&init_net, "bpqether");
remove_proc_entry("bpqether", init_net.proc_net);
rtnl_lock();
while (!list_empty(&bpq_devices)) {


+ 1
- 1
drivers/net/hamradio/scc.c View File

@ -2173,7 +2173,7 @@ static void __exit scc_cleanup_driver(void)
if (Vector_Latch)
release_region(Vector_Latch, 1);
proc_net_remove(&init_net, "z8530drv");
remove_proc_entry("z8530drv", init_net.proc_net);
}
MODULE_AUTHOR("Joerg Reuter <jreuter@yaina.de>");


+ 1
- 1
drivers/net/hamradio/yam.c View File

@ -1199,7 +1199,7 @@ static void __exit yam_cleanup_driver(void)
kfree(p);
}
proc_net_remove(&init_net, "yam");
remove_proc_entry("yam", init_net.proc_net);
}
/* --------------------------------------------------------------------- */


+ 1
- 1
drivers/net/ppp/pppoe.c View File

@ -1145,7 +1145,7 @@ static __net_init int pppoe_init_net(struct net *net)
static __net_exit void pppoe_exit_net(struct net *net)
{
proc_net_remove(net, "pppoe");
remove_proc_entry("pppoe", net->proc_net);
}
static struct pernet_operations pppoe_net_ops = {


+ 1
- 1
net/8021q/vlanproc.c View File

@ -131,7 +131,7 @@ void vlan_proc_cleanup(struct net *net)
remove_proc_entry(name_conf, vn->proc_vlan_dir);
if (vn->proc_vlan_dir)
proc_net_remove(net, name_root);
remove_proc_entry(name_root, net->proc_net);
/* Dynamically added entries should be cleaned up as their vlan_device
* is removed, so we should not have to take care of it here...


+ 1
- 1
net/atm/proc.c View File

@ -460,7 +460,7 @@ static void atm_proc_dirs_remove(void)
if (e->dirent)
remove_proc_entry(e->name, atm_proc_root);
}
proc_net_remove(&init_net, "atm");
remove_proc_entry("atm", init_net.proc_net);
}
int __init atm_proc_init(void)


+ 3
- 3
net/ax25/af_ax25.c View File

@ -2009,9 +2009,9 @@ MODULE_ALIAS_NETPROTO(PF_AX25);
static void __exit ax25_exit(void)
{
proc_net_remove(&init_net, "ax25_route");
proc_net_remove(&init_net, "ax25");
proc_net_remove(&init_net, "ax25_calls");
remove_proc_entry("ax25_route", init_net.proc_net);
remove_proc_entry("ax25", init_net.proc_net);
remove_proc_entry("ax25_calls", init_net.proc_net);
unregister_netdevice_notifier(&ax25_dev_notifier);


+ 1
- 1
net/bluetooth/af_bluetooth.c View File

@ -652,7 +652,7 @@ int bt_procfs_init(struct module* module, struct net *net, const char *name,
void bt_procfs_cleanup(struct net *net, const char *name)
{
proc_net_remove(net, name);
remove_proc_entry(name, net->proc_net);
}
#else
int bt_procfs_init(struct module* module, struct net *net, const char *name,


+ 1
- 1
net/can/bcm.c View File

@ -1633,7 +1633,7 @@ static void __exit bcm_module_exit(void)
can_proto_unregister(&bcm_can_proto);
if (proc_dir)
proc_net_remove(&init_net, "can-bcm");
remove_proc_entry("can-bcm", init_net.proc_net);
}
module_init(bcm_module_init);


+ 1
- 1
net/can/proc.c View File

@ -531,5 +531,5 @@ void can_remove_proc(void)
can_remove_proc_readentry(CAN_PROC_RCVLIST_SFF);
if (can_dir)
proc_net_remove(&init_net, "can");
remove_proc_entry("can", init_net.proc_net);
}

+ 6
- 6
net/core/dev.c View File

@ -4532,11 +4532,11 @@ static int __net_init dev_proc_net_init(struct net *net)
out:
return rc;
out_ptype:
proc_net_remove(net, "ptype");
remove_proc_entry("ptype", net->proc_net);
out_softnet:
proc_net_remove(net, "softnet_stat");
remove_proc_entry("softnet_stat", net->proc_net);
out_dev:
proc_net_remove(net, "dev");
remove_proc_entry("dev", net->proc_net);
goto out;
}
@ -4544,9 +4544,9 @@ static void __net_exit dev_proc_net_exit(struct net *net)
{
wext_proc_exit(net);
proc_net_remove(net, "ptype");
proc_net_remove(net, "softnet_stat");
proc_net_remove(net, "dev");
remove_proc_entry("ptype", net->proc_net);
remove_proc_entry("softnet_stat", net->proc_net);
remove_proc_entry("dev", net->proc_net);
}
static struct pernet_operations __net_initdata dev_proc_ops = {


+ 1
- 1
net/core/dev_addr_lists.c View File

@ -787,7 +787,7 @@ static int __net_init dev_mc_net_init(struct net *net)
static void __net_exit dev_mc_net_exit(struct net *net)
{
proc_net_remove(net, "dev_mcast");
remove_proc_entry("dev_mcast", net->proc_net);
}
static struct pernet_operations __net_initdata dev_mc_net_ops = {


+ 2
- 2
net/core/pktgen.c View File

@ -3650,7 +3650,7 @@ static int __net_init pg_net_init(struct net *net)
remove_entry:
remove_proc_entry(PGCTRL, pn->proc_dir);
remove:
proc_net_remove(pn->net, PG_PROC_DIR);
remove_proc_entry(PG_PROC_DIR, pn->net->proc_net);
return ret;
}
@ -3676,7 +3676,7 @@ static void __net_exit pg_net_exit(struct net *net)
}
remove_proc_entry(PGCTRL, pn->proc_dir);
proc_net_remove(pn->net, PG_PROC_DIR);
remove_proc_entry(PG_PROC_DIR, pn->net->proc_net);
}
static struct pernet_operations pg_net_ops = {


+ 1
- 1
net/core/sock.c View File

@ -2844,7 +2844,7 @@ static __net_init int proto_init_net(struct net *net)
static __net_exit void proto_exit_net(struct net *net)
{
proc_net_remove(net, "protocols");
remove_proc_entry("protocols", net->proc_net);
}


+ 2
- 2
net/dccp/probe.c View File

@ -181,7 +181,7 @@ static __init int dccpprobe_init(void)
pr_info("DCCP watch registered (port=%d)\n", port);
return 0;
err1:
proc_net_remove(&init_net, procname);
remove_proc_entry(procname, init_net.proc_net);
err0:
kfifo_free(&dccpw.fifo);
return ret;
@ -191,7 +191,7 @@ module_init(dccpprobe_init);
static __exit void dccpprobe_exit(void)
{
kfifo_free(&dccpw.fifo);
proc_net_remove(&init_net, procname);
remove_proc_entry(procname, init_net.proc_net);
unregister_jprobe(&dccp_send_probe);
}


+ 1
- 1
net/decnet/af_decnet.c View File

@ -2413,7 +2413,7 @@ static void __exit decnet_exit(void)
dn_neigh_cleanup();
dn_fib_cleanup();
proc_net_remove(&init_net, "decnet");
remove_proc_entry("decnet", init_net.proc_net);
proto_unregister(&dn_proto);


+ 1
- 1
net/decnet/dn_dev.c View File

@ -1433,7 +1433,7 @@ void __exit dn_dev_cleanup(void)
}
#endif /* CONFIG_SYSCTL */
proc_net_remove(&init_net, "decnet_dev");
remove_proc_entry("decnet_dev", init_net.proc_net);
dn_dev_devices_off();
}

+ 1
- 1
net/decnet/dn_neigh.c View File

@ -596,6 +596,6 @@ void __init dn_neigh_init(void)
void __exit dn_neigh_cleanup(void)
{
proc_net_remove(&init_net, "decnet_neigh");
remove_proc_entry("decnet_neigh", init_net.proc_net);
neigh_table_clear(&dn_neigh_table);
}

+ 1
- 1
net/decnet/dn_route.c View File

@ -1918,7 +1918,7 @@ void __exit dn_route_cleanup(void)
del_timer(&dn_route_timer);
dn_run_flush(0);
proc_net_remove(&init_net, "decnet_cache");
remove_proc_entry("decnet_cache", init_net.proc_net);
dst_entries_destroy(&dn_dst_ops);
}

+ 1
- 1
net/ipv4/arp.c View File

@ -1412,7 +1412,7 @@ static int __net_init arp_net_init(struct net *net)
static void __net_exit arp_net_exit(struct net *net)
{
proc_net_remove(net, "arp");
remove_proc_entry("arp", net->proc_net);
}
static struct pernet_operations arp_net_ops = {


+ 5
- 5
net/ipv4/fib_trie.c View File

@ -2620,18 +2620,18 @@ int __net_init fib_proc_init(struct net *net)
return 0;
out3:
proc_net_remove(net, "fib_triestat");
remove_proc_entry("fib_triestat", net->proc_net);
out2:
proc_net_remove(net, "fib_trie");
remove_proc_entry("fib_trie", net->proc_net);
out1:
return -ENOMEM;
}
void __net_exit fib_proc_exit(struct net *net)
{
proc_net_remove(net, "fib_trie");
proc_net_remove(net, "fib_triestat");
proc_net_remove(net, "route");
remove_proc_entry("fib_trie", net->proc_net);
remove_proc_entry("fib_triestat", net->proc_net);
remove_proc_entry("route", net->proc_net);
}
#endif /* CONFIG_PROC_FS */

+ 3
- 3
net/ipv4/igmp.c View File

@ -2656,15 +2656,15 @@ static int __net_init igmp_net_init(struct net *net)
return 0;
out_mcfilter:
proc_net_remove(net, "igmp");
remove_proc_entry("igmp", net->proc_net);
out_igmp:
return -ENOMEM;
}
static void __net_exit igmp_net_exit(struct net *net)
{
proc_net_remove(net, "mcfilter");
proc_net_remove(net, "igmp");
remove_proc_entry("mcfilter", net->proc_net);
remove_proc_entry("igmp", net->proc_net);
}
static struct pernet_operations igmp_net_ops = {


+ 3
- 3
net/ipv4/ipmr.c View File

@ -2712,7 +2712,7 @@ static int __net_init ipmr_net_init(struct net *net)
#ifdef CONFIG_PROC_FS
proc_cache_fail:
proc_net_remove(net, "ip_mr_vif");
remove_proc_entry("ip_mr_vif", net->proc_net);
proc_vif_fail:
ipmr_rules_exit(net);
#endif
@ -2723,8 +2723,8 @@ fail:
static void __net_exit ipmr_net_exit(struct net *net)
{
#ifdef CONFIG_PROC_FS
proc_net_remove(net, "ip_mr_cache");
proc_net_remove(net, "ip_mr_vif");
remove_proc_entry("ip_mr_cache", net->proc_net);
remove_proc_entry("ip_mr_vif", net->proc_net);
#endif
ipmr_rules_exit(net);
}


+ 4
- 4
net/ipv4/netfilter/nf_conntrack_l3proto_ipv4_compat.c View File

@ -433,9 +433,9 @@ static int __net_init ip_conntrack_net_init(struct net *net)
return 0;
err3:
proc_net_remove(net, "ip_conntrack_expect");
remove_proc_entry("ip_conntrack_expect", net->proc_net);
err2:
proc_net_remove(net, "ip_conntrack");
remove_proc_entry("ip_conntrack", net->proc_net);
err1:
return -ENOMEM;
}
@ -443,8 +443,8 @@ err1:
static void __net_exit ip_conntrack_net_exit(struct net *net)
{
remove_proc_entry("ip_conntrack", net->proc_net_stat);
proc_net_remove(net, "ip_conntrack_expect");
proc_net_remove(net, "ip_conntrack");
remove_proc_entry("ip_conntrack_expect", net->proc_net);
remove_proc_entry("ip_conntrack", net->proc_net);
}
static struct pernet_operations ip_conntrack_net_ops = {


+ 1
- 1
net/ipv4/ping.c View File

@ -897,7 +897,7 @@ static int ping_proc_register(struct net *net)
static void ping_proc_unregister(struct net *net)
{
proc_net_remove(net, "icmp");
remove_proc_entry("icmp", net->proc_net);
}


+ 5
- 5
net/ipv4/proc.c View File

@ -482,18 +482,18 @@ static __net_init int ip_proc_init_net(struct net *net)
return 0;
out_snmp:
proc_net_remove(net, "netstat");
remove_proc_entry("netstat", net->proc_net);
out_netstat:
proc_net_remove(net, "sockstat");
remove_proc_entry("sockstat", net->proc_net);
out_sockstat:
return -ENOMEM;
}
static __net_exit void ip_proc_exit_net(struct net *net)
{
proc_net_remove(net, "snmp");
proc_net_remove(net, "netstat");
proc_net_remove(net, "sockstat");
remove_proc_entry("snmp", net->proc_net);
remove_proc_entry("netstat", net->proc_net);
remove_proc_entry("sockstat", net->proc_net);
}
static __net_initdata struct pernet_operations ip_proc_ops = {


+ 1
- 1
net/ipv4/raw.c View File

@ -1058,7 +1058,7 @@ static __net_init int raw_init_net(struct net *net)
static __net_exit void raw_exit_net(struct net *net)
{
proc_net_remove(net, "raw");
remove_proc_entry("raw", net->proc_net);
}
static __net_initdata struct pernet_operations raw_net_ops = {


+ 1
- 1
net/ipv4/tcp_ipv4.c View File

@ -2616,7 +2616,7 @@ EXPORT_SYMBOL(tcp_proc_register);
void tcp_proc_unregister(struct net *net, struct tcp_seq_afinfo *afinfo)
{
proc_net_remove(net, afinfo->name);
remove_proc_entry(afinfo->name, net->proc_net);
}
EXPORT_SYMBOL(tcp_proc_unregister);


+ 2
- 2
net/ipv4/tcp_probe.c View File

@ -244,7 +244,7 @@ static __init int tcpprobe_init(void)
pr_info("probe registered (port=%d) bufsize=%u\n", port, bufsize);
return 0;
err1:
proc_net_remove(&init_net, procname);
remove_proc_entry(procname, init_net.proc_net);
err0:
kfree(tcp_probe.log);
return ret;
@ -253,7 +253,7 @@ module_init(tcpprobe_init);
static __exit void tcpprobe_exit(void)
{
proc_net_remove(&init_net, procname);
remove_proc_entry(procname, init_net.proc_net);
unregister_jprobe(&tcp_jprobe);
kfree(tcp_probe.log);
}


+ 1
- 1
net/ipv4/udp.c View File

@ -2122,7 +2122,7 @@ EXPORT_SYMBOL(udp_proc_register);
void udp_proc_unregister(struct net *net, struct udp_seq_afinfo *afinfo)
{
proc_net_remove(net, afinfo->name);
remove_proc_entry(afinfo->name, net->proc_net);
}
EXPORT_SYMBOL(udp_proc_unregister);


+ 1
- 1
net/ipv6/addrconf.c View File

@ -3332,7 +3332,7 @@ static int __net_init if6_proc_net_init(struct net *net)
static void __net_exit if6_proc_net_exit(struct net *net)
{
proc_net_remove(net, "if_inet6");
remove_proc_entry("if_inet6", net->proc_net);
}
static struct pernet_operations if6_proc_net_ops = {


+ 1
- 1
net/ipv6/anycast.c View File

@ -517,7 +517,7 @@ int __net_init ac6_proc_init(struct net *net)
void ac6_proc_exit(struct net *net)
{
proc_net_remove(net, "anycast6");
remove_proc_entry("anycast6", net->proc_net);
}
#endif

+ 1
- 1
net/ipv6/ip6_flowlabel.c View File

@ -814,7 +814,7 @@ static int __net_init ip6_flowlabel_proc_init(struct net *net)
static void __net_exit ip6_flowlabel_proc_fini(struct net *net)
{
proc_net_remove(net, "ip6_flowlabel");
remove_proc_entry("ip6_flowlabel", net->proc_net);
}
#else
static inline int ip6_flowlabel_proc_init(struct net *net)


+ 3
- 3
net/ipv6/ip6mr.c View File

@ -1369,7 +1369,7 @@ static int __net_init ip6mr_net_init(struct net *net)
#ifdef CONFIG_PROC_FS
proc_cache_fail:
proc_net_remove(net, "ip6_mr_vif");
remove_proc_entry("ip6_mr_vif", net->proc_net);
proc_vif_fail:
ip6mr_rules_exit(net);
#endif
@ -1380,8 +1380,8 @@ fail:
static void __net_exit ip6mr_net_exit(struct net *net)
{
#ifdef CONFIG_PROC_FS
proc_net_remove(net, "ip6_mr_cache");
proc_net_remove(net, "ip6_mr_vif");
remove_proc_entry("ip6_mr_cache", net->proc_net);
remove_proc_entry("ip6_mr_vif", net->proc_net);
#endif
ip6mr_rules_exit(net);
}


+ 3
- 3
net/ipv6/mcast.c View File

@ -2610,14 +2610,14 @@ out:
return err;
out_proc_net_igmp6:
proc_net_remove(net, "igmp6");
remove_proc_entry("igmp6", net->proc_net);
goto out;
}
static void __net_exit igmp6_proc_exit(struct net *net)
{
proc_net_remove(net, "mcfilter6");
proc_net_remove(net, "igmp6");
remove_proc_entry("mcfilter6", net->proc_net);
remove_proc_entry("igmp6", net->proc_net);
}
#else
static inline int igmp6_proc_init(struct net *net)


+ 5
- 5
net/ipv6/proc.c View File

@ -308,17 +308,17 @@ static int __net_init ipv6_proc_init_net(struct net *net)
return 0;
proc_dev_snmp6_fail:
proc_net_remove(net, "snmp6");
remove_proc_entry("snmp6", net->proc_net);
proc_snmp6_fail:
proc_net_remove(net, "sockstat6");
remove_proc_entry("sockstat6", net->proc_net);
return -ENOMEM;
}
static void __net_exit ipv6_proc_exit_net(struct net *net)
{
proc_net_remove(net, "sockstat6");
proc_net_remove(net, "dev_snmp6");
proc_net_remove(net, "snmp6");
remove_proc_entry("sockstat6", net->proc_net);
remove_proc_entry("dev_snmp6", net->proc_net);
remove_proc_entry("snmp6", net->proc_net);
}
static struct pernet_operations ipv6_proc_ops = {


+ 1
- 1
net/ipv6/raw.c View File

@ -1300,7 +1300,7 @@ static int __net_init raw6_init_net(struct net *net)
static void __net_exit raw6_exit_net(struct net *net)
{
proc_net_remove(net, "raw6");
remove_proc_entry("raw6", net->proc_net);
}
static struct pernet_operations raw6_net_ops = {


+ 2
- 2
net/ipv6/route.c View File

@ -3004,8 +3004,8 @@ static int __net_init ip6_route_net_init_late(struct net *net)
static void __net_exit ip6_route_net_exit_late(struct net *net)
{
#ifdef CONFIG_PROC_FS
proc_net_remove(net, "ipv6_route");
proc_net_remove(net, "rt6_stats");
remove_proc_entry("ipv6_route", net->proc_net);
remove_proc_entry("rt6_stats", net->proc_net);
#endif
}


+ 1
- 1
net/key/af_key.c View File

@ -3749,7 +3749,7 @@ static int __net_init pfkey_init_proc(struct net *net)
static void __net_exit pfkey_exit_proc(struct net *net)
{
proc_net_remove(net, "pfkey");
remove_proc_entry("pfkey", net->proc_net);
}
#else
static inline int pfkey_init_proc(struct net *net)


+ 1
- 1
net/l2tp/l2tp_ppp.c View File

@ -1796,7 +1796,7 @@ out:
static __net_exit void pppol2tp_exit_net(struct net *net)
{
proc_net_remove(net, "pppol2tp");
remove_proc_entry("pppol2tp", net->proc_net);
}
static struct pernet_operations pppol2tp_net_ops = {


+ 1
- 1
net/netfilter/ipvs/ip_vs_app.c View File

@ -612,5 +612,5 @@ int __net_init ip_vs_app_net_init(struct net *net)
void __net_exit ip_vs_app_net_cleanup(struct net *net)
{
unregister_ip_vs_app(net, NULL /* all */);
proc_net_remove(net, "ip_vs_app");
remove_proc_entry("ip_vs_app", net->proc_net);
}

+ 2
- 2
net/netfilter/ipvs/ip_vs_conn.c View File

@ -1300,8 +1300,8 @@ void __net_exit ip_vs_conn_net_cleanup(struct net *net)
{
/* flush all the connection entries first */
ip_vs_conn_flush(net);
proc_net_remove(net, "ip_vs_conn");
proc_net_remove(net, "ip_vs_conn_sync");
remove_proc_entry("ip_vs_conn", net->proc_net);
remove_proc_entry("ip_vs_conn_sync", net->proc_net);
}
int __init ip_vs_conn_init(void)


+ 3
- 3
net/netfilter/ipvs/ip_vs_ctl.c View File

@ -3822,9 +3822,9 @@ void __net_exit ip_vs_control_net_cleanup(struct net *net)
ip_vs_trash_cleanup(net);
ip_vs_stop_estimator(net, &ipvs->tot_stats);
ip_vs_control_net_cleanup_sysctl(net);
proc_net_remove(net, "ip_vs_stats_percpu");
proc_net_remove(net, "ip_vs_stats");
proc_net_remove(net, "ip_vs");
remove_proc_entry("ip_vs_stats_percpu", net->proc_net);
remove_proc_entry("ip_vs_stats", net->proc_net);
remove_proc_entry("ip_vs", net->proc_net);
free_percpu(ipvs->tot_stats.cpustats);
}


+ 1
- 1
net/netfilter/nf_conntrack_expect.c View File

@ -582,7 +582,7 @@ static int exp_proc_init(struct net *net)
static void exp_proc_remove(struct net *net)
{
#ifdef CONFIG_NF_CONNTRACK_PROCFS
proc_net_remove(net, "nf_conntrack_expect");
remove_proc_entry("nf_conntrack_expect", net->proc_net);
#endif /* CONFIG_NF_CONNTRACK_PROCFS */
}


+ 2
- 2
net/netfilter/nf_conntrack_standalone.c View File

@ -377,7 +377,7 @@ static int nf_conntrack_standalone_init_proc(struct net *net)
return 0;
out_stat_nf_conntrack:
proc_net_remove(net, "nf_conntrack");
remove_proc_entry("nf_conntrack", net->proc_net);
out_nf_conntrack:
return -ENOMEM;
}
@ -385,7 +385,7 @@ out_nf_conntrack:
static void nf_conntrack_standalone_fini_proc(struct net *net)
{
remove_proc_entry("nf_conntrack", net->proc_net_stat);
proc_net_remove(net, "nf_conntrack");
remove_proc_entry("nf_conntrack", net->proc_net);
}
#else
static int nf_conntrack_standalone_init_proc(struct net *net)


+ 5
- 5
net/netfilter/x_tables.c View File

@ -1323,12 +1323,12 @@ int xt_proto_init(struct net *net, u_int8_t af)
out_remove_matches:
strlcpy(buf, xt_prefix[af], sizeof(buf));
strlcat(buf, FORMAT_MATCHES, sizeof(buf));
proc_net_remove(net, buf);
remove_proc_entry(buf, net->proc_net);
out_remove_tables:
strlcpy(buf, xt_prefix[af], sizeof(buf));
strlcat(buf, FORMAT_TABLES, sizeof(buf));
proc_net_remove(net, buf);
remove_proc_entry(buf, net->proc_net);
out:
return -1;
#endif
@ -1342,15 +1342,15 @@ void xt_proto_fini(struct net *net, u_int8_t af)
strlcpy(buf, xt_prefix[af], sizeof(buf));
strlcat(buf, FORMAT_TABLES, sizeof(buf));
proc_net_remove(net, buf);
remove_proc_entry(buf, net->proc_net);
strlcpy(buf, xt_prefix[af], sizeof(buf));
strlcat(buf, FORMAT_TARGETS, sizeof(buf));
proc_net_remove(net, buf);
remove_proc_entry(buf, net->proc_net);
strlcpy(buf, xt_prefix[af], sizeof(buf));
strlcat(buf, FORMAT_MATCHES, sizeof(buf));
proc_net_remove(net, buf);
remove_proc_entry(buf, net->proc_net);
#endif /*CONFIG_PROC_FS*/
}
EXPORT_SYMBOL_GPL(xt_proto_fini);


+ 3
- 3
net/netfilter/xt_hashlimit.c View File

@ -867,7 +867,7 @@ static int __net_init hashlimit_proc_net_init(struct net *net)
#if IS_ENABLED(CONFIG_IP6_NF_IPTABLES)
hashlimit_net->ip6t_hashlimit = proc_mkdir("ip6t_hashlimit", net->proc_net);
if (!hashlimit_net->ip6t_hashlimit) {
proc_net_remove(net, "ipt_hashlimit");
remove_proc_entry("ipt_hashlimit", net->proc_net);
return -ENOMEM;
}
#endif
@ -897,9 +897,9 @@ static void __net_exit hashlimit_proc_net_exit(struct net *net)
hashlimit_net->ip6t_hashlimit = NULL;
mutex_unlock(&hashlimit_mutex);
proc_net_remove(net, "ipt_hashlimit");
remove_proc_entry("ipt_hashlimit", net->proc_net);
#if IS_ENABLED(CONFIG_IP6_NF_IPTABLES)
proc_net_remove(net, "ip6t_hashlimit");
remove_proc_entry("ip6t_hashlimit", net->proc_net);
#endif
}


+ 1
- 1
net/netfilter/xt_recent.c View File

@ -643,7 +643,7 @@ static void __net_exit recent_proc_net_exit(struct net *net)
recent_net->xt_recent = NULL;
spin_unlock_bh(&recent_lock);
proc_net_remove(net, "xt_recent");
remove_proc_entry("xt_recent", net->proc_net);
}
#else
static inline int recent_proc_net_init(struct net *net)


+ 1
- 1
net/netlink/af_netlink.c View File

@ -2154,7 +2154,7 @@ static int __net_init netlink_net_init(struct net *net)
static void __net_exit netlink_net_exit(struct net *net)
{
#ifdef CONFIG_PROC_FS
proc_net_remove(net, "netlink");
remove_proc_entry("netlink", net->proc_net);
#endif
}


+ 3
- 3
net/netrom/af_netrom.c View File

@ -1482,9 +1482,9 @@ static void __exit nr_exit(void)
{
int i;
proc_net_remove(&init_net, "nr");
proc_net_remove(&init_net, "nr_neigh");
proc_net_remove(&init_net, "nr_nodes");
remove_proc_entry("nr", init_net.proc_net);
remove_proc_entry("nr_neigh", init_net.proc_net);
remove_proc_entry("nr_nodes", init_net.proc_net);
nr_loopback_clear();
nr_rt_free();


+ 1
- 1
net/packet/af_packet.c View File

@ -3836,7 +3836,7 @@ static int __net_init packet_net_init(struct net *net)
static void __net_exit packet_net_exit(struct net *net)
{
proc_net_remove(net, "packet");
remove_proc_entry("packet", net->proc_net);
}
static struct pernet_operations packet_net_ops = {


+ 2
- 2
net/phonet/pn_dev.c View File

@ -331,7 +331,7 @@ static int __net_init phonet_init_net(struct net *net)
static void __net_exit phonet_exit_net(struct net *net)
{
proc_net_remove(net, "phonet");
remove_proc_entry("phonet", net->proc_net);
}
static struct pernet_operations phonet_net_ops = {
@ -361,7 +361,7 @@ void phonet_device_exit(void)
rtnl_unregister_all(PF_PHONET);
unregister_netdevice_notifier(&phonet_device_notifier);
unregister_pernet_subsys(&phonet_net_ops);
proc_net_remove(&init_net, "pnresource");
remove_proc_entry("pnresource", init_net.proc_net);
}
int phonet_route_add(struct net_device *dev, u8 daddr)


+ 4
- 4
net/rose/af_rose.c View File

@ -1608,10 +1608,10 @@ static void __exit rose_exit(void)
{
int i;
proc_net_remove(&init_net, "rose");
proc_net_remove(&init_net, "rose_neigh");
proc_net_remove(&init_net, "rose_nodes");
proc_net_remove(&init_net, "rose_routes");
remove_proc_entry("rose", init_net.proc_net);
remove_proc_entry("rose_neigh", init_net.proc_net);
remove_proc_entry("rose_nodes", init_net.proc_net);
remove_proc_entry("rose_routes", init_net.proc_net);
rose_loopback_clear();
rose_rt_free();


+ 2
- 2
net/rxrpc/af_rxrpc.c View File

@ -879,8 +879,8 @@ static void __exit af_rxrpc_exit(void)
_debug("flush scheduled work");
flush_workqueue(rxrpc_workqueue);
proc_net_remove(&init_net, "rxrpc_conns");
proc_net_remove(&init_net, "rxrpc_calls");
remove_proc_entry("rxrpc_conns", init_net.proc_net);
remove_proc_entry("rxrpc_calls", init_net.proc_net);
destroy_workqueue(rxrpc_workqueue);
kmem_cache_destroy(rxrpc_call_jar);
_leave("");


+ 1
- 1
net/sched/sch_api.c View File

@ -1777,7 +1777,7 @@ static int __net_init psched_net_init(struct net *net)
static void __net_exit psched_net_exit(struct net *net)
{
proc_net_remove(net, "psched");
remove_proc_entry("psched", net->proc_net);
}
#else
static int __net_init psched_net_init(struct net *net)


+ 2
- 2
net/sctp/probe.c View File

@ -208,7 +208,7 @@ static __init int sctpprobe_init(void)
return 0;
remove_proc:
proc_net_remove(&init_net, procname);
remove_proc_entry(procname, init_net.proc_net);
free_kfifo:
kfifo_free(&sctpw.fifo);
return ret;
@ -217,7 +217,7 @@ free_kfifo:
static __exit void sctpprobe_exit(void)
{
kfifo_free(&sctpw.fifo);
proc_net_remove(&init_net, procname);
remove_proc_entry(procname, init_net.proc_net);
unregister_jprobe(&sctp_recv_probe);
}


+ 1
- 1
net/unix/af_unix.c View File

@ -2415,7 +2415,7 @@ out:
static void __net_exit unix_net_exit(struct net *net)
{
unix_sysctl_unregister(net);
proc_net_remove(net, "unix");
remove_proc_entry("unix", net->proc_net);
}
static struct pernet_operations unix_net_ops = {


+ 1
- 1
net/wireless/wext-proc.c View File

@ -152,5 +152,5 @@ int __net_init wext_proc_init(struct net *net)
void __net_exit wext_proc_exit(struct net *net)
{
proc_net_remove(net, "wireless");
remove_proc_entry("wireless", net->proc_net);
}

+ 1
- 1
net/xfrm/xfrm_proc.c View File

@ -82,5 +82,5 @@ int __net_init xfrm_proc_init(struct net *net)
void xfrm_proc_fini(struct net *net)
{
proc_net_remove(net, "xfrm_stat");
remove_proc_entry("xfrm_stat", net->proc_net);
}

Loading…
Cancel
Save