Date: Tue, 25 Aug 2009 16:08:21 +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: <20090825130821.GA41669@traktor.dnepro.net> In-Reply-To: <20090825114649.GA11642@traktor.dnepro.net> References: <20090821142039.GA40018@traktor.dnepro.net> <20090821221932.GE1262@michelle.cdnetworks.com> <20090825083857.GA22983@traktor.dnepro.net> <20090825114649.GA11642@traktor.dnepro.net>
next in thread | previous in thread | raw e-mail | index | archive | help
Hello. On Tue, Aug 25, 2009 at 02:46:49PM +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; [...] > --- 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've rebooted with new kernel with following results: mskc0: <D-Link 560SX Gigabit Ethernet> port 0x4000-0x40ff mem 0xdc100000-0xdc103 fff irq 16 at device 0.0 on pci1 msk0: <Marvell Technology Group Ltd. Yukon XL Id 0xb3 Rev 0x03> on mskc0 msk0: Ethernet address: 00:21:91:52:4f:09 miibus1: <MII bus> on msk0 e1000phy0: <Marvell 88E1112 Gigabit PHY> PHY 0 on miibus1 e1000phy0: 1000baseSX, 1000baseSX-FDX, auto mskc0: [FILTER] # ifconfig msk0 msk0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=11a<TXCSUM,VLAN_MTU,VLAN_HWTAGGING,TSO4> ether 00:21:91:52:4f:09 media: Ethernet autoselect # ifconfig msk0 up # ifconfig -m msk0 msk0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=11a<TXCSUM,VLAN_MTU,VLAN_HWTAGGING,TSO4> capabilities=11a<TXCSUM,VLAN_MTU,VLAN_HWTAGGING,TSO4> ether 00:21:91:52:4f:09 media: Ethernet autoselect (autoselect <full-duplex>) status: active supported media: media autoselect media 1000baseSX mediaopt full-duplex media 1000baseSX media none Switch and NIC see the link, but no packets pass through the interface. # ifconfig msk0 media 1000baseSX mediaopt full-duplex # ifconfig msk0 msk0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=11a<TXCSUM,VLAN_MTU,VLAN_HWTAGGING,TSO4> ether 00:21:91:52:4f:09 media: Ethernet 1000baseSX <full-duplex> (autoselect <full-duplex>) status: active Again no packets are seen with tcpdump. Switch counters show no incoming packets from NIC if I set an ip and try to generate some traffic. Any ideas? -- Eugene Perevyazko
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090825130821.GA41669>