summaryrefslogtreecommitdiff
path: root/sys/dev/pci/if_nfe.c
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2011-01-10 16:18:04 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2011-01-10 16:18:04 +0000
commit0a4a9df88e4339b22efeef2192b29449d870ee36 (patch)
tree771725aa8d949e501d1a09591db73aedf5c7189a /sys/dev/pci/if_nfe.c
parentf94392ccbaf3c8955688b433fec197eec6d5e66c (diff)
Some nfe(4)/rlphy(4) combos don't work, because the PHY responds to all
addresses on the mii bus. As a countereasure, only attach the first PHY we encounter. It is very unlikely we're going to ever see nfe(4) with multiple PHYs. The same is probably true for any modern NIC. ok mikeb@, deraadt@
Diffstat (limited to 'sys/dev/pci/if_nfe.c')
-rw-r--r--sys/dev/pci/if_nfe.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/pci/if_nfe.c b/sys/dev/pci/if_nfe.c
index 02f6da6a142..515ee66e990 100644
--- a/sys/dev/pci/if_nfe.c
+++ b/sys/dev/pci/if_nfe.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_nfe.c,v 1.96 2010/09/07 16:21:45 deraadt Exp $ */
+/* $OpenBSD: if_nfe.c,v 1.97 2011/01/10 16:18:03 kettenis Exp $ */
/*-
* Copyright (c) 2006, 2007 Damien Bergamini <damien.bergamini@free.fr>
@@ -368,8 +368,7 @@ nfe_attach(struct device *parent, struct device *self, void *aux)
ifmedia_init(&sc->sc_mii.mii_media, 0, nfe_ifmedia_upd,
nfe_ifmedia_sts);
- mii_attach(self, &sc->sc_mii, 0xffffffff, MII_PHY_ANY,
- MII_OFFSET_ANY, 0);
+ mii_attach(self, &sc->sc_mii, 0xffffffff, MII_PHY_ANY, 0, 0);
if (LIST_FIRST(&sc->sc_mii.mii_phys) == NULL) {
printf("%s: no PHY found!\n", sc->sc_dev.dv_xname);
ifmedia_add(&sc->sc_mii.mii_media, IFM_ETHER | IFM_MANUAL,