From: Mike Rapoport Date: Sat, 13 Apr 2013 23:21:51 +0000 (+0000) Subject: vxlan: don't bypass encapsulation for multi- and broadcasts X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=ab09a6d0d38fc0da11e4cd57ec7f9fcfd16d335d;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git vxlan: don't bypass encapsulation for multi- and broadcasts The multicast and broadcast packets may have RTCF_LOCAL set in rt_flags and therefore will be sent out bypassing encapsulation. This breaks delivery of packets sent to the vxlan multicast group. Disabling encapsulation bypass for multicasts and broadcasts fixes the issue. Signed-off-by: Mike Rapoport Tested-by: Cong Wang Acked-by: Sridhar Samudrala Tested-by: Sridhar Samudrala Signed-off-by: David S. Miller --- diff --git a/drivers/net/vxlan.c b/drivers/net/vxlan.c index 725aba37e182..97a306c9e65d 100644 --- a/drivers/net/vxlan.c +++ b/drivers/net/vxlan.c @@ -1014,7 +1014,8 @@ static netdev_tx_t vxlan_xmit_one(struct sk_buff *skb, struct net_device *dev, } /* Bypass encapsulation if the destination is local */ - if (rt->rt_flags & RTCF_LOCAL) { + if (rt->rt_flags & RTCF_LOCAL && + !(rt->rt_flags & (RTCF_BROADCAST | RTCF_MULTICAST))) { struct vxlan_dev *dst_vxlan; ip_rt_put(rt);