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

[PATCH] fix ethernet padding on ni52

parent 1578e844
...@@ -1169,7 +1169,11 @@ static int ni52_send_packet(struct sk_buff *skb, struct net_device *dev) ...@@ -1169,7 +1169,11 @@ static int ni52_send_packet(struct sk_buff *skb, struct net_device *dev)
#endif #endif
{ {
memcpy((char *)p->xmit_cbuffs[p->xmit_count],(char *)(skb->data),skb->len); memcpy((char *)p->xmit_cbuffs[p->xmit_count],(char *)(skb->data),skb->len);
len = (ETH_ZLEN < skb->len) ? skb->len : ETH_ZLEN; len = skb->len;
if (len < ETH_ZLEN) {
len = ETH_ZLEN;
memset((char *)p->xmit_cbuffs[p->xmit_count]+skb->len, 0, len - skb->len);
}
#if (NUM_XMIT_BUFFS == 1) #if (NUM_XMIT_BUFFS == 1)
# ifdef NO_NOPCOMMANDS # ifdef NO_NOPCOMMANDS
......
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