Skip to content

Commit

Permalink
macvlan: Forward unicast frames in bridge mode to lowerdev
Browse files Browse the repository at this point in the history
Unicast frames between macvlan interfaces in bridge mode are not otherwise
sent to network taps on the lowerdev (as all other macvlan frames are), so
forward the frames to the receive queue of the lowerdev first.

Signed-off-by: David Ward <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
dpward authored and davem330 committed May 23, 2011
1 parent 67f11f4 commit a37dd33
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions drivers/net/macvlan.c
Original file line number Diff line number Diff line change
Expand Up @@ -238,10 +238,8 @@ static int macvlan_queue_xmit(struct sk_buff *skb, struct net_device *dev)

dest = macvlan_hash_lookup(port, eth->h_dest);
if (dest && dest->mode == MACVLAN_MODE_BRIDGE) {
unsigned int length = skb->len + ETH_HLEN;
int ret = dest->forward(dest->dev, skb);
macvlan_count_rx(dest, length,
ret == NET_RX_SUCCESS, 0);
/* send to lowerdev first for its network taps */
vlan->forward(vlan->lowerdev, skb);

return NET_XMIT_SUCCESS;
}
Expand Down

0 comments on commit a37dd33

Please sign in to comment.