summaryrefslogtreecommitdiff
path: root/sys/dev/tx
diff options
context:
space:
mode:
authorSemen Ustimenko <semenu@FreeBSD.org>2001-08-13 18:37:31 +0000
committerSemen Ustimenko <semenu@FreeBSD.org>2001-08-13 18:37:31 +0000
commit395a636fb233e862bf7feafe81c539d9475ffc79 (patch)
tree456f68284b6c25b16254c7b72e4ca24e70f3c3d4 /sys/dev/tx
parent2c9067b16fca8383611b81033ad4d01fba52f4f5 (diff)
Notes
Diffstat (limited to 'sys/dev/tx')
-rw-r--r--sys/dev/tx/if_tx.c16
1 files changed, 7 insertions, 9 deletions
diff --git a/sys/dev/tx/if_tx.c b/sys/dev/tx/if_tx.c
index f7610c713a41..707355dbd01e 100644
--- a/sys/dev/tx/if_tx.c
+++ b/sys/dev/tx/if_tx.c
@@ -523,12 +523,9 @@ epic_freebsd_attach(dev)
/* Workaround for Application Note 7-15 */
for (i=0; i<16; i++) CSR_WRITE_4(sc, TEST1, TEST1_CLOCK_TEST);
- /*
- * Do ifmedia setup.
- */
- if (mii_phy_probe(dev, &sc->miibus,
- epic_ifmedia_upd, epic_ifmedia_sts)) {
- device_printf(dev, "MII without any PHY!?\n");
+ /* Do OS independent part, including chip wakeup and reset */
+ if (epic_common_attach(sc)) {
+ device_printf(dev, "memory distribution error\n");
bus_teardown_intr(dev, sc->irq, sc->sc_ih);
bus_release_resource(dev, SYS_RES_IRQ, 0, sc->irq);
bus_release_resource(dev, EPIC_RES, EPIC_RID, sc->res);
@@ -536,9 +533,10 @@ epic_freebsd_attach(dev)
goto fail;
}
- /* Do OS independent part, including chip wakeup and reset */
- if (epic_common_attach(sc)) {
- device_printf(dev, "memory distribution error\n");
+ /* Do ifmedia setup */
+ if (mii_phy_probe(dev, &sc->miibus,
+ epic_ifmedia_upd, epic_ifmedia_sts)) {
+ device_printf(dev, "MII without any PHY!?\n");
bus_teardown_intr(dev, sc->irq, sc->sc_ih);
bus_release_resource(dev, SYS_RES_IRQ, 0, sc->irq);
bus_release_resource(dev, EPIC_RES, EPIC_RID, sc->res);