patch-1.3.7 linux/drivers/net/3c505.c

Next file: linux/drivers/net/3c507.c
Previous file: linux/drivers/net/3c501.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.6/linux/drivers/net/3c505.c linux/drivers/net/3c505.c
@@ -560,7 +560,7 @@
 
 	rlen = (len+1) & ~1;
 
-	skb = dev_alloc_skb(rlen);
+	skb = dev_alloc_skb(rlen+2);
 
 	/*
 	 * make sure the data register is going the right way
@@ -587,6 +587,7 @@
 		adapter->stats.rx_dropped++;
 
 	} else {
+		skb_reserve(skb,2);	/* 16 byte alignment */
 		skb->dev = dev;
 
 		/*

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