diff options
author | Changli Gao <xiaosuo@gmail.com> | 2010-11-12 18:43:55 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-11-17 12:27:45 -0800 |
commit | 5811662b15db018c740c57d037523683fd3e6123 (patch) | |
tree | f820610a6024799a26699f22dc9a4ef5dee07978 /net/ipv4/igmp.c | |
parent | dd68ad2235b4625e0dc928b2b4c614d265f976d3 (diff) | |
download | linux-5811662b15db018c740c57d037523683fd3e6123.tar.gz linux-5811662b15db018c740c57d037523683fd3e6123.tar.bz2 linux-5811662b15db018c740c57d037523683fd3e6123.zip |
net: use the macros defined for the members of flowi
Use the macros defined for the members of flowi to clean the code up.
Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/igmp.c')
-rw-r--r-- | net/ipv4/igmp.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/net/ipv4/igmp.c b/net/ipv4/igmp.c index a1bf2f49e716..afb1e82a59f9 100644 --- a/net/ipv4/igmp.c +++ b/net/ipv4/igmp.c @@ -314,8 +314,7 @@ static struct sk_buff *igmpv3_newpack(struct net_device *dev, int size) { struct flowi fl = { .oif = dev->ifindex, - .nl_u = { .ip4_u = { - .daddr = IGMPV3_ALL_MCR } }, + .fl4_dst = IGMPV3_ALL_MCR, .proto = IPPROTO_IGMP }; if (ip_route_output_key(net, &rt, &fl)) { kfree_skb(skb); @@ -660,7 +659,7 @@ static int igmp_send_report(struct in_device *in_dev, struct ip_mc_list *pmc, { struct flowi fl = { .oif = dev->ifindex, - .nl_u = { .ip4_u = { .daddr = dst } }, + .fl4_dst = dst, .proto = IPPROTO_IGMP }; if (ip_route_output_key(net, &rt, &fl)) return -1; @@ -1425,8 +1424,7 @@ void ip_mc_destroy_dev(struct in_device *in_dev) /* RTNL is locked */ static struct in_device *ip_mc_find_dev(struct net *net, struct ip_mreqn *imr) { - struct flowi fl = { .nl_u = { .ip4_u = - { .daddr = imr->imr_multiaddr.s_addr } } }; + struct flowi fl = { .fl4_dst = imr->imr_multiaddr.s_addr }; struct rtable *rt; struct net_device *dev = NULL; struct in_device *idev = NULL; |