patch-1.3.7 linux/drivers/net/3c507.c
Next file: linux/drivers/net/3c509.c
Previous file: linux/drivers/net/3c505.c
Back to the patch index
Back to the overall index
- Lines: 17
- Date:
Wed Jul 5 13:06:26 1995
- Orig file:
v1.3.6/linux/drivers/net/3c507.c
- Orig date:
Fri Jun 30 16:22:26 1995
diff -u --recursive --new-file v1.3.6/linux/drivers/net/3c507.c linux/drivers/net/3c507.c
@@ -835,13 +835,14 @@
struct sk_buff *skb;
pkt_len &= 0x3fff;
- skb = dev_alloc_skb(pkt_len);
+ skb = dev_alloc_skb(pkt_len+2);
if (skb == NULL) {
printk("%s: Memory squeeze, dropping packet.\n", dev->name);
lp->stats.rx_dropped++;
break;
}
- skb->len = pkt_len;
+
+ skb_reserve(skb,2);
skb->dev = dev;
/* 'skb->data' points to the start of sk_buff data area. */
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov
with Sam's (original) version of this