patch-2.4.21 linux-2.4.21/drivers/net/lp486e.c
Next file: linux-2.4.21/drivers/net/mac8390.c
Previous file: linux-2.4.21/drivers/net/lasi_82596.c
Back to the patch index
Back to the overall index
- Lines: 18
- Date:
2003-06-13 07:51:35.000000000 -0700
- Orig file:
linux-2.4.20/drivers/net/lp486e.c
- Orig date:
2001-09-30 12:26:06.000000000 -0700
diff -urN linux-2.4.20/drivers/net/lp486e.c linux-2.4.21/drivers/net/lp486e.c
@@ -886,7 +886,16 @@
if (skb->len <= 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;
tx_cmd = (struct tx_cmd *)
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)