diff options
author | YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> | 2008-03-25 13:36:06 -0400 |
---|---|---|
committer | YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> | 2008-03-25 15:39:56 -0400 |
commit | 1218854afa6f659be90b748cf1bc7badee954a35 (patch) | |
tree | 78b83e3941fa7e5a03c04e2e4f6ddb1a08ea38a0 /net/ipv6 | |
parent | 3b1e0a655f8eba44ab1ee2a1068d169ccfb853b9 (diff) |
[NET] NETNS: Omit seq_net_private->net without CONFIG_NET_NS.
Without CONFIG_NET_NS, no namespace other than &init_net exists,
no need to store net in seq_net_private.
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Diffstat (limited to 'net/ipv6')
-rw-r--r-- | net/ipv6/addrconf.c | 4 | ||||
-rw-r--r-- | net/ipv6/mcast.c | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c index f2c90f145cbb..ac5d4f4b6312 100644 --- a/net/ipv6/addrconf.c +++ b/net/ipv6/addrconf.c | |||
@@ -2766,7 +2766,7 @@ static struct inet6_ifaddr *if6_get_first(struct seq_file *seq) | |||
2766 | { | 2766 | { |
2767 | struct inet6_ifaddr *ifa = NULL; | 2767 | struct inet6_ifaddr *ifa = NULL; |
2768 | struct if6_iter_state *state = seq->private; | 2768 | struct if6_iter_state *state = seq->private; |
2769 | struct net *net = state->p.net; | 2769 | struct net *net = seq_file_net(seq); |
2770 | 2770 | ||
2771 | for (state->bucket = 0; state->bucket < IN6_ADDR_HSIZE; ++state->bucket) { | 2771 | for (state->bucket = 0; state->bucket < IN6_ADDR_HSIZE; ++state->bucket) { |
2772 | ifa = inet6_addr_lst[state->bucket]; | 2772 | ifa = inet6_addr_lst[state->bucket]; |
@@ -2782,7 +2782,7 @@ static struct inet6_ifaddr *if6_get_first(struct seq_file *seq) | |||
2782 | static struct inet6_ifaddr *if6_get_next(struct seq_file *seq, struct inet6_ifaddr *ifa) | 2782 | static struct inet6_ifaddr *if6_get_next(struct seq_file *seq, struct inet6_ifaddr *ifa) |
2783 | { | 2783 | { |
2784 | struct if6_iter_state *state = seq->private; | 2784 | struct if6_iter_state *state = seq->private; |
2785 | struct net *net = state->p.net; | 2785 | struct net *net = seq_file_net(seq); |
2786 | 2786 | ||
2787 | ifa = ifa->lst_next; | 2787 | ifa = ifa->lst_next; |
2788 | try_again: | 2788 | try_again: |
diff --git a/net/ipv6/mcast.c b/net/ipv6/mcast.c index 20a3d8e2f6c6..d810cff818cf 100644 --- a/net/ipv6/mcast.c +++ b/net/ipv6/mcast.c | |||
@@ -2355,7 +2355,7 @@ static inline struct ifmcaddr6 *igmp6_mc_get_first(struct seq_file *seq) | |||
2355 | { | 2355 | { |
2356 | struct ifmcaddr6 *im = NULL; | 2356 | struct ifmcaddr6 *im = NULL; |
2357 | struct igmp6_mc_iter_state *state = igmp6_mc_seq_private(seq); | 2357 | struct igmp6_mc_iter_state *state = igmp6_mc_seq_private(seq); |
2358 | struct net *net = state->p.net; | 2358 | struct net *net = seq_file_net(seq); |
2359 | 2359 | ||
2360 | state->idev = NULL; | 2360 | state->idev = NULL; |
2361 | for_each_netdev(net, state->dev) { | 2361 | for_each_netdev(net, state->dev) { |
@@ -2486,7 +2486,7 @@ static inline struct ip6_sf_list *igmp6_mcf_get_first(struct seq_file *seq) | |||
2486 | struct ip6_sf_list *psf = NULL; | 2486 | struct ip6_sf_list *psf = NULL; |
2487 | struct ifmcaddr6 *im = NULL; | 2487 | struct ifmcaddr6 *im = NULL; |
2488 | struct igmp6_mcf_iter_state *state = igmp6_mcf_seq_private(seq); | 2488 | struct igmp6_mcf_iter_state *state = igmp6_mcf_seq_private(seq); |
2489 | struct net *net = state->p.net; | 2489 | struct net *net = seq_file_net(seq); |
2490 | 2490 | ||
2491 | state->idev = NULL; | 2491 | state->idev = NULL; |
2492 | state->im = NULL; | 2492 | state->im = NULL; |