Module Name: src
Committed By: msaitoh
Date: Sun Jun 9 09:23:35 UTC 2013
Modified Files:
src/sys/dev/sbus: be.c
Log Message:
Don't "return" but "break" in MII_TICK when the interface isn't doing
autonegotiaton or the link is up to update the status.
To generate a diff of this commit:
cvs rdiff -u -r1.79 -r1.80 src/sys/dev/sbus/be.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/dev/sbus/be.c
diff -u src/sys/dev/sbus/be.c:1.79 src/sys/dev/sbus/be.c:1.80
--- src/sys/dev/sbus/be.c:1.79 Sun Jul 22 14:33:05 2012
+++ src/sys/dev/sbus/be.c Sun Jun 9 09:23:35 2013
@@ -1,4 +1,4 @@
-/* $NetBSD: be.c,v 1.79 2012/07/22 14:33:05 matt Exp $ */
+/* $NetBSD: be.c,v 1.80 2013/06/09 09:23:35 msaitoh Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -57,7 +57,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: be.c,v 1.79 2012/07/22 14:33:05 matt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: be.c,v 1.80 2013/06/09 09:23:35 msaitoh Exp $");
#include "opt_ddb.h"
#include "opt_inet.h"
@@ -1516,14 +1516,14 @@ be_intphy_service(struct be_softc *sc, s
if (IFM_INST(ife->ifm_media) != sc->sc_mii_inst)
return 0;
- /* Only used for automatic media selection */
- if (IFM_SUBTYPE(ife->ifm_media) != IFM_AUTO)
- return 0;
-
/* Is the interface even up? */
if ((mii->mii_ifp->if_flags & IFF_UP) == 0)
return 0;
+ /* Only used for automatic media selection */
+ if (IFM_SUBTYPE(ife->ifm_media) != IFM_AUTO)
+ break;
+
/*
* Check link status; if we don't have a link, try another
* speed. We can't detect duplex mode, so half-duplex is
@@ -1555,7 +1555,7 @@ be_intphy_service(struct be_softc *sc, s
device_xname(self),
(bmcr & BMCR_S100) ? "100" : "10");
}
- return 0;
+ break;
}
if ((sc->sc_mii_flags & MIIF_DOINGAUTO) == 0) {