summaryrefslogtreecommitdiffstats
path: root/net/l2tp/l2tp_eth.c
diff options
context:
space:
mode:
authorGao Feng <gfree.wind@gmail.com>2016-11-21 08:56:21 +0800
committerDavid S. Miller <davem@davemloft.net>2016-11-21 13:10:29 -0500
commit7c6ae610a1f0a9d3cebf790e0245b4e0f76aa86e (patch)
treeb3f4d6edd5bd8de6d98dc49b40e6cdcce9aa146c /net/l2tp/l2tp_eth.c
parent6bc5445c0180a0c7cc61a95d131c7eac66459692 (diff)
downloadlinux-7c6ae610a1f0a9d3cebf790e0245b4e0f76aa86e.tar.gz
linux-7c6ae610a1f0a9d3cebf790e0245b4e0f76aa86e.tar.bz2
linux-7c6ae610a1f0a9d3cebf790e0245b4e0f76aa86e.zip
net: l2tp: Treat NET_XMIT_CN as success in l2tp_eth_dev_xmit
The tc could return NET_XMIT_CN as one congestion notification, but it does not mean the packe is lost. Other modules like ipvlan, macvlan, and others treat NET_XMIT_CN as success too. So l2tp_eth_dev_xmit should add the NET_XMIT_CN check. Signed-off-by: Gao Feng <gfree.wind@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/l2tp/l2tp_eth.c')
-rw-r--r--net/l2tp/l2tp_eth.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/l2tp/l2tp_eth.c b/net/l2tp/l2tp_eth.c
index 965f7e344cef..3dc97b4f982b 100644
--- a/net/l2tp/l2tp_eth.c
+++ b/net/l2tp/l2tp_eth.c
@@ -97,7 +97,7 @@ static int l2tp_eth_dev_xmit(struct sk_buff *skb, struct net_device *dev)
unsigned int len = skb->len;
int ret = l2tp_xmit_skb(session, skb, session->hdr_len);
- if (likely(ret == NET_XMIT_SUCCESS)) {
+ if (likely(ret == NET_XMIT_SUCCESS || ret == NET_XMIT_CN)) {
atomic_long_add(len, &priv->tx_bytes);
atomic_long_inc(&priv->tx_packets);
} else {