Commit e7851533 authored by Alan Cox's avatar Alan Cox Committed by Linus Torvalds

[PATCH] fix lp486e using skb_padto

parent d530fb24
...@@ -885,7 +885,15 @@ i596_start_xmit (struct sk_buff *skb, struct net_device *dev) { ...@@ -885,7 +885,15 @@ i596_start_xmit (struct sk_buff *skb, struct net_device *dev) {
if (skb->len <= 0) if (skb->len <= 0)
return 0; return 0;
length = (ETH_ZLEN < skb->len) ? skb->len : ETH_ZLEN; length = skb->len;
if (length < ETH_ZLEN) {
skb = skb_padto(skb, ETH_ZLEN);
if (skb == NULL)
return 0;
length = ETH_ZLEN;
}
dev->trans_start = jiffies; dev->trans_start = jiffies;
tx_cmd = (struct tx_cmd *) tx_cmd = (struct tx_cmd *)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment