summaryrefslogtreecommitdiffstats
path: root/sys/i386/isa
diff options
context:
space:
mode:
authorwollman <wollman@FreeBSD.org>1996-12-13 21:29:07 +0000
committerwollman <wollman@FreeBSD.org>1996-12-13 21:29:07 +0000
commit3417f9411098d1cd19c5db539c0768e778b83a1c (patch)
tree782c07e423375f5e3235e7a677261301a91e59c6 /sys/i386/isa
parent4ad813db29ba756a35db6540961c86a4c1f5592b (diff)
downloadFreeBSD-src-3417f9411098d1cd19c5db539c0768e778b83a1c.zip
FreeBSD-src-3417f9411098d1cd19c5db539c0768e778b83a1c.tar.gz
Convert the interface address and IP interface address structures
to TAILQs. Fix places which referenced these for no good reason that I can see (the references remain, but were fixed to compile again; they are still questionable).
Diffstat (limited to 'sys/i386/isa')
-rw-r--r--sys/i386/isa/if_ed.c4
-rw-r--r--sys/i386/isa/if_el.c19
-rw-r--r--sys/i386/isa/if_ep.c21
-rw-r--r--sys/i386/isa/if_fe.c4
-rw-r--r--sys/i386/isa/if_lnc.c2
-rw-r--r--sys/i386/isa/if_ze.c4
-rw-r--r--sys/i386/isa/if_zp.c4
7 files changed, 12 insertions, 46 deletions
diff --git a/sys/i386/isa/if_ed.c b/sys/i386/isa/if_ed.c
index 6bed04e..95a4859 100644
--- a/sys/i386/isa/if_ed.c
+++ b/sys/i386/isa/if_ed.c
@@ -24,7 +24,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: if_ed.c,v 1.109 1996/12/03 16:08:00 phk Exp $
+ * $Id: if_ed.c,v 1.110 1996/12/10 07:29:39 davidg Exp $
*/
/*
@@ -1872,7 +1872,7 @@ ed_init(xsc)
return;
/* address not known */
- if (ifp->if_addrlist == (struct ifaddr *) 0)
+ if (TAILQ_EMPTY(&ifp->if_addrhead)) /* unlikely? XXX */
return;
/*
diff --git a/sys/i386/isa/if_el.c b/sys/i386/isa/if_el.c
index afa08ae..3338aee 100644
--- a/sys/i386/isa/if_el.c
+++ b/sys/i386/isa/if_el.c
@@ -6,7 +6,7 @@
*
* Questions, comments, bug reports and fixes to kimmel@cs.umass.edu.
*
- * $Id: if_el.c,v 1.25 1996/08/06 21:14:04 phk Exp $
+ * $Id: if_el.c,v 1.26 1996/09/06 23:07:32 phk Exp $
*/
/* Except of course for the portions of code lifted from other FreeBSD
* drivers (mainly elread, elget and el_ioctl)
@@ -191,21 +191,6 @@ el_attach(struct isa_device *idev)
if_attach(ifp);
ether_ifattach(ifp);
- /* Put the station address in the ifa address list's AF_LINK
- * entry, if any.
- */
- ifa = ifp->if_addrlist;
- while ((ifa != NULL) && (ifa->ifa_addr != NULL) &&
- (ifa->ifa_addr->sa_family != AF_LINK))
- ifa = ifa->ifa_next;
- if((ifa != NULL) && (ifa->ifa_addr != NULL)) {
- sdl = (struct sockaddr_dl *)ifa->ifa_addr;
- sdl->sdl_type = IFT_ETHER;
- sdl->sdl_alen = ETHER_ADDR_LEN;
- sdl->sdl_slen = 0;
- bcopy(sc->arpcom.ac_enaddr,LLADDR(sdl),ETHER_ADDR_LEN);
- }
-
/* Print out some information for the user */
printf("el%d: 3c501 address %6D\n",idev->id_unit,
sc->arpcom.ac_enaddr, ":");
@@ -278,7 +263,7 @@ el_init(int unit)
base = sc->el_base;
/* If address not known, do nothing. */
- if(ifp->if_addrlist == (struct ifaddr *)0)
+ if(TAILQ_EMPTY(&ifp->if_addrhead)) /* XXX unlikely */
return;
s = splimp();
diff --git a/sys/i386/isa/if_ep.c b/sys/i386/isa/if_ep.c
index 7840e8b..6efbe85 100644
--- a/sys/i386/isa/if_ep.c
+++ b/sys/i386/isa/if_ep.c
@@ -38,7 +38,7 @@
*/
/*
- * $Id: if_ep.c,v 1.52 1996/07/27 12:40:31 amurai Exp $
+ * $Id: if_ep.c,v 1.53 1996/09/06 23:07:33 phk Exp $
*
* Promiscuous mode added and interrupt logic slightly changed
* to reduce the number of adapter failures. Transceiver select
@@ -655,25 +655,6 @@ ep_attach(sc)
ether_ifattach(ifp);
}
- /* device attach does transition from UNCONFIGURED to IDLE state */
-
- /*
- * Fill the hardware address into ifa_addr if we find an AF_LINK entry.
- * We need to do this so bpf's can get the hardware addr of this card.
- * netstat likes this too!
- */
- ifa = ifp->if_addrlist;
- while ((ifa != 0) && (ifa->ifa_addr != 0) &&
- (ifa->ifa_addr->sa_family != AF_LINK))
- ifa = ifa->ifa_next;
-
- if ((ifa != 0) && (ifa->ifa_addr != 0)) {
- sdl = (struct sockaddr_dl *) ifa->ifa_addr;
- sdl->sdl_type = IFT_ETHER;
- sdl->sdl_alen = ETHER_ADDR_LEN;
- sdl->sdl_slen = 0;
- bcopy(sc->arpcom.ac_enaddr, LLADDR(sdl), ETHER_ADDR_LEN);
- }
/* we give some initial parameters */
sc->rx_avg_pkt = 128;
diff --git a/sys/i386/isa/if_fe.c b/sys/i386/isa/if_fe.c
index a8fdc3c..9c2cf8e 100644
--- a/sys/i386/isa/if_fe.c
+++ b/sys/i386/isa/if_fe.c
@@ -21,7 +21,7 @@
*/
/*
- * $Id: if_fe.c,v 1.20 1996/10/07 17:50:00 wollman Exp $
+ * $Id: if_fe.c,v 1.21 1996/11/15 16:15:56 wollman Exp $
*
* Device driver for Fujitsu MB86960A/MB86965A based Ethernet cards.
* To be used with FreeBSD 2.x
@@ -1701,7 +1701,7 @@ fe_init ( int unit )
#endif
/* We need an address. */
- if (sc->sc_if.if_addrlist == 0) {
+ if (TAILQ_EMPTY(&sc->sc_if.if_addrhead)) { /* XXX unlikely */
#if FE_DEBUG >= 1
log( LOG_ERR, "fe%d: init() without any address\n",
sc->sc_unit );
diff --git a/sys/i386/isa/if_lnc.c b/sys/i386/isa/if_lnc.c
index 20201e4..0df6bbe 100644
--- a/sys/i386/isa/if_lnc.c
+++ b/sys/i386/isa/if_lnc.c
@@ -1212,7 +1212,7 @@ lnc_init(struct lnc_softc *sc)
/* Check that interface has valid address */
- if (!sc->arpcom.ac_if.if_addrlist)
+ if (TAILQ_EMPTY(&sc->arpcom.ac_if.if_addrhead)) /* XXX unlikely */
return;
/* Shut down interface */
diff --git a/sys/i386/isa/if_ze.c b/sys/i386/isa/if_ze.c
index 7eb6abe..1b7e1ab 100644
--- a/sys/i386/isa/if_ze.c
+++ b/sys/i386/isa/if_ze.c
@@ -47,7 +47,7 @@
*/
/*
- * $Id: if_ze.c,v 1.32 1996/07/12 04:11:23 bde Exp $
+ * $Id: if_ze.c,v 1.33 1996/08/06 21:14:11 phk Exp $
*/
#include "ze.h"
@@ -763,7 +763,7 @@ ze_init(unit)
Debugger("here!!");
ze_setup(sc);
/* address not known */
- if (ifp->if_addrlist == (struct ifaddr *)0) return;
+ if (TAILQ_EMPTY(&ifp->if_addrhead)) return; /* XXX unlikely! */
/*
* Initialize the NIC in the exact order outlined in the NS manual.
diff --git a/sys/i386/isa/if_zp.c b/sys/i386/isa/if_zp.c
index f4b1a7b..d76bd88 100644
--- a/sys/i386/isa/if_zp.c
+++ b/sys/i386/isa/if_zp.c
@@ -34,7 +34,7 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* From: if_ep.c,v 1.9 1994/01/25 10:46:29 deraadt Exp $
- * $Id: if_zp.c,v 1.26 1996/09/11 16:11:21 nate Exp $
+ * $Id: if_zp.c,v 1.27 1996/11/11 17:11:08 bde Exp $
*/
/*-
* TODO:
@@ -581,7 +581,7 @@ zpinit(unit)
register struct ifnet *ifp = &sc->arpcom.ac_if;
int s, i;
- if (ifp->if_addrlist == (struct ifaddr *) 0)
+ if (TAILQ_EMPTY(&ifp->if_addrhead)) /* XXX unlikely */
return;
s = splimp();
OpenPOWER on IntegriCloud