aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/r6040.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2010-10-21 11:43:05 -0400
committerDavid S. Miller <davem@davemloft.net>2010-10-21 11:43:05 -0400
commit2198a10b501fd4443430cb17e065a9e859cc58c9 (patch)
tree87f3781d293da0f8f8f61615905eb7bf62b7c128 /drivers/net/r6040.c
parent9941fb62762253774cc6177d0b9172ece5133fe1 (diff)
parentdb5a753bf198ef7a50e17d2ff358adf37efe8648 (diff)
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts: net/core/dev.c
Diffstat (limited to 'drivers/net/r6040.c')
-rw-r--r--drivers/net/r6040.c22
1 files changed, 12 insertions, 10 deletions
diff --git a/drivers/net/r6040.c b/drivers/net/r6040.c
index 68a84198eb05..0b014c894686 100644
--- a/drivers/net/r6040.c
+++ b/drivers/net/r6040.c
@@ -908,16 +908,18 @@ static void r6040_multicast_list(struct net_device *dev)
908 /* Multicast Address 1~4 case */ 908 /* Multicast Address 1~4 case */
909 i = 0; 909 i = 0;
910 netdev_for_each_mc_addr(ha, dev) { 910 netdev_for_each_mc_addr(ha, dev) {
911 if (i < MCAST_MAX) { 911 if (i >= MCAST_MAX)
912 adrp = (u16 *) ha->addr; 912 break;
913 iowrite16(adrp[0], ioaddr + MID_1L + 8 * i); 913 adrp = (u16 *) ha->addr;
914 iowrite16(adrp[1], ioaddr + MID_1M + 8 * i); 914 iowrite16(adrp[0], ioaddr + MID_1L + 8 * i);
915 iowrite16(adrp[2], ioaddr + MID_1H + 8 * i); 915 iowrite16(adrp[1], ioaddr + MID_1M + 8 * i);
916 } else { 916 iowrite16(adrp[2], ioaddr + MID_1H + 8 * i);
917 iowrite16(0xffff, ioaddr + MID_1L + 8 * i); 917 i++;
918 iowrite16(0xffff, ioaddr + MID_1M + 8 * i); 918 }
919 iowrite16(0xffff, ioaddr + MID_1H + 8 * i); 919 while (i < MCAST_MAX) {
920 } 920 iowrite16(0xffff, ioaddr + MID_1L + 8 * i);
921 iowrite16(0xffff, ioaddr + MID_1M + 8 * i);
922 iowrite16(0xffff, ioaddr + MID_1H + 8 * i);
921 i++; 923 i++;
922 } 924 }
923} 925}