diff options
author | phk <phk@FreeBSD.org> | 2001-02-03 16:29:10 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2001-02-03 16:29:10 +0000 |
commit | 408a00d7df90965db4085ccfd67356bf3f7c38ee (patch) | |
tree | 4ad9050dfc339204ebef2be568d2128e1bbf4da8 /sys/pci/if_dc.c | |
parent | 2ef21ddcb983700a744a68bdc09d4328d1af0d71 (diff) | |
download | FreeBSD-src-408a00d7df90965db4085ccfd67356bf3f7c38ee.zip FreeBSD-src-408a00d7df90965db4085ccfd67356bf3f7c38ee.tar.gz |
Use LIST_FOREACH() to traverse ifp->if_multiaddrs list, instead of
<sys/queue.h> implementation details.
Created with: /usr/sbin/sed
Reviewed with: /sbin/md5
Diffstat (limited to 'sys/pci/if_dc.c')
-rw-r--r-- | sys/pci/if_dc.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/sys/pci/if_dc.c b/sys/pci/if_dc.c index 0745fde..f66e65d 100644 --- a/sys/pci/if_dc.c +++ b/sys/pci/if_dc.c @@ -1051,8 +1051,7 @@ void dc_setfilt_21143(sc) else DC_CLRBIT(sc, DC_NETCFG, DC_NETCFG_RX_ALLMULTI); - for (ifma = ifp->if_multiaddrs.lh_first; ifma != NULL; - ifma = ifma->ifma_link.le_next) { + LIST_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) { if (ifma->ifma_addr->sa_family != AF_LINK) continue; h = dc_crc_le(sc, @@ -1123,8 +1122,7 @@ void dc_setfilt_admtek(sc) return; /* now program new ones */ - for (ifma = ifp->if_multiaddrs.lh_first; ifma != NULL; - ifma = ifma->ifma_link.le_next) { + LIST_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) { if (ifma->ifma_addr->sa_family != AF_LINK) continue; h = dc_crc_be(LLADDR((struct sockaddr_dl *)ifma->ifma_addr)); @@ -1192,8 +1190,7 @@ void dc_setfilt_asix(sc) return; /* now program new ones */ - for (ifma = ifp->if_multiaddrs.lh_first; ifma != NULL; - ifma = ifma->ifma_link.le_next) { + LIST_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) { if (ifma->ifma_addr->sa_family != AF_LINK) continue; h = dc_crc_be(LLADDR((struct sockaddr_dl *)ifma->ifma_addr)); @@ -1247,8 +1244,7 @@ void dc_setfilt_xircom(sc) else DC_CLRBIT(sc, DC_NETCFG, DC_NETCFG_RX_ALLMULTI); - for (ifma = ifp->if_multiaddrs.lh_first; ifma != NULL; - ifma = ifma->ifma_link.le_next) { + LIST_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) { if (ifma->ifma_addr->sa_family != AF_LINK) continue; h = dc_crc_le(sc, |