diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-03-02 07:55:08 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-03-02 07:55:08 -0800 |
commit | 6d6b89bd2e316b78d668f761d380837b81fa71ef (patch) | |
tree | 7e63c58611fc6181153526abbdafdd846ed1a19d /drivers/net/lp486e.c | |
parent | 13dda80e48439b446d0bc9bab34b91484bc8f533 (diff) | |
parent | 2507c05ff55fbf38326b08ed27eaed233bc75042 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1341 commits)
virtio_net: remove forgotten assignment
be2net: fix tx completion polling
sis190: fix cable detect via link status poll
net: fix protocol sk_buff field
bridge: Fix build error when IGMP_SNOOPING is not enabled
bnx2x: Tx barriers and locks
scm: Only support SCM_RIGHTS on unix domain sockets.
vhost-net: restart tx poll on sk_sndbuf full
vhost: fix get_user_pages_fast error handling
vhost: initialize log eventfd context pointer
vhost: logging thinko fix
wireless: convert to use netdev_for_each_mc_addr
ethtool: do not set some flags, if others failed
ipoib: returned back addrlen check for mc addresses
netlink: Adding inode field to /proc/net/netlink
axnet_cs: add new id
bridge: Make IGMP snooping depend upon BRIDGE.
bridge: Add multicast count/interval sysfs entries
bridge: Add hash elasticity/max sysfs entries
bridge: Add multicast_snooping sysfs toggle
...
Trivial conflicts in Documentation/feature-removal-schedule.txt
Diffstat (limited to 'drivers/net/lp486e.c')
-rw-r--r-- | drivers/net/lp486e.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/drivers/net/lp486e.c b/drivers/net/lp486e.c index e20fefc73c8..3e3cc04defd 100644 --- a/drivers/net/lp486e.c +++ b/drivers/net/lp486e.c @@ -1253,21 +1253,22 @@ static void set_multicast_list(struct net_device *dev) { if (i596_debug > 1) printk ("%s: set multicast list %d\n", - dev->name, dev->mc_count); + dev->name, netdev_mc_count(dev)); - if (dev->mc_count > 0) { + if (!netdev_mc_empty(dev)) { struct dev_mc_list *dmi; char *cp; - cmd = kmalloc(sizeof(struct i596_cmd)+2+dev->mc_count*6, GFP_ATOMIC); + cmd = kmalloc(sizeof(struct i596_cmd) + 2 + + netdev_mc_count(dev) * 6, GFP_ATOMIC); if (cmd == NULL) { printk (KERN_ERR "%s: set_multicast Memory squeeze.\n", dev->name); return; } cmd->command = CmdMulticastList; - *((unsigned short *) (cmd + 1)) = dev->mc_count * 6; + *((unsigned short *) (cmd + 1)) = netdev_mc_count(dev) * 6; cp = ((char *)(cmd + 1))+2; - for (dmi = dev->mc_list; dmi != NULL; dmi = dmi->next) { - memcpy(cp, dmi,6); + netdev_for_each_mc_addr(dmi, dev) { + memcpy(cp, dmi->dmi_addr, 6); cp += 6; } if (i596_debug & LOG_SRCDST) @@ -1277,7 +1278,8 @@ static void set_multicast_list(struct net_device *dev) { if (lp->set_conf.pa_next != I596_NULL) { return; } - if (dev->mc_count == 0 && !(dev->flags & (IFF_PROMISC | IFF_ALLMULTI))) { + if (netdev_mc_empty(dev) && + !(dev->flags & (IFF_PROMISC | IFF_ALLMULTI))) { lp->i596_config[8] &= ~0x01; } else { lp->i596_config[8] |= 0x01; |