diff options
author | imp <imp@FreeBSD.org> | 2005-10-22 05:14:18 +0000 |
---|---|---|
committer | imp <imp@FreeBSD.org> | 2005-10-22 05:14:18 +0000 |
commit | acd6923419a86b702232316d9daae546732a366b (patch) | |
tree | 86b8edb91171672879e5feb0ead7791a997ee5a1 /sys/dev/ed | |
parent | 55b3e47503e40acc7443656e35f538b6f48eb899 (diff) | |
download | FreeBSD-src-acd6923419a86b702232316d9daae546732a366b.zip FreeBSD-src-acd6923419a86b702232316d9daae546732a366b.tar.gz |
In the ISA case, we call ed_probe_WD80x3 before we call
ed_probe_rtl80x9. In the pci case we call ed_probe_rtl80x9 first. In
the PCI case we were using the correct nic_offset by accident because
softc is initialized to zero. In the isa case we were using the wrong
value by accident, since ed_probe_WD80x3 sets the offset value to
0x10. This lead to the identification routines failing. Fix this
problem by always initalizing the nic_offset and asic_offset before
making ed_{asic,nic}_{in,out}* calls.
Diffstat (limited to 'sys/dev/ed')
-rw-r--r-- | sys/dev/ed/if_ed_rtl80x9.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/ed/if_ed_rtl80x9.c b/sys/dev/ed/if_ed_rtl80x9.c index cec1b618..c6a7d76 100644 --- a/sys/dev/ed/if_ed_rtl80x9.c +++ b/sys/dev/ed/if_ed_rtl80x9.c @@ -80,6 +80,9 @@ ed_probe_RTL80x9(device_t dev, int port_rid, int flags) if ((error = ed_alloc_port(dev, port_rid, ED_NOVELL_IO_PORTS))) return (error); + + sc->asic_offset = ED_NOVELL_ASIC_OFFSET; + sc->nic_offset = ED_NOVELL_NIC_OFFSET; if (ed_nic_inb(sc, ED_P0_CR) & (ED_CR_PS0 | ED_CR_PS1)) ed_nic_outb(sc, ED_P0_CR, ED_CR_RD2 | ED_CR_STP); @@ -100,9 +103,6 @@ ed_probe_RTL80x9(device_t dev, int port_rid, int flags) return (ENXIO); } - sc->asic_offset = ED_NOVELL_ASIC_OFFSET; - sc->nic_offset = ED_NOVELL_NIC_OFFSET; - if ((error = ed_probe_Novell_generic(dev, flags))) return (error); |