[realtek] RE: network drops out
Kris Thielemans
kris.thielemans@csc.mrc.ac.uk
Wed Jun 26 08:42:01 2002
Hi,
some more info on my problem. Looking through the archives (which would be
far more easy if there would be a search facility of course), it seems that
my problem is a well-known one and is probably driver related. So, I tried
the solutions that other people came up with.
(By the way SuSE 7.3 uses a 2.4 kernel. The system uses an Athlon XP 1500+).
I've taken the latest version (1.18) of Donald Becker's driver, and applied
the following patches I've seen on this mailing list:
- patch by John Hornton
- patch by Edgar Toerning
- patch by Stephan Brauss
With this patched version installed, my system locked up at the first ftp
(get) attempt. I then disabled Edgar Toerning's patch. After this, the
behaviour resorted to the previously mentioned mess: after doing some ftps,
the network card/driver seems to pack up, and only gets going again after
ifconfig eth0 down
ifconfig eth0 172.16.20.2 broadcast 172.16.255.255 netmask 255.255.0.0
rcroute start
I've invested a bit more time in kernel messages and diagnostic programmes
now (I had to learn all this stuff, sorry I didn't include it in my first
email).
My testing conditions were pretty simple. The system isn't doing anything
(aside from normal background system tasks), except 1 ftp process where I
mget a bunch of large files (20MB or so). Usually the transfer stalls during
the 2nd or 3rd file, and I have to restart the network.
Here are some sample messages I get in /var/log/messages. I have one of
these messages everytime the network connection drops.
--------------------- /var/log/messages extract ----------------
Jun 26 11:04:40 feynman kernel: eth0: Abnormal interrupt, status 00000008.
Jun 26 11:05:45 feynman kernel: eth0: Transmit timeout, status 0d 0000 media
18.
Jun 26 11:05:45 feynman kernel: eth0: Tx queue start entry 25042 dirty
entry 25038, full.
Jun 26 11:05:45 feynman kernel: eth0: Tx descriptor 0 is 1008204e.
Jun 26 11:05:45 feynman kernel: eth0: Tx descriptor 1 is 40082056.
Jun 26 11:05:45 feynman kernel: eth0: Tx descriptor 2 is 0008204e. (queue
head)
Jun 26 11:05:45 feynman kernel: eth0: Tx descriptor 3 is 0008204e.
Jun 26 11:05:45 feynman kernel: eth0: MII #32 registers are: 1000 782d 0000
0000 01e1 0000 0000 0000.
Jun 26 11:10:08 feynman kernel: eth0: no IPv6 routers present
Jun 26 11:15:15 feynman kernel: eth0: Abnormal interrupt, status 00000008.
Jun 26 11:16:01 feynman kernel: eth0: Transmit timeout, status 0d 0000 media
18.
Jun 26 11:16:01 feynman kernel: eth0: Tx queue start entry 19037 dirty
entry 19033, full.
Jun 26 11:16:01 feynman kernel: eth0: Tx descriptor 0 is 4008204e.
Jun 26 11:16:01 feynman kernel: eth0: Tx descriptor 1 is 00082042. (queue
head)
Jun 26 11:16:01 feynman kernel: eth0: Tx descriptor 2 is 0008204e.
Jun 26 11:16:01 feynman kernel: eth0: Tx descriptor 3 is 1008204e.
Jun 26 11:16:01 feynman kernel: eth0: MII #32 registers are: 1000 782d 0000
0000 01e1 0000 0000 0000.
Jun 26 11:21:15 feynman kernel: eth0: no IPv6 routers present
Jun 26 11:26:19 feynman kernel: eth0: Abnormal interrupt, status 00000008.
Jun 26 11:27:08 feynman kernel: eth0: Transmit timeout, status 0d 0000 media
18.
Jun 26 11:27:08 feynman kernel: eth0: Tx queue start entry 7928 dirty entry
7924, full.
Jun 26 11:27:08 feynman kernel: eth0: Tx descriptor 0 is 00082042. (queue
head)
Jun 26 11:27:08 feynman kernel: eth0: Tx descriptor 1 is 00082042.
Jun 26 11:27:08 feynman kernel: eth0: Tx descriptor 2 is 1008204e.
Jun 26 11:27:08 feynman kernel: eth0: Tx descriptor 3 is 4008204e.
Jun 26 11:27:08 feynman kernel: eth0: MII #32 registers are: 1000 782d 0000
0000 01e1 0000 0000 0000.
Jun 26 11:29:23 feynman kernel: eth0: no IPv6 routers present
Jun 26 11:35:43 feynman kernel: eth0: Abnormal interrupt, status 00000008.
Jun 26 11:36:15 feynman kernel: eth0: Transmit timeout, status 0d 0000 media
18.
Jun 26 11:36:15 feynman kernel: eth0: Tx queue start entry 36053 dirty
entry 36049, full.
Jun 26 11:36:15 feynman kernel: eth0: Tx descriptor 0 is 4008204e.
Jun 26 11:36:15 feynman kernel: eth0: Tx descriptor 1 is 0008204e. (queue
head)
Jun 26 11:36:15 feynman kernel: eth0: Tx descriptor 2 is 0008204e.
Jun 26 11:36:15 feynman kernel: eth0: Tx descriptor 3 is 10082042.
Jun 26 11:36:15 feynman kernel: eth0: MII #32 registers are: 1000 782d 0000
0000 01e1 0000 0000 0000.
------------------------ end of /var/log/messages ------------------
Notice that the funny thing is that all errors are related to transmitting
data, while I'm doing an mget.
I compiled rtl8139-diag.c and ran it when the network is ok, and when it
isn't. I ran it with the following flags: -a -f -d -m -v -v. Attached are
the output of a couple of runs. They differ only in the "RealTek chip
registers at 0xd800", so I've included those lines only for the 2nd and 3rd
case. I have no clue what this means.
------------------rtl8139-diag output for working network------------------
rtl8139-diag.c:v2.06 3/22/2002 Donald Becker (becker@scyld.com)
http://www.scyld.com/diag/index.html
Index #1: Found a RealTek RTL8139 adapter at 0xd800.
RealTek chip registers at 0xd800
0x000: 76843000 00006ecd 81000000 40000000 9008a04e 9008a046 9008a046
00002000
0x020: 0f368010 0f368610 0f368c10 0f369210 0f360000 0d0a0000 040003f0
0000c07f
0x040: 77000400 0000940e e1f7db3a 00000000 002c1000 00000000 008cc118
00100000
0x060: 1000700f 01e1782d 00000000 00000000 00000005 000f77c0 b0f243b9
8a36df43.
No interrupt sources are pending.
The chip configuration is 0x10 0x2c, MII half-duplex mode.
The RTL8139 does not use a MII transceiver.
It does have internal MII-compatible registers:
Basic mode control register 0x1000.
Basic mode status register 0x782d.
Autonegotiation Advertisement 0x01e1.
Link Partner Ability register 0x0000.
Autonegotiation expansion 0x0000.
Disconnects 0x0000.
False carrier sense counter 0x0000.
NWay test register 0x0005.
Receive frame error count 0x0000.
MII PHY #-1 transceiver registers:1111111111100000-> cccccccccccccccccccc
MII read of -1:0 -> 0000.
00001111111111100001-> cccccccccccccccccccc MII read of -1:1 -> 0000.
00001111111111100010-> cccccccccccccccccccc MII read of -1:2 -> 0000.
00001111111111100011-> cccccccccccccccccccc MII read of -1:3 -> 0000.
00001111111111100100-> cccccccccccccccccccc MII read of -1:4 -> 0000.
00001111111111100101-> cccccccccccccccccccc MII read of -1:5 -> 0000.
00001111111111100110-> cccccccccccccccccccc MII read of -1:6 -> 0000.
00001111111111100111-> cccccccccccccccccccc MII read of -1:7 -> 0000.
00001111111111101000-> cccccccccccccccccccc MII read of -1:8 -> 0000.
00001111111111101001-> cccccccccccccccccccc MII read of -1:9 -> 0000.
00001111111111101010-> cccccccccccccccccccc MII read of -1:10 -> 0000.
00001111111111101011-> cccccccccccccccccccc MII read of -1:11 -> 0000.
00001111111111101100-> cccccccccccccccccccc MII read of -1:12 -> 0000.
00001111111111101101-> cccccccccccccccccccc MII read of -1:13 -> 0000.
00001111111111101110-> cccccccccccccccccccc MII read of -1:14 -> 0000.
00001111111111101111-> cccccccccccccccccccc MII read of -1:15 -> 0000.
00001111111111110000-> cccccccccccccccccccc MII read of -1:16 -> 0000.
00001111111111110001-> cccccccccccccccccccc MII read of -1:17 -> 0000.
00001111111111110010-> cccccccccccccccccccc MII read of -1:18 -> 0000.
00001111111111110011-> cccccccccccccccccccc MII read of -1:19 -> 0000.
00001111111111110100-> cccccccccccccccccccc MII read of -1:20 -> 0000.
00001111111111110101-> cccccccccccccccccccc MII read of -1:21 -> 0000.
00001111111111110110-> cccccccccccccccccccc MII read of -1:22 -> 0000.
00001111111111110111-> cccccccccccccccccccc MII read of -1:23 -> 0000.
00001111111111111000-> cccccccccccccccccccc MII read of -1:24 -> 0000.
00001111111111111001-> cccccccccccccccccccc MII read of -1:25 -> 0000.
00001111111111111010-> cccccccccccccccccccc MII read of -1:26 -> 0000.
00001111111111111011-> cccccccccccccccccccc MII read of -1:27 -> 0000.
00001111111111111100-> cccccccccccccccccccc MII read of -1:28 -> 0000.
00001111111111111101-> cccccccccccccccccccc MII read of -1:29 -> 0000.
00001111111111111110-> cccccccccccccccccccc MII read of -1:30 -> 0000.
00001111111111111111-> cccccccccccccccccccc MII read of -1:31 -> 0000.
0000.
Basic mode control register 0x0000: Auto-negotiation disabled!
Speed fixed at 10 mbps, half-duplex.
1111111111100001-> cccccccccccccccccccc MII read of -1:1 -> 0000.
Basic mode status register 0x0000 ... 0000.
Link status: not established.
Capable of <Warning! No media capabilities>.
Unable to perform Auto-negotiation, negotiation not complete.
This transceiver has no vendor identification.
I'm advertising 0000:
Advertising no additional info pages.
Using an unknown (non 802.3) encapsulation.
Link partner capability is 0000:.
Negotiation did not complete.
------------------rtl8139-diag output for not-working network, case 1------
RealTek chip registers at 0xd800
0x000: 76843000 00006ecd 81000000 40000000 00002000 00002000 00002000
00002000
0x020: 0f368010 0f368610 0f368c10 0f369210 0f360000 0d0a0000 3fdc3fcc
0000c07f
0x040: 77000400 0000940e 7c1e77f3 00000000 002c1000 00000000 008cc118
00100000
0x060: 1000000f 01e1782d 00000000 00000000 00000005 000f77c0 b0f243b9
8a36df43
------------------rtl8139-diag output for not-working network, case 2------
RealTek chip registers at 0xd800
0x000: 76843000 00006ecd 81000000 40000000 00002000 00002000 00002000
00002000
0x020: 0f368010 0f368610 0f368c10 0f369210 0f360000 0d0a0000 28102800
0000c07f
0x040: 77000400 0000940e a26c3e62 00000000 002c1000 00000000 008cc118
00100000
0x060: 1000000f 01e1782d 00000000 00000000 00000005 000f77c0 b0f243b9
8a36df43
-------------------------end of rtl8139-diag output -----------------------
If anybody is interested, I'd be happy to send my patched version of the
1.18 driver. Obviously, I take no credit for these patches at all. It all
goes to Donald Becker and the people I mentioned before for the patches.
That's it really. We're going to try to stick in another network card
without RTL8139, such that I can forget about this mess. I'm posting all
this info hoping that my wasted time will benefit somebody else. If anybody
sorts out the problems with this driver, I'd still be interested. I won't
guarantee that I will test it though. Hopefully my other network card will
solve all my problems.
Good luck
Kris Thielemans
(kris.thielemans <at> ic.ac.uk)
Imaging Research Solutions Ltd
Cyclotron Building
Hammersmith Hospital
Du Cane Road
London W12 ONN, United Kingdom
web site address: http://www.irsl.org/~kris