patch-1.3.71 linux/net/core/dev.c

Next file: linux/net/core/sock.c
Previous file: linux/net/ax25/ax25_subr.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.70/linux/net/core/dev.c linux/net/core/dev.c
@@ -216,10 +216,10 @@
 
 extern __inline__ void dev_load(const char *name)
 {
-        const char *sptr;
- 
         if(!dev_get(name)) {
 #ifdef CONFIG_NET_ALIAS
+	        const char *sptr;
+ 
                 for (sptr=name ; *sptr ; sptr++) if(*sptr==':') break;
                 if (!(*sptr && *(sptr+1)))
 #endif
@@ -557,7 +557,7 @@
  *	mark_bh(NET_BH);
  */
  
-void net_bh(void *tmp)
+void net_bh(void)
 {
 	struct sk_buff *skb;
 	struct packet_type *ptype;
@@ -728,9 +728,11 @@
 	 */	 
 	for(i = 0;i < DEV_NUMBUFFS; i++,head++)
 	{
-		struct sk_buff *skb = skb_peek(head);
 
-		if (skb) {
+		while (!skb_queue_empty(head)) {
+			struct sk_buff *skb;
+
+			skb = head->next;
 			__skb_unlink(skb, head);
 			/*
 			 *	Stop anyone freeing the buffer while we retransmit it
@@ -1408,7 +1410,6 @@
 	net_alias_init();
 #endif
 
-	bh_base[NET_BH].routine = net_bh;
-	enable_bh(NET_BH);
+	init_bh(NET_BH, net_bh);
 	return 0;
 }

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