summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/dev/ic/dwc_gmac.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/ic/dwc_gmac.c b/sys/dev/ic/dwc_gmac.c
index 4a511a0cb0f..78fdbf6d301 100644
--- a/sys/dev/ic/dwc_gmac.c
+++ b/sys/dev/ic/dwc_gmac.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dwc_gmac.c,v 1.8 2017/06/29 17:36:16 deraadt Exp $ */
+/* $OpenBSD: dwc_gmac.c,v 1.9 2018/04/07 22:43:12 kettenis Exp $ */
/* $NetBSD: dwc_gmac.c,v 1.34 2015/08/21 20:12:29 jmcneill Exp $ */
/*-
@@ -222,8 +222,8 @@ dwc_gmac_attach(struct dwc_gmac_softc *sc, uint32_t mii_clk, int phyloc)
ifmedia_init(&mii->mii_media, 0, dwc_gmac_ifmedia_upd,
dwc_gmac_ifmedia_sts);
- mii_attach((void *)sc, mii, 0xffffffff, phyloc, MII_OFFSET_ANY,
- MIIF_DOPAUSE);
+ mii_attach((void *)sc, mii, 0xffffffff, phyloc,
+ (phyloc == MII_PHY_ANY) ? 0 : MII_OFFSET_ANY, MIIF_DOPAUSE);
if (LIST_EMPTY(&mii->mii_phys)) {
printf("%s: no PHY found!\n", sc->sc_dev.dv_xname);