summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2009-07-23 09:45:59 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2009-07-23 09:45:59 +0000
commit82334150f98fc771582712f79cffad70ec1a0e7b (patch)
treeba7cf31f446ae12f23ce05dcc8b45b6fdbdca23f
parent2d98876c8a839dd128689ca37f013a2218b57904 (diff)
If we initialize miicapabilities, we might as well pass it on when calling
mii_attach. Spotted by chl@. Fix inspired by looking at the current NetBSD code. Repeated calls for testing went unanswered.
-rw-r--r--sys/dev/ic/smc91cxx.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/dev/ic/smc91cxx.c b/sys/dev/ic/smc91cxx.c
index 685be05c990..83bbf395c4b 100644
--- a/sys/dev/ic/smc91cxx.c
+++ b/sys/dev/ic/smc91cxx.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: smc91cxx.c,v 1.30 2008/11/28 02:44:17 brad Exp $ */
+/* $OpenBSD: smc91cxx.c,v 1.31 2009/07/23 09:45:58 kettenis Exp $ */
/* $NetBSD: smc91cxx.c,v 1.11 1998/08/08 23:51:41 mycroft Exp $ */
/*-
@@ -283,13 +283,14 @@ smc91cxx_attach(sc, myea)
* even if the PHY does.
*/
miicapabilities &= ~(BMSR_100TXFDX | BMSR_10TFDX);
+ /* FALLTHROUGH */
case CHIP_91100FD:
if (tmp & CR_MII_SELECT) {
#ifdef SMC_DEBUG
printf("%s: default media MII\n",
sc->sc_dev.dv_xname);
#endif
- mii_attach(&sc->sc_dev, &sc->sc_mii, 0xffffffff,
+ mii_attach(&sc->sc_dev, &sc->sc_mii, miicapabilities,
MII_PHY_ANY, MII_OFFSET_ANY, 0);
if (LIST_FIRST(&sc->sc_mii.mii_phys) == NULL) {
ifmedia_add(&sc->sc_mii.mii_media,
@@ -303,7 +304,7 @@ smc91cxx_attach(sc, myea)
sc->sc_flags |= SMC_FLAGS_HAS_MII;
break;
}
- /*FALLTHROUGH*/
+ /* FALLTHROUGH */
default:
aui = tmp & CR_AUI_SELECT;
#ifdef SMC_DEBUG