Skip to content

Commit 6ab271a

Browse files
idoschdavem330
authored andcommitted
vxlan: Expose vxlan_xmit_one()
Given a packet and a remote destination, the function will take care of encapsulating the packet and transmitting it to the destination. Expose it so that it could be used in subsequent patches by the MDB code to transmit a packet to the remote destination(s) stored in the MDB entry. It will allow us to keep the MDB code self-contained, not exposing its data structures to the rest of the VXLAN driver. Signed-off-by: Ido Schimmel <[email protected]> Reviewed-by: Nikolay Aleksandrov <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent f307c8b commit 6ab271a

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

drivers/net/vxlan/vxlan_core.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2395,9 +2395,8 @@ static int encap_bypass_if_local(struct sk_buff *skb, struct net_device *dev,
23952395
return 0;
23962396
}
23972397

2398-
static void vxlan_xmit_one(struct sk_buff *skb, struct net_device *dev,
2399-
__be32 default_vni, struct vxlan_rdst *rdst,
2400-
bool did_rsc)
2398+
void vxlan_xmit_one(struct sk_buff *skb, struct net_device *dev,
2399+
__be32 default_vni, struct vxlan_rdst *rdst, bool did_rsc)
24012400
{
24022401
struct dst_cache *dst_cache;
24032402
struct ip_tunnel_info *info;

drivers/net/vxlan/vxlan_private.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,8 @@ int vxlan_fdb_update(struct vxlan_dev *vxlan,
172172
__be16 port, __be32 src_vni, __be32 vni,
173173
__u32 ifindex, __u16 ndm_flags, u32 nhid,
174174
bool swdev_notify, struct netlink_ext_ack *extack);
175+
void vxlan_xmit_one(struct sk_buff *skb, struct net_device *dev,
176+
__be32 default_vni, struct vxlan_rdst *rdst, bool did_rsc);
175177
int vxlan_vni_in_use(struct net *src_net, struct vxlan_dev *vxlan,
176178
struct vxlan_config *conf, __be32 vni);
177179

0 commit comments

Comments
 (0)