-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
This commit is contained in:
drochner 1997-09-20 12:13:01 +00:00
parent 1e11bfa8b7
commit 9b4679d869
5 changed files with 15 additions and 15 deletions

View File

@ -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));

View File

@ -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));

View File

@ -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));

View File

@ -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));

View File

@ -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));