diff options
author | Changli Gao <xiaosuo@gmail.com> | 2010-06-11 02:31:35 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-06-11 02:31:35 -0400 |
commit | d8d1f30b95a635dbd610dcc5eb641aca8f4768cf (patch) | |
tree | 71424d82a96facd5fcf05cc769ef2ba52b584aeb /net/ipv4/ip_gre.c | |
parent | 592fcb9dfafaa02dd0edc207bf5d3a0ee7a1f8df (diff) |
net-next: remove useless union keyword
remove useless union keyword in rtable, rt6_info and dn_route.
Since there is only one member in a union, the union keyword isn't useful.
Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/ip_gre.c')
-rw-r--r-- | net/ipv4/ip_gre.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/net/ipv4/ip_gre.c b/net/ipv4/ip_gre.c index 32618e11076d..749e54889e82 100644 --- a/net/ipv4/ip_gre.c +++ b/net/ipv4/ip_gre.c | |||
@@ -745,7 +745,7 @@ static netdev_tx_t ipgre_tunnel_xmit(struct sk_buff *skb, struct net_device *dev | |||
745 | goto tx_error; | 745 | goto tx_error; |
746 | } | 746 | } |
747 | } | 747 | } |
748 | tdev = rt->u.dst.dev; | 748 | tdev = rt->dst.dev; |
749 | 749 | ||
750 | if (tdev == dev) { | 750 | if (tdev == dev) { |
751 | ip_rt_put(rt); | 751 | ip_rt_put(rt); |
@@ -755,7 +755,7 @@ static netdev_tx_t ipgre_tunnel_xmit(struct sk_buff *skb, struct net_device *dev | |||
755 | 755 | ||
756 | df = tiph->frag_off; | 756 | df = tiph->frag_off; |
757 | if (df) | 757 | if (df) |
758 | mtu = dst_mtu(&rt->u.dst) - dev->hard_header_len - tunnel->hlen; | 758 | mtu = dst_mtu(&rt->dst) - dev->hard_header_len - tunnel->hlen; |
759 | else | 759 | else |
760 | mtu = skb_dst(skb) ? dst_mtu(skb_dst(skb)) : dev->mtu; | 760 | mtu = skb_dst(skb) ? dst_mtu(skb_dst(skb)) : dev->mtu; |
761 | 761 | ||
@@ -803,7 +803,7 @@ static netdev_tx_t ipgre_tunnel_xmit(struct sk_buff *skb, struct net_device *dev | |||
803 | tunnel->err_count = 0; | 803 | tunnel->err_count = 0; |
804 | } | 804 | } |
805 | 805 | ||
806 | max_headroom = LL_RESERVED_SPACE(tdev) + gre_hlen + rt->u.dst.header_len; | 806 | max_headroom = LL_RESERVED_SPACE(tdev) + gre_hlen + rt->dst.header_len; |
807 | 807 | ||
808 | if (skb_headroom(skb) < max_headroom || skb_shared(skb)|| | 808 | if (skb_headroom(skb) < max_headroom || skb_shared(skb)|| |
809 | (skb_cloned(skb) && !skb_clone_writable(skb, 0))) { | 809 | (skb_cloned(skb) && !skb_clone_writable(skb, 0))) { |
@@ -830,7 +830,7 @@ static netdev_tx_t ipgre_tunnel_xmit(struct sk_buff *skb, struct net_device *dev | |||
830 | IPCB(skb)->flags &= ~(IPSKB_XFRM_TUNNEL_SIZE | IPSKB_XFRM_TRANSFORMED | | 830 | IPCB(skb)->flags &= ~(IPSKB_XFRM_TUNNEL_SIZE | IPSKB_XFRM_TRANSFORMED | |
831 | IPSKB_REROUTED); | 831 | IPSKB_REROUTED); |
832 | skb_dst_drop(skb); | 832 | skb_dst_drop(skb); |
833 | skb_dst_set(skb, &rt->u.dst); | 833 | skb_dst_set(skb, &rt->dst); |
834 | 834 | ||
835 | /* | 835 | /* |
836 | * Push down and install the IPIP header. | 836 | * Push down and install the IPIP header. |
@@ -853,7 +853,7 @@ static netdev_tx_t ipgre_tunnel_xmit(struct sk_buff *skb, struct net_device *dev | |||
853 | iph->ttl = ((struct ipv6hdr *)old_iph)->hop_limit; | 853 | iph->ttl = ((struct ipv6hdr *)old_iph)->hop_limit; |
854 | #endif | 854 | #endif |
855 | else | 855 | else |
856 | iph->ttl = dst_metric(&rt->u.dst, RTAX_HOPLIMIT); | 856 | iph->ttl = dst_metric(&rt->dst, RTAX_HOPLIMIT); |
857 | } | 857 | } |
858 | 858 | ||
859 | ((__be16 *)(iph + 1))[0] = tunnel->parms.o_flags; | 859 | ((__be16 *)(iph + 1))[0] = tunnel->parms.o_flags; |
@@ -915,7 +915,7 @@ static int ipgre_tunnel_bind_dev(struct net_device *dev) | |||
915 | .proto = IPPROTO_GRE }; | 915 | .proto = IPPROTO_GRE }; |
916 | struct rtable *rt; | 916 | struct rtable *rt; |
917 | if (!ip_route_output_key(dev_net(dev), &rt, &fl)) { | 917 | if (!ip_route_output_key(dev_net(dev), &rt, &fl)) { |
918 | tdev = rt->u.dst.dev; | 918 | tdev = rt->dst.dev; |
919 | ip_rt_put(rt); | 919 | ip_rt_put(rt); |
920 | } | 920 | } |
921 | 921 | ||
@@ -1174,7 +1174,7 @@ static int ipgre_open(struct net_device *dev) | |||
1174 | struct rtable *rt; | 1174 | struct rtable *rt; |
1175 | if (ip_route_output_key(dev_net(dev), &rt, &fl)) | 1175 | if (ip_route_output_key(dev_net(dev), &rt, &fl)) |
1176 | return -EADDRNOTAVAIL; | 1176 | return -EADDRNOTAVAIL; |
1177 | dev = rt->u.dst.dev; | 1177 | dev = rt->dst.dev; |
1178 | ip_rt_put(rt); | 1178 | ip_rt_put(rt); |
1179 | if (__in_dev_get_rtnl(dev) == NULL) | 1179 | if (__in_dev_get_rtnl(dev) == NULL) |
1180 | return -EADDRNOTAVAIL; | 1180 | return -EADDRNOTAVAIL; |