aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/sonic.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/sonic.c')
-rw-r--r--drivers/net/sonic.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/net/sonic.c b/drivers/net/sonic.c
index 9599ce77ef85..bd8bc66f2e00 100644
--- a/drivers/net/sonic.c
+++ b/drivers/net/sonic.c
@@ -541,13 +541,15 @@ static void sonic_multicast_list(struct net_device *dev)
541 if (dev->flags & IFF_PROMISC) { /* set promiscuous mode */ 541 if (dev->flags & IFF_PROMISC) { /* set promiscuous mode */
542 rcr |= SONIC_RCR_PRO; 542 rcr |= SONIC_RCR_PRO;
543 } else { 543 } else {
544 if ((dev->flags & IFF_ALLMULTI) || (dev->mc_count > 15)) { 544 if ((dev->flags & IFF_ALLMULTI) ||
545 (netdev_mc_count(dev) > 15)) {
545 rcr |= SONIC_RCR_AMC; 546 rcr |= SONIC_RCR_AMC;
546 } else { 547 } else {
547 if (sonic_debug > 2) 548 if (sonic_debug > 2)
548 printk("sonic_multicast_list: mc_count %d\n", dev->mc_count); 549 printk("sonic_multicast_list: mc_count %d\n",
550 netdev_mc_count(dev));
549 sonic_set_cam_enable(dev, 1); /* always enable our own address */ 551 sonic_set_cam_enable(dev, 1); /* always enable our own address */
550 for (i = 1; i <= dev->mc_count; i++) { 552 for (i = 1; i <= netdev_mc_count(dev); i++) {
551 addr = dmi->dmi_addr; 553 addr = dmi->dmi_addr;
552 dmi = dmi->next; 554 dmi = dmi->next;
553 sonic_cda_put(dev, i, SONIC_CD_CAP0, addr[1] << 8 | addr[0]); 555 sonic_cda_put(dev, i, SONIC_CD_CAP0, addr[1] << 8 | addr[0]);