提交 8978ca7c 编写于 作者: D David Gounaris 提交者: David S. Miller

net/wan/fsl_ucc_hdlc: Adding ARPHRD_ETHER

This patch is to avoid discarding ethernet
packets when using HDLC_ETH protocol.
Signed-off-by: NDavid Gounaris <david.gounaris@infinera.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 43a78e0e
......@@ -375,6 +375,10 @@ static netdev_tx_t ucc_hdlc_tx(struct sk_buff *skb, struct net_device *dev)
dev->stats.tx_bytes += skb->len;
break;
case ARPHRD_ETHER:
dev->stats.tx_bytes += skb->len;
break;
default:
dev->stats.tx_dropped++;
dev_kfree_skb(skb);
......@@ -512,6 +516,7 @@ static int hdlc_rx_done(struct ucc_hdlc_private *priv, int rx_work_limit)
break;
case ARPHRD_PPP:
case ARPHRD_ETHER:
length -= HDLC_CRC_SIZE;
skb = dev_alloc_skb(length);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册