summaryrefslogtreecommitdiffstats
path: root/sys/i386/isa/if_lnc.c
diff options
context:
space:
mode:
authormsmith <msmith@FreeBSD.org>1998-07-20 17:33:01 +0000
committermsmith <msmith@FreeBSD.org>1998-07-20 17:33:01 +0000
commit164c653979d31d472c9de112e2889730a979afab (patch)
tree32b03a5d278f3cfd8c493a4d0c7c188649a96d24 /sys/i386/isa/if_lnc.c
parent8f5a35b01d5b48f689f82f032749a60abbeaccad (diff)
downloadFreeBSD-src-164c653979d31d472c9de112e2889730a979afab.zip
FreeBSD-src-164c653979d31d472c9de112e2889730a979afab.tar.gz
Add support for PCNet PCI chips that only work when we talk to them as ISA
devices. Specifically fix the case for the Hitachi version as used in their VisionBook models. Submitted by: Ted Faber <faber@isi.edu>
Diffstat (limited to 'sys/i386/isa/if_lnc.c')
-rw-r--r--sys/i386/isa/if_lnc.c21
1 files changed, 19 insertions, 2 deletions
diff --git a/sys/i386/isa/if_lnc.c b/sys/i386/isa/if_lnc.c
index bff5d17..dd201a3 100644
--- a/sys/i386/isa/if_lnc.c
+++ b/sys/i386/isa/if_lnc.c
@@ -30,7 +30,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: if_lnc.c,v 1.42 1998/05/27 11:05:17 paul Exp $
+ * $Id: if_lnc.c,v 1.43 1998/06/07 17:10:36 dfr Exp $
*/
/*
@@ -1145,6 +1145,14 @@ pcnet_probe(struct lnc_softc *sc)
* do NOT try to ISA attach the PCI version
*/
return (0);
+ case HITACHI_Am79C970:
+
+ /*
+ * PCI cards that should be attached in
+ * ISA mode should return this value. -- tvf
+ */
+
+ return (PCnet_PCI);
default:
break;
}
@@ -1274,7 +1282,16 @@ lnc_attach_ne2100_pci(int unit, unsigned iobase)
if (sc) {
bzero (sc, sizeof *sc);
- if ((ne2100_probe(sc, iobase) == 0)
+ /*
+ * ne2100_probe sets sc->nic.ic to PCnet_PCI for PCI
+ * cards that work in ISA emulation mode. The first
+ * clause this code avoids attaching such a card at
+ * this time to allow it to be picked up as an ISA
+ * card later. -- tvf
+ */
+
+ if (((ne2100_probe(sc, iobase) == 0) ||
+ sc->nic.ic == PCnet_PCI)
|| (lnc_attach_sc(sc, unit) == 0)) {
free(sc, M_DEVBUF);
sc = NULL;
OpenPOWER on IntegriCloud