Commit cbbef5e183079455763fc470ccf69008f92ab4b6

Authored by Patrick McHardy
Committed by David S. Miller
1 parent 572a9d7b6f

vlan/macvlan: propagate transmission state to upper layers

Both vlan and macvlan devices usually don't use a qdisc and immediately
queue packets to the underlying device. Propagate transmission state of
the underlying device to the upper layers so they can react on congestion
and/or inform the sending process.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>

Showing 2 changed files with 3 additions and 3 deletions Side-by-side Diff

drivers/net/macvlan.c
... ... @@ -202,7 +202,7 @@
202 202 } else
203 203 txq->tx_dropped++;
204 204  
205   - return NETDEV_TX_OK;
  205 + return ret;
206 206 }
207 207  
208 208 static int macvlan_hard_header(struct sk_buff *skb, struct net_device *dev,
net/8021q/vlan_dev.c
... ... @@ -332,7 +332,7 @@
332 332 } else
333 333 txq->tx_dropped++;
334 334  
335   - return NETDEV_TX_OK;
  335 + return ret;
336 336 }
337 337  
338 338 static netdev_tx_t vlan_dev_hwaccel_hard_start_xmit(struct sk_buff *skb,
... ... @@ -358,7 +358,7 @@
358 358 } else
359 359 txq->tx_dropped++;
360 360  
361   - return NETDEV_TX_OK;
  361 + return ret;
362 362 }
363 363  
364 364 static int vlan_dev_change_mtu(struct net_device *dev, int new_mtu)