Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 25 Aug 2009 14:46:49 +0300
From:      Eugene Perevyazko <john@dnepro.net>
To:        freebsd-net@freebsd.org
Cc:        Pyun YongHyeon <pyunyh@gmail.com>
Subject:   Re: D-Link DGE-560SX (Marvell 88E8061-based) doesn't see link
Message-ID:  <20090825114649.GA11642@traktor.dnepro.net>
In-Reply-To: <20090825083857.GA22983@traktor.dnepro.net>
References:  <20090821142039.GA40018@traktor.dnepro.net> <20090821221932.GE1262@michelle.cdnetworks.com> <20090825083857.GA22983@traktor.dnepro.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Hello Pyun.
On Tue, Aug 25, 2009 at 11:38:57AM +0300, Eugene Perevyazko wrote:
>  [...]
> > 
> > ATM there is no easy/clean way to pass driver specific data to mii
> > layer in FreeBSD so e1000phy(4) incorrectly thinks it found copper
> > PHY. Marvell PHYs seem to have no reliable way to know configured
> > media type of PHY hardware unless parent driver(msk) gives hint to
> > it. If you have just 1 NIC which uses e1000phy(4) on your system,
> > modify e1000phy(4) to force it having fiber media by inserting the
> > following line around line 114 in e1000phy.c. 
> > 
> > sc->mii_flags |= MIIF_HAVEFIBER;
> > 
> I'm lucky enough that it's the only e1000phy NIC in the system, but I can't
> find the place you mean in e1000phy.c
> It's src/sys/dev/e1000/e1000_phy.c,v 1.1.2.2 and lines 112-115 are

Sorry for being so blind as to look for MII code in intel's gigabit driver! :)

It's sys/dev/mii/e1000phy.c of course.

Line 114 still looks weird to me, so I'm trying this:
--- e1000phy.c  2009-08-25 14:45:03.000000000 +0300
+++ e1000phy.c.old      2009-08-25 14:44:47.000000000 +0300
@@ -166,7 +166,6 @@
                break;
        }

-       sc->mii_flags |= MIIF_HAVEFIBER;
        e1000phy_reset(sc);

        sc->mii_capabilities = PHY_READ(sc, MII_BMSR) & ma->mii_capmask;

for src/sys/dev/mii/e1000phy.c,v 1.18.2.8
I'm rebuilding kernel now...


-- 
Eugene Perevyazko



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090825114649.GA11642>