diff options
author | Tom Herbert <therbert@google.com> | 2014-07-02 06:32:49 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-07-08 06:14:21 +0200 |
commit | 535fb8d006bc6a96d59558181a9a6f267be382c5 (patch) | |
tree | 044ec047776bdbc14bdcf93ae2b9068d349bdeef /net | |
parent | udp: Add function to make source port for UDP tunnels (diff) | |
download | linux-535fb8d006bc6a96d59558181a9a6f267be382c5.tar.xz linux-535fb8d006bc6a96d59558181a9a6f267be382c5.zip |
vxlan: Call udp_flow_src_port
In vxlan and OVS vport-vxlan call common function to get source port
for a UDP tunnel. Removed vxlan_src_port since the functionality is
now in udp_flow_src_port.
Signed-off-by: Tom Herbert <therbert@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/openvswitch/vport-vxlan.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/net/openvswitch/vport-vxlan.c b/net/openvswitch/vport-vxlan.c index 0edbd95c60e7..d8b7e247bebf 100644 --- a/net/openvswitch/vport-vxlan.c +++ b/net/openvswitch/vport-vxlan.c @@ -143,8 +143,6 @@ static int vxlan_tnl_send(struct vport *vport, struct sk_buff *skb) struct rtable *rt; struct flowi4 fl; __be16 src_port; - int port_min; - int port_max; __be16 df; int err; @@ -172,8 +170,7 @@ static int vxlan_tnl_send(struct vport *vport, struct sk_buff *skb) skb->ignore_df = 1; - inet_get_local_port_range(net, &port_min, &port_max); - src_port = vxlan_src_port(port_min, port_max, skb); + src_port = udp_flow_src_port(net, skb, 0, 0, true); err = vxlan_xmit_skb(vxlan_port->vs, rt, skb, fl.saddr, OVS_CB(skb)->tun_key->ipv4_dst, |