diff options
author | David S. Miller <davem@davemloft.net> | 2010-11-15 11:52:02 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-11-15 11:52:02 -0500 |
commit | d9aa93804e53f2153260568024b75ad3d81784f9 (patch) | |
tree | 467753edeeb50e7b40da73141cb2478c82b3a623 /net/ipv4/igmp.c | |
parent | c25ecd0a21d5e08160cb5cc984f9e2b8ee347443 (diff) |
ipv4: Fix build with multicast disabled.
net/ipv4/igmp.c: In function 'ip_mc_inc_group':
net/ipv4/igmp.c:1228: error: implicit declaration of function 'for_each_pmc_rtnl'
net/ipv4/igmp.c:1228: error: expected ';' before '{' token
net/ipv4/igmp.c: In function 'ip_mc_unmap':
net/ipv4/igmp.c:1333: error: expected ';' before 'igmp_group_dropped'
...
Move for_each_pmc_rcu and for_each_pmc_rtnl macro definitions
outside of multicast ifdef protection.
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/igmp.c')
-rw-r--r-- | net/ipv4/igmp.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/net/ipv4/igmp.c b/net/ipv4/igmp.c index 0f0e0f0279b8..a1bf2f49e716 100644 --- a/net/ipv4/igmp.c +++ b/net/ipv4/igmp.c | |||
@@ -163,6 +163,16 @@ static void ip_ma_put(struct ip_mc_list *im) | |||
163 | } | 163 | } |
164 | } | 164 | } |
165 | 165 | ||
166 | #define for_each_pmc_rcu(in_dev, pmc) \ | ||
167 | for (pmc = rcu_dereference(in_dev->mc_list); \ | ||
168 | pmc != NULL; \ | ||
169 | pmc = rcu_dereference(pmc->next_rcu)) | ||
170 | |||
171 | #define for_each_pmc_rtnl(in_dev, pmc) \ | ||
172 | for (pmc = rtnl_dereference(in_dev->mc_list); \ | ||
173 | pmc != NULL; \ | ||
174 | pmc = rtnl_dereference(pmc->next_rcu)) | ||
175 | |||
166 | #ifdef CONFIG_IP_MULTICAST | 176 | #ifdef CONFIG_IP_MULTICAST |
167 | 177 | ||
168 | /* | 178 | /* |
@@ -502,16 +512,6 @@ empty_source: | |||
502 | return skb; | 512 | return skb; |
503 | } | 513 | } |
504 | 514 | ||
505 | #define for_each_pmc_rcu(in_dev, pmc) \ | ||
506 | for (pmc = rcu_dereference(in_dev->mc_list); \ | ||
507 | pmc != NULL; \ | ||
508 | pmc = rcu_dereference(pmc->next_rcu)) | ||
509 | |||
510 | #define for_each_pmc_rtnl(in_dev, pmc) \ | ||
511 | for (pmc = rtnl_dereference(in_dev->mc_list); \ | ||
512 | pmc != NULL; \ | ||
513 | pmc = rtnl_dereference(pmc->next_rcu)) | ||
514 | |||
515 | static int igmpv3_send_report(struct in_device *in_dev, struct ip_mc_list *pmc) | 515 | static int igmpv3_send_report(struct in_device *in_dev, struct ip_mc_list *pmc) |
516 | { | 516 | { |
517 | struct sk_buff *skb = NULL; | 517 | struct sk_buff *skb = NULL; |