Project

General

Profile

Actions

Bug #20

closed

No detection of 8169S Gb interface

Added by tomaz.borstnar almost 19 years ago. Updated about 18 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Start date:
Due date:
% Done:

0%

Estimated time:

Description

DragonFly 1.3.7-DEVELOPMENT #0: Wed Dec 21 15:32:39 GMT 2005

re0: <RealTek 8169S Single-chip Gigabit Ethernet> port 0xa400-0xa4ff mem 0xfb801
000-0xfb8010ff irq 10 at device 2.0 on pci2
miibus0: <MII bus> on re0
ukphy0: <Generic IEEE 802.3u media interface> on miibus0
ukphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
re0: MAC address: 00:0e:2e:28:08:1f

Connected to GigE switch:

[web2] ~> ifconfig re0
re0: flags=9843<UP,BROADCAST,RUNNING,SIMPLEX,LINK0,MULTICAST> mtu 1500
options=18<VLAN_MTU,VLAN_HWTAGGING>
inet 10.10.52.50 netmask 0xffffff00 broadcast 10.10.52.255
inet6 fe80::20e:2eff:fe28:81f%re0 prefixlen 64 scopeid 0x1
ether 00:0e:2e:28:08:1f
media: Ethernet autoselect (100baseTX <full-duplex>)
status: active

So it appears that this 8169S still needs some driver modification as it does not know about GigE physical interface.
This is from LevelOne add-on PCI card.

Tomaž

Tomaž

Actions #1

Updated by sepherosa almost 19 years ago

Please try:http://leaf.dragonflybsd.org/~sephe/rgephy.diff
You will have rebuild kernel if you have a compiled-in miiIf you use mii as module, you will have to recompile mii module
I have done a rough test with my re(4)
Please let us know whether it works or not ASAP, not much time is left :-)Thank you in advance.
Best Regards,sephe
On 12/22/05, Tomaž Borštnar <> wrote:> Jeroen Ruigrok/asmodai pravi:> > -On [20050719 00:55], George Georgalis () wrote:> >> call me grateful to have a $19.95 Gigabit PCI Adapter! ...I'll be> >> watching the commits!> >> > Got the docs now, yes it has its own PHY.> >> > I will add some stuff to the driver over the weekend.> >> DragonFly 1.3.7-DEVELOPMENT #0: Wed Dec 21 15:32:39 GMT 2005>>> re0: <RealTek 8169S Single-chip Gigabit Ethernet> port 0xa400-0xa4ff mem 0xfb801> 000-0xfb8010ff irq 10 at device 2.0 on pci2> miibus0: <MII bus> on re0> ukphy0: <Generic IEEE 802.3u media interface> on miibus0> ukphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto> re0: MAC address: 00:0e:2e:28:08:1f>> Connected to GigE switch:>> [web2] ~> ifconfig re0> re0: flags=9843<UP,BROADCAST,RUNNING,SIMPLEX,LINK0,MULTICAST> mtu 1500> options=18<VLAN_MTU,VLAN_HWTAGGING>> inet 10.10.52.50 netmask 0xffffff00 broadcast 10.10.52.255> !
inet6 fe80::20e:2eff:fe28:81f%re0 prefixlen 64 scopeid 0x1> ether 00:0e:2e:28:08:1f> media: Ethernet autoselect (100baseTX <full-duplex>)> status: active>>> So it appears that this 8169S still needs some driver modification as it does not know about GigE physical interface.> This is from LevelOne add-on PCI card.>>> Tomaž>> Tomaž>

--Live Free or Die

Actions #2

Updated by tomaz.borstnar almost 19 years ago

Right after booting:

re0: <RealTek 8169S Single-chip Gigabit Ethernet> port 0xa400-0xa4ff mem 0xfb801
000-0xfb8010ff irq 10 at device 2.0 on pci2
miibus0: <MII bus> on re0
rgephy0: <RTL8169S/8110S media interface> on miibus0
rgephy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseTX, 1000baseTX
-FDX, auto
re0: MAC address: 00:0e:2e:28:08:1f

[web2] ~> ifconfig re0
re0: flags=9843<UP,BROADCAST,RUNNING,SIMPLEX,LINK0,MULTICAST> mtu 1500
options=18<VLAN_MTU,VLAN_HWTAGGING>
inet 10.10.52.50 netmask 0xffffff00 broadcast 10.10.52.255
inet6 fe80::20e:2eff:fe28:81f%re0 prefixlen 64 scopeid 0x1
ether 00:0e:2e:28:08:1f
media: Ethernet autoselect (10baseT/UTP <full-duplex>)
status: active

After down/up sequence:

media: Ethernet autoselect (100baseTX &lt;full-duplex&gt;)

%ifconfig re0 media 1000basetx mediaopt full-duplex
ifconfig: unknown media subtype: 1000basetx

So no luck to set it to gig. I applied your patch and did a nativekernel/installkernel only.

Tomaž

Actions #3

Updated by tomaz.borstnar almost 19 years ago

Yes, autoselect mostly does 10Mbps/full.

Tomaž

Actions #4

Updated by dragonfly almost 19 years ago

Hello,

DragonFly is missing the rgephy driver found in FreeBSD5+, NetBSD and
others. This supports the Gigabit speeds. The re driver in FreeBSD6 also
supports the detection of more cards. It would be trivial to import the
additional cards.

Look at the section ("Various supported device vendors/types and their
names") in:

http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/dev/re/if_re.c
http://www.dragonflybsd.org/cgi-bin/cvsweb.cgi/src/sys/dev/netif/re/if_re.c

I'm working on importing the FreeBSD driver as I also have an 8169S
based Gigabit card (Dlink 528T), unfortunately the DragonFly mii_layer
is missing a few calls found in the other OSes so it's slightly more
difficult than I had hoped. I should get some spare time this weekend
but wouldn't complain if someone wants to do it for me.

Here's the original instructions from Matt

Do a boot -v and report which MII driver is currently attaching
to the RE ethernet. It's probably the generic driver (ukphy), in
which case we will need to port rgephy.c from FreeBSD to DragonFly.
FreeBSD: sys/dev/mii/rge*
DragonFly: sys/dev/netif/mii_layer/rge*
There is some fairly minor porting work that needs to be done,
which you can look at by looking at the cvs log history for some
of the other MII source modules in DragonFly.
-Matt

Regards

G.Allan

Actions #5

Updated by sepherosa almost 19 years ago

Updated patch is at:http://leaf.dragonflybsd.org/~sephe/rgephy1.diff
Auto-negotiation works fine even when re(4) is not up :)
Please test it
Cheers,sephe
On 12/23/05, Tomaž Borštnar <> wrote:> Yes, autoselect mostly does 10Mbps/full.>> Tomaž>

--Live Free or Die

Actions #6

Updated by tomaz.borstnar almost 19 years ago

Sepherosa Ziehau pravi:

Updated patch is at:http://leaf.dragonflybsd.org/~sephe/rgephy1.diff
Auto-negotiation works fine even when re(4) is not up :)
Please test it

re0: <RealTek 8169S Single-chip Gigabit Ethernet> port 0xa400-0xa4ff mem 0xfb801
000-0xfb8010ff irq 10 at device 2.0 on pci2
miibus0: <MII bus> on re0
rgephy0: <RTL8169S/8110S media interface> on miibus0
rgephy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseTX, 1000baseTX
-FDX, auto
re0: MAC address: 00:0e:2e:28:08:1f

%grep re0 /etc/rc.conf
ifconfig_re0="up"

%ifconfig re0 media 1000basetx mediaopt full-duplex
ifconfig: unknown media subtype: 1000basetx

why is not possible?

Still comes as 10Mbps full-duplex when autonegotiating to a GigE switch (dumb one).

Tomaž

Actions #7

Updated by sepherosa almost 19 years ago

On 12/25/05, Tomaž Borštnar <> wrote:> Sepherosa Ziehau pravi:> > Updated patch is at:http://leaf.dragonflybsd.org/~sephe/rgephy1.diff> > Auto-negotiation works fine even when re(4) is not up :)> > Please test it>> re0: <RealTek 8169S Single-chip Gigabit Ethernet> port 0xa400-0xa4ff mem 0xfb801> 000-0xfb8010ff irq 10 at device 2.0 on pci2> miibus0: <MII bus> on re0> rgephy0: <RTL8169S/8110S media interface> on miibus0> rgephy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseTX, 1000baseTX> -FDX, auto
I have updated tha patch:http://leaf.dragonflybsd.org/~sephe/rgephy2.diff
1000baseTX is confusing, I have changed them to 1000baseT
If you want to manually configure the media, you should:# ifconfig re0 media 1000baseT mediaopt full-duplex

re0: MAC address: 00:0e:2e:28:08:1f>> %grep re0 /etc/rc.conf> ifconfig_re0="up">>> %ifconfig re0 media 1000basetx mediaopt full-duplex> ifconfig: unknown media subtype: 1000basetx>> why is not possible?>> Still comes as 10Mbps full-duplex when autonegotiating to a GigE switch (dumb one).>> Tomaž>

--Live Free or Die

Actions #8

Updated by tomaz.borstnar almost 19 years ago

It works with rgephy1 patch :) Works fine with GigE switch, em cards, bge cards and PCI-E Broadcom cards. I also had to
replace the cable to make it work better. I could not do that remotely though which is why it took me little longer.

Will this get into 1.4 or not?

With rgephy2 I get this:

re0: <RealTek 8169S Single-chip Gigabit Ethernet> port 0xa400-0xa4ff mem 0xfb801
000-0xfb8010ff irq 10 at device 2.0 on pci2
miibus0: <MII bus> on re0
rgephy0: <RTL8169S/8110S media interface> on miibus0
rgephy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-F
DX, auto
re0: MAC address: 00:0e:2e:28:08:1f
re0: diagnostic failed to receive packet in loopback mode
re0: hardware diagnostic failure
rgephy0: detached
miibus0: detached
device_probe_and_attach: re0 attach returned 5

And no re0 because of that.

So I would suggest to review and commit rgephy1 patch which works fine after replacing the cable.

Tomaž

Actions #9

Updated by sepherosa almost 19 years ago

On 12/26/05, Tomaž Borštnar <> wrote:> It works with rgephy1 patch :) Works fine with GigE switch, em cards, bge cards and PCI-E Broadcom cards. I also had to> replace the cable to make it work better. I could not do that remotely though which is why it took me little longer.>> Will this get into 1.4 or not?>> With rgephy2 I get this:>> re0: <RealTek 8169S Single-chip Gigabit Ethernet> port 0xa400-0xa4ff mem 0xfb801> 000-0xfb8010ff irq 10 at device 2.0 on pci2> miibus0: <MII bus> on re0> rgephy0: <RTL8169S/8110S media interface> on miibus0> rgephy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-F> DX, auto> re0: MAC address: 00:0e:2e:28:08:1f> re0: diagnostic failed to receive packet in loopback mode> re0: hardware diagnostic failure> rgephy0: detached> miibus0: detached> device_probe_and_attach: re0 attach returned 5>> And no re0 because of that.>> So I would suggest to review and commit rgephy1 patch which works fine after r!
eplacing the cable.>> Tomaž>
Thank you for testing, I have committed the rgephy1 patch :-)
Hopefully, Matt will put it into 1.4 branch
Cheers,sephe
--Live Free or Die

Actions #10

Updated by corecode almost 19 years ago

committed by sephe

Actions

Also available in: Atom PDF