Deleted Added
full compact
if_ie.c (3713) if_ie.c (3816)
1/*-
2 * Copyright (c) 1992, 1993, University of Vermont and State
3 * Agricultural College.
4 * Copyright (c) 1992, 1993, Garrett A. Wollman.
5 *
6 * Portions:
7 * Copyright (c) 1990, 1991, William F. Jolitz
8 * Copyright (c) 1990, The Regents of the University of California

--- 29 unchanged lines hidden (view full) ---

38 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
39 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
40 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
41 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
42 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
43 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
44 * SUCH DAMAGE.
45 *
1/*-
2 * Copyright (c) 1992, 1993, University of Vermont and State
3 * Agricultural College.
4 * Copyright (c) 1992, 1993, Garrett A. Wollman.
5 *
6 * Portions:
7 * Copyright (c) 1990, 1991, William F. Jolitz
8 * Copyright (c) 1990, The Regents of the University of California

--- 29 unchanged lines hidden (view full) ---

38 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
39 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
40 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
41 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
42 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
43 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
44 * SUCH DAMAGE.
45 *
46 * $Id: if_ie.c,v 1.15 1994/09/07 03:34:12 wollman Exp $
46 * $Id: if_ie.c,v 1.16 1994/10/19 01:59:00 wollman Exp $
47 */
48
49/*
50 * Intel 82586 Ethernet chip
51 * Register, bit, and structure definitions.
52 *
53 * Written by GAW with reference to the Clarkson Packet Driver code for this
54 * chip written by Russ Nelson and others.

--- 248 unchanged lines hidden (view full) ---

303#define MEM ie_softc[unit].iomem
304
305static int sl_probe(struct isa_device *);
306static int el_probe(struct isa_device *);
307static int ni_probe(struct isa_device *);
308
309static struct kern_devconf kdc_ie[NIE] = { {
310 0, 0, 0, /* filled in by dev_attach */
47 */
48
49/*
50 * Intel 82586 Ethernet chip
51 * Register, bit, and structure definitions.
52 *
53 * Written by GAW with reference to the Clarkson Packet Driver code for this
54 * chip written by Russ Nelson and others.

--- 248 unchanged lines hidden (view full) ---

303#define MEM ie_softc[unit].iomem
304
305static int sl_probe(struct isa_device *);
306static int el_probe(struct isa_device *);
307static int ni_probe(struct isa_device *);
308
309static struct kern_devconf kdc_ie[NIE] = { {
310 0, 0, 0, /* filled in by dev_attach */
311 "ie", 0, { "isa0", MDDT_ISA, 0 },
312 isa_generic_externalize, 0, 0, ISA_EXTERNALLEN
311 "ie", 0, { MDDT_ISA, 0, "net" },
312 isa_generic_externalize, 0, 0, ISA_EXTERNALLEN,
313 &kdc_isa0, /* parent */
314 0, /* parentdata */
315 DC_BUSY, /* network interfaces are always ``busy'' */
316 ""
313} };
314
315static inline void
317} };
318
319static inline void
316ie_registerdev(struct isa_device *id)
320ie_registerdev(struct isa_device *id, const char *descr)
317{
318 if(id->id_unit)
319 kdc_ie[id->id_unit] = kdc_ie[0];
320 kdc_ie[id->id_unit].kdc_unit = id->id_unit;
321 kdc_ie[id->id_unit].kdc_isa = id;
321{
322 if(id->id_unit)
323 kdc_ie[id->id_unit] = kdc_ie[0];
324 kdc_ie[id->id_unit].kdc_unit = id->id_unit;
325 kdc_ie[id->id_unit].kdc_isa = id;
326 kdc_ie[id->id_unit].kdc_description = descr;
322 dev_attach(&kdc_ie[id->id_unit]);
323}
324
325/* This routine written by Charles Martin Hannum. */
326int ieprobe(dvp)
327 struct isa_device *dvp;
328{
329 int ret;

--- 251 unchanged lines hidden (view full) ---

581 ifp->if_hdrlen = 14;
582
583#if NBPFILTER > 0
584 bpfattach(&ie_softc[unit].ie_bpf, ifp, DLT_EN10MB,
585 sizeof(struct ether_header));
586#endif
587
588 if_attach(ifp);
327 dev_attach(&kdc_ie[id->id_unit]);
328}
329
330/* This routine written by Charles Martin Hannum. */
331int ieprobe(dvp)
332 struct isa_device *dvp;
333{
334 int ret;

--- 251 unchanged lines hidden (view full) ---

586 ifp->if_hdrlen = 14;
587
588#if NBPFILTER > 0
589 bpfattach(&ie_softc[unit].ie_bpf, ifp, DLT_EN10MB,
590 sizeof(struct ether_header));
591#endif
592
593 if_attach(ifp);
589 ie_registerdev(dvp);
594 ie_registerdev(dvp, ie_hardware_names[ie_softc[unit].hard_type]);
590
591 {
592 struct ifaddr *ifa = ifp->if_addrlist;
593 struct sockaddr_dl *sdl;
594 while(ifa && ifa->ifa_addr && ifa->ifa_addr->sa_family != AF_LINK)
595 ifa = ifa->ifa_next;
596
597 if(!ifa || !ifa->ifa_addr) return 1;

--- 1422 unchanged lines hidden ---
595
596 {
597 struct ifaddr *ifa = ifp->if_addrlist;
598 struct sockaddr_dl *sdl;
599 while(ifa && ifa->ifa_addr && ifa->ifa_addr->sa_family != AF_LINK)
600 ifa = ifa->ifa_next;
601
602 if(!ifa || !ifa->ifa_addr) return 1;

--- 1422 unchanged lines hidden ---