From: Ron Mercer Date: Wed, 11 Mar 2009 11:55:43 +0000 (+0000) Subject: qlge: bugfix: Pad outbound frames smaller than 60 bytes. X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=855b0993f216a9b0f9cb33573bd05e314105d86c;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git qlge: bugfix: Pad outbound frames smaller than 60 bytes. With some asic configurations xmit of frames smaller than 60 bytes may fail. Signed-off-by: Ron Mercer Signed-off-by: David S. Miller --- diff --git a/drivers/net/qlge/qlge_main.c b/drivers/net/qlge/qlge_main.c index 00c37c0f8a90..91191f761fba 100644 --- a/drivers/net/qlge/qlge_main.c +++ b/drivers/net/qlge/qlge_main.c @@ -1941,6 +1941,9 @@ static int qlge_send(struct sk_buff *skb, struct net_device *ndev) tx_ring = &qdev->tx_ring[tx_ring_idx]; + if (skb_padto(skb, ETH_ZLEN)) + return NETDEV_TX_OK; + if (unlikely(atomic_read(&tx_ring->tx_count) < 2)) { QPRINTK(qdev, TX_QUEUED, INFO, "%s: shutting down tx queue %d du to lack of resources.\n",