Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
[safe/jmp/linux-2.6] / drivers / net / ni5010.c
index 6a87d81..4d3f2e2 100644 (file)
@@ -51,7 +51,6 @@
 #include <linux/string.h>
 #include <linux/errno.h>
 #include <linux/ioport.h>
-#include <linux/slab.h>
 #include <linux/interrupt.h>
 #include <linux/delay.h>
 #include <linux/init.h>
@@ -445,7 +444,7 @@ static void ni5010_timeout(struct net_device *dev)
        /* Try to restart the adaptor. */
        /* FIXME: Give it a real kick here */
        chipset_init(dev, 1);
-       dev->trans_start = jiffies;
+       dev->trans_start = jiffies; /* prevent tx timeout */
        netif_wake_queue(dev);
 }
 
@@ -461,7 +460,6 @@ static int ni5010_send_packet(struct sk_buff *skb, struct net_device *dev)
 
        netif_stop_queue(dev);
        hardware_send_packet(dev, (unsigned char *)skb->data, skb->len, length-skb->len);
-       dev->trans_start = jiffies;
        dev_kfree_skb (skb);
        return NETDEV_TX_OK;
 }
@@ -516,8 +514,6 @@ static void dump_packet(void *buf, int len)
                if (i % 16 == 15) printk("\n");
        }
        printk("\n");
-
-       return;
 }
 
 /* We have a good packet, get it out of the buffer. */
@@ -651,7 +647,8 @@ static void ni5010_set_multicast_list(struct net_device *dev)
 
        PRINTK2((KERN_DEBUG "%s: entering set_multicast_list\n", dev->name));
 
-       if (dev->flags&IFF_PROMISC || dev->flags&IFF_ALLMULTI || dev->mc_list) {
+       if (dev->flags & IFF_PROMISC || dev->flags & IFF_ALLMULTI ||
+           !netdev_mc_empty(dev)) {
                outb(RMD_PROMISC, EDLC_RMODE); /* Enable promiscuous mode */
                PRINTK((KERN_DEBUG "%s: Entering promiscuous mode\n", dev->name));
        } else {