aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/tokenring
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/tokenring')
-rw-r--r--drivers/net/tokenring/3c359.c5
-rw-r--r--drivers/net/tokenring/ibmtr.c4
-rw-r--r--drivers/net/tokenring/lanstreamer.c4
-rw-r--r--drivers/net/tokenring/olympic.c5
-rw-r--r--drivers/net/tokenring/tms380tr.c8
5 files changed, 9 insertions, 17 deletions
diff --git a/drivers/net/tokenring/3c359.c b/drivers/net/tokenring/3c359.c
index eff68e1d107b..0fb930feea45 100644
--- a/drivers/net/tokenring/3c359.c
+++ b/drivers/net/tokenring/3c359.c
@@ -1390,10 +1390,9 @@ static int xl_close(struct net_device *dev)
1390static void xl_set_rx_mode(struct net_device *dev) 1390static void xl_set_rx_mode(struct net_device *dev)
1391{ 1391{
1392 struct xl_private *xl_priv = netdev_priv(dev); 1392 struct xl_private *xl_priv = netdev_priv(dev);
1393 struct dev_mc_list *dmi ; 1393 struct dev_mc_list *dmi;
1394 unsigned char dev_mc_address[4] ; 1394 unsigned char dev_mc_address[4] ;
1395 u16 options ; 1395 u16 options ;
1396 int i ;
1397 1396
1398 if (dev->flags & IFF_PROMISC) 1397 if (dev->flags & IFF_PROMISC)
1399 options = 0x0004 ; 1398 options = 0x0004 ;
@@ -1408,7 +1407,7 @@ static void xl_set_rx_mode(struct net_device *dev)
1408 1407
1409 dev_mc_address[0] = dev_mc_address[1] = dev_mc_address[2] = dev_mc_address[3] = 0 ; 1408 dev_mc_address[0] = dev_mc_address[1] = dev_mc_address[2] = dev_mc_address[3] = 0 ;
1410 1409
1411 for (i=0,dmi=dev->mc_list;i < netdev_mc_count(dev); i++,dmi = dmi->next) { 1410 netdev_for_each_mc_addr(dmi, dev) {
1412 dev_mc_address[0] |= dmi->dmi_addr[2] ; 1411 dev_mc_address[0] |= dmi->dmi_addr[2] ;
1413 dev_mc_address[1] |= dmi->dmi_addr[3] ; 1412 dev_mc_address[1] |= dmi->dmi_addr[3] ;
1414 dev_mc_address[2] |= dmi->dmi_addr[4] ; 1413 dev_mc_address[2] |= dmi->dmi_addr[4] ;
diff --git a/drivers/net/tokenring/ibmtr.c b/drivers/net/tokenring/ibmtr.c
index 1ce8f85a89aa..1a0967246e2f 100644
--- a/drivers/net/tokenring/ibmtr.c
+++ b/drivers/net/tokenring/ibmtr.c
@@ -995,13 +995,11 @@ static void tok_set_multicast_list(struct net_device *dev)
995 /*BMS ifconfig tr down or hot unplug a PCMCIA card ??hownowbrowncow*/ 995 /*BMS ifconfig tr down or hot unplug a PCMCIA card ??hownowbrowncow*/
996 if (/*BMSHELPdev->start == 0 ||*/ ti->open_status != OPEN) return; 996 if (/*BMSHELPdev->start == 0 ||*/ ti->open_status != OPEN) return;
997 address[0] = address[1] = address[2] = address[3] = 0; 997 address[0] = address[1] = address[2] = address[3] = 0;
998 mclist = dev->mc_list; 998 netdev_for_each_mc_addr(mclist, dev) {
999 for (i = 0; i < netdev_mc_count(dev); i++) {
1000 address[0] |= mclist->dmi_addr[2]; 999 address[0] |= mclist->dmi_addr[2];
1001 address[1] |= mclist->dmi_addr[3]; 1000 address[1] |= mclist->dmi_addr[3];
1002 address[2] |= mclist->dmi_addr[4]; 1001 address[2] |= mclist->dmi_addr[4];
1003 address[3] |= mclist->dmi_addr[5]; 1002 address[3] |= mclist->dmi_addr[5];
1004 mclist = mclist->next;
1005 } 1003 }
1006 SET_PAGE(ti->srb_page); 1004 SET_PAGE(ti->srb_page);
1007 for (i = 0; i < sizeof(struct srb_set_funct_addr); i++) 1005 for (i = 0; i < sizeof(struct srb_set_funct_addr); i++)
diff --git a/drivers/net/tokenring/lanstreamer.c b/drivers/net/tokenring/lanstreamer.c
index 26d84daf660b..dd028fee9dc2 100644
--- a/drivers/net/tokenring/lanstreamer.c
+++ b/drivers/net/tokenring/lanstreamer.c
@@ -1268,7 +1268,6 @@ static void streamer_set_rx_mode(struct net_device *dev)
1268 __u8 options = 0; 1268 __u8 options = 0;
1269 struct dev_mc_list *dmi; 1269 struct dev_mc_list *dmi;
1270 unsigned char dev_mc_address[5]; 1270 unsigned char dev_mc_address[5];
1271 int i;
1272 1271
1273 writel(streamer_priv->srb, streamer_mmio + LAPA); 1272 writel(streamer_priv->srb, streamer_mmio + LAPA);
1274 options = streamer_priv->streamer_copy_all_options; 1273 options = streamer_priv->streamer_copy_all_options;
@@ -1303,8 +1302,7 @@ static void streamer_set_rx_mode(struct net_device *dev)
1303 writel(streamer_priv->srb,streamer_mmio+LAPA); 1302 writel(streamer_priv->srb,streamer_mmio+LAPA);
1304 dev_mc_address[0] = dev_mc_address[1] = dev_mc_address[2] = dev_mc_address[3] = 0 ; 1303 dev_mc_address[0] = dev_mc_address[1] = dev_mc_address[2] = dev_mc_address[3] = 0 ;
1305 1304
1306 for (i=0,dmi=dev->mc_list;i < netdev_mc_count(dev); i++,dmi = dmi->next) 1305 netdev_for_each_mc_addr(dmi, dev) {
1307 {
1308 dev_mc_address[0] |= dmi->dmi_addr[2] ; 1306 dev_mc_address[0] |= dmi->dmi_addr[2] ;
1309 dev_mc_address[1] |= dmi->dmi_addr[3] ; 1307 dev_mc_address[1] |= dmi->dmi_addr[3] ;
1310 dev_mc_address[2] |= dmi->dmi_addr[4] ; 1308 dev_mc_address[2] |= dmi->dmi_addr[4] ;
diff --git a/drivers/net/tokenring/olympic.c b/drivers/net/tokenring/olympic.c
index a242d125b34c..3a25e0434ae2 100644
--- a/drivers/net/tokenring/olympic.c
+++ b/drivers/net/tokenring/olympic.c
@@ -1139,9 +1139,8 @@ static void olympic_set_rx_mode(struct net_device *dev)
1139 u8 __iomem *olympic_mmio = olympic_priv->olympic_mmio ; 1139 u8 __iomem *olympic_mmio = olympic_priv->olympic_mmio ;
1140 u8 options = 0; 1140 u8 options = 0;
1141 u8 __iomem *srb; 1141 u8 __iomem *srb;
1142 struct dev_mc_list *dmi ; 1142 struct dev_mc_list *dmi;
1143 unsigned char dev_mc_address[4] ; 1143 unsigned char dev_mc_address[4] ;
1144 int i ;
1145 1144
1146 writel(olympic_priv->srb,olympic_mmio+LAPA); 1145 writel(olympic_priv->srb,olympic_mmio+LAPA);
1147 srb=olympic_priv->olympic_lap + (olympic_priv->srb & (~0xf800)); 1146 srb=olympic_priv->olympic_lap + (olympic_priv->srb & (~0xf800));
@@ -1178,7 +1177,7 @@ static void olympic_set_rx_mode(struct net_device *dev)
1178 1177
1179 dev_mc_address[0] = dev_mc_address[1] = dev_mc_address[2] = dev_mc_address[3] = 0 ; 1178 dev_mc_address[0] = dev_mc_address[1] = dev_mc_address[2] = dev_mc_address[3] = 0 ;
1180 1179
1181 for (i=0,dmi=dev->mc_list;i < netdev_mc_count(dev); i++,dmi = dmi->next) { 1180 netdev_for_each_mc_addr(dmi, dev) {
1182 dev_mc_address[0] |= dmi->dmi_addr[2] ; 1181 dev_mc_address[0] |= dmi->dmi_addr[2] ;
1183 dev_mc_address[1] |= dmi->dmi_addr[3] ; 1182 dev_mc_address[1] |= dmi->dmi_addr[3] ;
1184 dev_mc_address[2] |= dmi->dmi_addr[4] ; 1183 dev_mc_address[2] |= dmi->dmi_addr[4] ;
diff --git a/drivers/net/tokenring/tms380tr.c b/drivers/net/tokenring/tms380tr.c
index 6b8868959b85..21a01753312a 100644
--- a/drivers/net/tokenring/tms380tr.c
+++ b/drivers/net/tokenring/tms380tr.c
@@ -1212,10 +1212,9 @@ static void tms380tr_set_multicast_list(struct net_device *dev)
1212 } 1212 }
1213 else 1213 else
1214 { 1214 {
1215 int i; 1215 struct dev_mc_list *mclist;
1216 struct dev_mc_list *mclist = dev->mc_list; 1216
1217 for (i=0; i< netdev_mc_count(dev); i++) 1217 netdev_for_each_mc_addr(mclist, dev) {
1218 {
1219 ((char *)(&tp->ocpl.FunctAddr))[0] |= 1218 ((char *)(&tp->ocpl.FunctAddr))[0] |=
1220 mclist->dmi_addr[2]; 1219 mclist->dmi_addr[2];
1221 ((char *)(&tp->ocpl.FunctAddr))[1] |= 1220 ((char *)(&tp->ocpl.FunctAddr))[1] |=
@@ -1224,7 +1223,6 @@ static void tms380tr_set_multicast_list(struct net_device *dev)
1224 mclist->dmi_addr[4]; 1223 mclist->dmi_addr[4];
1225 ((char *)(&tp->ocpl.FunctAddr))[3] |= 1224 ((char *)(&tp->ocpl.FunctAddr))[3] |=
1226 mclist->dmi_addr[5]; 1225 mclist->dmi_addr[5];
1227 mclist = mclist->next;
1228 } 1226 }
1229 } 1227 }
1230 tms380tr_exec_cmd(dev, OC_SET_FUNCT_ADDR); 1228 tms380tr_exec_cmd(dev, OC_SET_FUNCT_ADDR);