Skip to content

Commit efbbced

Browse files
kaberdavem330
authored andcommitted
macvlan: don't broadcast PAUSE frames to macvlan devices
PAUSE frames are only relevant for the real device, broadcasting them to all macvlan devices can cause a significant load increase. Reported-by: Ben Greear <greearb@candelatech.com> Tested-by: Ben Greear <greearb@candelatech.com> Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 7e5ab54 commit efbbced

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

‎drivers/net/macvlan.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,9 @@ static void macvlan_broadcast(struct sk_buff *skb,
7070
struct sk_buff *nskb;
7171
unsigned int i;
7272

73+
if (skb->protocol == htons(ETH_P_PAUSE))
74+
return;
75+
7376
for (i = 0; i < MACVLAN_HASH_SIZE; i++) {
7477
hlist_for_each_entry_rcu(vlan, n, &port->vlan_hash[i], hlist) {
7578
dev = vlan->dev;

0 commit comments

Comments
 (0)