summaryrefslogtreecommitdiffstats
path: root/sys/dev/mii/ciphy.c
diff options
context:
space:
mode:
authormarius <marius@FreeBSD.org>2006-12-02 19:36:25 +0000
committermarius <marius@FreeBSD.org>2006-12-02 19:36:25 +0000
commite88fd11fa63919f0d0ba952544f8abe033024e9e (patch)
tree0a8173ea0887896b2cd6a3f0ad42c1684b04c2b4 /sys/dev/mii/ciphy.c
parentc4618bacd39ad5ce8f2fb96309c79e7c9983bdb6 (diff)
downloadFreeBSD-src-e88fd11fa63919f0d0ba952544f8abe033024e9e.zip
FreeBSD-src-e88fd11fa63919f0d0ba952544f8abe033024e9e.tar.gz
Some style changes to a couple of PHY drivers:
- Fix some whitespace nits. - Fix some spelling in comments. - Use MII_ANEGTICKS instead of 5. - Don't define variables in nested scope. - Remove superfluous returns at the end of void functions. - Remove unused static global rgephy_mii_model. - Remove dupe $Id$ in tdkphy(4). - Sort brgphys table. MFC after: 2 weeks
Diffstat (limited to 'sys/dev/mii/ciphy.c')
-rw-r--r--sys/dev/mii/ciphy.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/sys/dev/mii/ciphy.c b/sys/dev/mii/ciphy.c
index ed601ad..07eb5e0 100644
--- a/sys/dev/mii/ciphy.c
+++ b/sys/dev/mii/ciphy.c
@@ -44,7 +44,6 @@ __FBSDID("$FreeBSD$");
#include <sys/socket.h>
#include <sys/bus.h>
-
#include <net/if.h>
#include <net/if_arp.h>
#include <net/if_media.h>
@@ -265,7 +264,7 @@ setit:
/*
* Only retry autonegotiation every 5 seconds.
*/
- if (++sc->mii_ticks <= 5/*10*/)
+ if (++sc->mii_ticks <= MII_ANEGTICKS)
break;
sc->mii_ticks = 0;
@@ -335,17 +334,14 @@ ciphy_status(struct mii_softc *sc)
if (bmsr & CIPHY_AUXCSR_FDX)
mii->mii_media_active |= IFM_FDX;
-
- return;
}
static void
ciphy_reset(struct mii_softc *sc)
{
+
mii_phy_reset(sc);
DELAY(1000);
-
- return;
}
#define PHY_SETBIT(x, y, z) \
@@ -405,6 +401,4 @@ ciphy_fixup(struct mii_softc *sc)
model);
break;
}
-
- return;
}
OpenPOWER on IntegriCloud