[NET]: Make /proc/net per network namespace
authorEric W. Biederman <ebiederm@xmission.com>
Wed, 12 Sep 2007 10:01:34 +0000 (12:01 +0200)
committerDavid S. Miller <davem@sunset.davemloft.net>
Wed, 10 Oct 2007 23:49:06 +0000 (16:49 -0700)
commit457c4cbc5a3dde259d2a1f15d5f9785290397267
treea2ceee88780cbce27433b9a4434b3e9251efd81a
parent07feaebfcc10cd35e745c7073667935246494bee
[NET]: Make /proc/net per network namespace

This patch makes /proc/net per network namespace.  It modifies the global
variables proc_net and proc_net_stat to be per network namespace.
The proc_net file helpers are modified to take a network namespace argument,
and all of their callers are fixed to pass &init_net for that argument.
This ensures that all of the /proc/net files are only visible and
usable in the initial network namespace until the code behind them
has been updated to be handle multiple network namespaces.

Making /proc/net per namespace is necessary as at least some files
in /proc/net depend upon the set of network devices which is per
network namespace, and even more files in /proc/net have contents
that are relevant to a single network namespace.

Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
84 files changed:
drivers/isdn/divert/divert_procfs.c
drivers/isdn/hardware/eicon/diva_didd.c
drivers/isdn/hysdn/hysdn_procconf.c
drivers/net/bonding/bond_main.c
drivers/net/hamradio/bpqether.c
drivers/net/hamradio/scc.c
drivers/net/hamradio/yam.c
drivers/net/ibmveth.c
drivers/net/pppoe.c
drivers/net/pppol2tp.c
drivers/net/tokenring/lanstreamer.c
drivers/net/tokenring/olympic.c
drivers/net/wireless/hostap/hostap_main.c
drivers/net/wireless/strip.c
fs/proc/Makefile
fs/proc/internal.h
fs/proc/root.c
include/linux/proc_fs.h
include/net/net_namespace.h
net/802/tr.c
net/8021q/vlanproc.c
net/appletalk/atalk_proc.c
net/atm/proc.c
net/ax25/af_ax25.c
net/core/dev.c
net/core/dev_mcast.c
net/core/neighbour.c
net/core/pktgen.c
net/core/sock.c
net/dccp/probe.c
net/decnet/af_decnet.c
net/decnet/dn_dev.c
net/decnet/dn_neigh.c
net/decnet/dn_route.c
net/ieee80211/ieee80211_module.c
net/ipv4/arp.c
net/ipv4/fib_hash.c
net/ipv4/fib_trie.c
net/ipv4/igmp.c
net/ipv4/ipconfig.c
net/ipv4/ipmr.c
net/ipv4/ipvs/ip_vs_app.c
net/ipv4/ipvs/ip_vs_conn.c
net/ipv4/ipvs/ip_vs_ctl.c
net/ipv4/ipvs/ip_vs_lblcr.c
net/ipv4/netfilter/ip_queue.c
net/ipv4/netfilter/ipt_CLUSTERIP.c
net/ipv4/netfilter/ipt_recent.c
net/ipv4/netfilter/nf_conntrack_l3proto_ipv4_compat.c
net/ipv4/proc.c
net/ipv4/raw.c
net/ipv4/route.c
net/ipv4/tcp_ipv4.c
net/ipv4/tcp_probe.c
net/ipv4/udp.c
net/ipv6/addrconf.c
net/ipv6/anycast.c
net/ipv6/ip6_flowlabel.c
net/ipv6/mcast.c
net/ipv6/netfilter/ip6_queue.c
net/ipv6/proc.c
net/ipv6/raw.c
net/ipv6/route.c
net/ipx/ipx_proc.c
net/irda/irproc.c
net/key/af_key.c
net/llc/llc_proc.c
net/netfilter/core.c
net/netfilter/nf_conntrack_expect.c
net/netfilter/nf_conntrack_standalone.c
net/netfilter/x_tables.c
net/netfilter/xt_hashlimit.c
net/netlink/af_netlink.c
net/netrom/af_netrom.c
net/packet/af_packet.c
net/rose/af_rose.c
net/rxrpc/af_rxrpc.c
net/sched/sch_api.c
net/sctp/protocol.c
net/sunrpc/stats.c
net/unix/af_unix.c
net/wanrouter/wanproc.c
net/wireless/wext.c
net/x25/x25_proc.c