Commit 6d99dd96 authored by Alan Cox's avatar Alan Cox Committed by Linus Torvalds

[PATCH] fix seeq8005 using skb_padto

parent fe777b45
...@@ -377,9 +377,15 @@ static void seeq8005_timeout(struct net_device *dev) ...@@ -377,9 +377,15 @@ static void seeq8005_timeout(struct net_device *dev)
static int seeq8005_send_packet(struct sk_buff *skb, struct net_device *dev) static int seeq8005_send_packet(struct sk_buff *skb, struct net_device *dev)
{ {
struct net_local *lp = (struct net_local *)dev->priv; struct net_local *lp = (struct net_local *)dev->priv;
short length = ETH_ZLEN < skb->len ? skb->len : ETH_ZLEN; short length = skb->len;
unsigned char *buf = skb->data; unsigned char *buf = skb->data;
if (length < ETH_ZLEN) {
skb = skb_padto(skb, ETH_ZLEN);
if (skb == NULL)
return 0;
length = ETH_ZLEN;
}
/* Block a timer-based transmit from overlapping */ /* Block a timer-based transmit from overlapping */
netif_stop_queue(dev); netif_stop_queue(dev);
......
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