Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c8c41ea1 authored by Alexander Duyck's avatar Alexander Duyck Committed by David S. Miller
Browse files

macvlan: Only update pkt_type if destination MAC address matches



This patch updates the pkt_type to PACKET_HOST only if the destination MAC
address matches on the on the source based macvlan. It didn't make sense to
be updating broadcast, multicast, and non-local destined frames with
PACKET_HOST.

Signed-off-by: default avatarAlexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent dd6b9c2c
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -413,6 +413,8 @@ static void macvlan_forward_source_one(struct sk_buff *skb,

	len = nskb->len + ETH_HLEN;
	nskb->dev = dev;

	if (ether_addr_equal_64bits(eth_hdr(skb)->h_dest, dev->dev_addr))
		nskb->pkt_type = PACKET_HOST;

	ret = netif_rx(nskb);