svn commit: r216000 - stable/8/sys/dev/mii
Marius Strobl
marius at FreeBSD.org
Sun Nov 28 15:57:23 UTC 2010
Author: marius
Date: Sun Nov 28 15:57:22 2010
New Revision: 216000
URL: http://svn.freebsd.org/changeset/base/216000
Log:
MFC: r215905
Ensure Bay flow control is disabled as we're going to use IEEE 802.3 annex
31B full duplex flow control instead.
Modified:
stable/8/sys/dev/mii/inphy.c
Directory Properties:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
Modified: stable/8/sys/dev/mii/inphy.c
==============================================================================
--- stable/8/sys/dev/mii/inphy.c Sun Nov 28 14:57:37 2010 (r215999)
+++ stable/8/sys/dev/mii/inphy.c Sun Nov 28 15:57:22 2010 (r216000)
@@ -77,6 +77,7 @@ DRIVER_MODULE(inphy, miibus, inphy_drive
static int inphy_service(struct mii_softc *, struct mii_data *, int);
static void inphy_status(struct mii_softc *);
+static void inphy_reset(struct mii_softc *);
static const struct mii_phydesc inphys[] = {
MII_PHY_DESC(INTEL, I82553C),
@@ -119,7 +120,7 @@ inphy_attach(device_t dev)
IFM_MAKEWORD(IFM_ETHER, IFM_100_TX, IFM_LOOP, sc->mii_inst),
MII_MEDIA_100_TX, NULL);
- mii_phy_reset(sc);
+ inphy_reset(sc);
sc->mii_capabilities = PHY_READ(sc, MII_BMSR) & ma->mii_capmask;
device_printf(dev, " ");
@@ -206,3 +207,14 @@ inphy_status(struct mii_softc *sc)
} else
mii->mii_media_active = ife->ifm_media;
}
+
+static void
+inphy_reset(struct mii_softc *sc)
+{
+
+ mii_phy_reset(sc);
+
+ /* Ensure Bay flow control is disabled. */
+ PHY_WRITE(sc, MII_INPHY_SCR,
+ PHY_READ(sc, MII_INPHY_SCR) & ~SCR_FLOWCTL);
+}
More information about the svn-src-all
mailing list