X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=datapath%2Fvport-vxlan.c;h=cc9477dd17d2f8a413635fd3d85766ac3a9a619e;hb=c5cf10598f8c9f4428291e9df3ecd72a05fb1ccf;hp=3401dfd22592bb6704da5a62f890ba5ba43f0f3a;hpb=13beaf6242986435200e545ce636446b12df8022;p=sliver-openvswitch.git diff --git a/datapath/vport-vxlan.c b/datapath/vport-vxlan.c index 3401dfd22..cc9477dd1 100644 --- a/datapath/vport-vxlan.c +++ b/datapath/vport-vxlan.c @@ -31,7 +31,6 @@ #include #include #include -#include #include #include #include @@ -125,7 +124,7 @@ static struct vport *vxlan_tnl_create(const struct vport_parms *parms) vxlan_port = vxlan_vport(vport); strncpy(vxlan_port->name, parms->name, IFNAMSIZ); - vs = vxlan_sock_add(net, htons(dst_port), vxlan_rcv, vport, true); + vs = vxlan_sock_add(net, htons(dst_port), vxlan_rcv, vport, true, false); if (IS_ERR(vs)) { ovs_vport_free(vport); return (void *)vs; @@ -140,6 +139,7 @@ error: static int vxlan_tnl_send(struct vport *vport, struct sk_buff *skb) { + struct net *net = ovs_dp_get_net(vport->dp); struct vxlan_port *vxlan_port = vxlan_vport(vport); __be16 dst_port = inet_sport(vxlan_port->vs->sock->sk); struct rtable *rt; @@ -173,7 +173,7 @@ static int vxlan_tnl_send(struct vport *vport, struct sk_buff *skb) skb->local_df = 1; - inet_get_local_port_range(&port_min, &port_max); + inet_get_local_port_range(net, &port_min, &port_max); src_port = vxlan_src_port(port_min, port_max, skb); err = vxlan_xmit_skb(vxlan_port->vs, rt, skb,