From 9b4679d8692d5d0ed06ccc7d097a873cccbf0d47 Mon Sep 17 00:00:00 2001 From: drochner Date: Sat, 20 Sep 1997 12:13:01 +0000 Subject: [PATCH] -Don't pass hardware address, it is not of much use for the kernel. -define "addr" differently for ISA and PCI devices - for PCI, it is (bus,device,function) now, in the format used by the PCI BIOS --- sys/arch/i386/stand/lib/netif/3c509.c | 6 +++--- sys/arch/i386/stand/lib/netif/3c590.c | 6 +++--- sys/arch/i386/stand/lib/netif/pcnet_isapnp.c | 6 +++--- sys/arch/i386/stand/lib/netif/pcnet_pci.c | 6 +++--- sys/arch/i386/stand/lib/netif/wd80x3.c | 6 +++--- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/sys/arch/i386/stand/lib/netif/3c509.c b/sys/arch/i386/stand/lib/netif/3c509.c index 0849a95962fa..3f5d180cbfc8 100644 --- a/sys/arch/i386/stand/lib/netif/3c509.c +++ b/sys/arch/i386/stand/lib/netif/3c509.c @@ -1,4 +1,4 @@ -/* $NetBSD: 3c509.c,v 1.3 1997/09/17 18:21:40 drochner Exp $ */ +/* $NetBSD: 3c509.c,v 1.4 1997/09/20 12:13:01 drochner Exp $ */ /* stripped down from freebsd:sys/i386/netboot/3c509.c */ @@ -158,13 +158,13 @@ ok: outw(BASE + EP_W2_ADDR_0 + (i * 2), help); } for(i = 0; i < 6; i++) - bi_netif.hw_addr[i] = myadr[i] = eth_myaddr[i]; + myadr[i] = eth_myaddr[i]; epreset(); strncpy(bi_netif.ifname, "ep", sizeof(bi_netif.ifname)); bi_netif.bus = BI_BUS_ISA; - bi_netif.addr = eth_base; + bi_netif.addr.iobase = eth_base; BI_ADD(&bi_netif, BTINFO_NETIF, sizeof(bi_netif)); diff --git a/sys/arch/i386/stand/lib/netif/3c590.c b/sys/arch/i386/stand/lib/netif/3c590.c index 8e5295a5c736..e9227328c65c 100644 --- a/sys/arch/i386/stand/lib/netif/3c590.c +++ b/sys/arch/i386/stand/lib/netif/3c590.c @@ -1,4 +1,4 @@ -/* $NetBSD: 3c590.c,v 1.6 1997/09/17 18:21:41 drochner Exp $ */ +/* $NetBSD: 3c590.c,v 1.7 1997/09/20 12:13:03 drochner Exp $ */ /* stripped down from freebsd:sys/i386/netboot/3c509.c */ @@ -137,14 +137,14 @@ ok: outw(BASE + EP_W2_ADDR_0 + (i * 2), help); } for(i = 0; i < 6; i++) - bi_netif.hw_addr[i] = myadr[i] = eth_myaddr[i]; + myadr[i] = eth_myaddr[i]; epreset(); strncpy(bi_netif.ifname, "ep", sizeof(bi_netif.ifname)); bi_netif.bus = BI_BUS_PCI; - bi_netif.addr = eth_base; + bi_netif.addr.tag = hdl; BI_ADD(&bi_netif, BTINFO_NETIF, sizeof(bi_netif)); diff --git a/sys/arch/i386/stand/lib/netif/pcnet_isapnp.c b/sys/arch/i386/stand/lib/netif/pcnet_isapnp.c index b40c99aa6375..329b55d1a0f5 100644 --- a/sys/arch/i386/stand/lib/netif/pcnet_isapnp.c +++ b/sys/arch/i386/stand/lib/netif/pcnet_isapnp.c @@ -1,4 +1,4 @@ -/* $NetBSD: pcnet_isapnp.c,v 1.3 1997/09/17 18:21:43 drochner Exp $ */ +/* $NetBSD: pcnet_isapnp.c,v 1.4 1997/09/20 12:13:04 drochner Exp $ */ /* * Copyright (c) 1996 @@ -79,7 +79,7 @@ char *myadr; am7990_stop(); for(i=0; i<6; i++) - bi_netif.hw_addr[i] = myadr[i] = eth_myaddr[i] = inb(iobase + i); + myadr[i] = eth_myaddr[i] = inb(iobase + i); isa_dmacascade(dmachan); @@ -87,7 +87,7 @@ char *myadr; strncpy(bi_netif.ifname, "le", sizeof(bi_netif.ifname)); bi_netif.bus = BI_BUS_ISA; - bi_netif.addr = iobase; + bi_netif.addr.iobase = iobase; BI_ADD(&bi_netif, BTINFO_NETIF, sizeof(bi_netif)); diff --git a/sys/arch/i386/stand/lib/netif/pcnet_pci.c b/sys/arch/i386/stand/lib/netif/pcnet_pci.c index c372a8b77ca2..8030be671714 100644 --- a/sys/arch/i386/stand/lib/netif/pcnet_pci.c +++ b/sys/arch/i386/stand/lib/netif/pcnet_pci.c @@ -1,4 +1,4 @@ -/* $NetBSD: pcnet_pci.c,v 1.3 1997/09/17 18:21:44 drochner Exp $ */ +/* $NetBSD: pcnet_pci.c,v 1.4 1997/09/20 12:13:05 drochner Exp $ */ /* * Copyright (c) 1996 @@ -91,13 +91,13 @@ char *myadr; } for(i=0; i<6; i++) - bi_netif.hw_addr[i] = myadr[i] = eth_myaddr[i] = inb(iobase + i); + myadr[i] = eth_myaddr[i] = inb(iobase + i); am7990_init(); strncpy(bi_netif.ifname, "le", sizeof(bi_netif.ifname)); bi_netif.bus = BI_BUS_PCI; - bi_netif.addr = iobase; + bi_netif.addr.tag = hdl; BI_ADD(&bi_netif, BTINFO_NETIF, sizeof(bi_netif)); diff --git a/sys/arch/i386/stand/lib/netif/wd80x3.c b/sys/arch/i386/stand/lib/netif/wd80x3.c index 01b450b4dd14..10aa3268011b 100644 --- a/sys/arch/i386/stand/lib/netif/wd80x3.c +++ b/sys/arch/i386/stand/lib/netif/wd80x3.c @@ -1,4 +1,4 @@ -/* $NetBSD: wd80x3.c,v 1.3 1997/09/17 18:21:44 drochner Exp $ */ +/* $NetBSD: wd80x3.c,v 1.4 1997/09/20 12:13:06 drochner Exp $ */ /* stripped down from netbsd:sys/arch/i386/netboot/wd8x13.c */ @@ -235,7 +235,7 @@ char *myadr; /* get ethernet address */ for(i = 0; i < 6; i++) - bi_netif.hw_addr[i] = eth_myaddr[i] = myadr[i]= inb(WD_BASEREG + WD_EA0 + i); + eth_myaddr[i] = myadr[i]= inb(WD_BASEREG + WD_EA0 + i); /* save settings for future use */ dpc.dc_reg = WD_BASEREG + WD_DP8390; @@ -256,7 +256,7 @@ char *myadr; strncpy(bi_netif.ifname, "ed", sizeof(bi_netif.ifname)); bi_netif.bus = BI_BUS_ISA; - bi_netif.addr = WD_BASEREG; + bi_netif.addr.iobase = WD_BASEREG; BI_ADD(&bi_netif, BTINFO_NETIF, sizeof(bi_netif));