Skip to contentSkip to conversation

r8169.c broke for me from 2.6.20.4 to 2.6.21

DISCUSSION Francois Romieu 2 participants 3 messages May 2, 2007 – May 27, 2007 1 message not in the archive

Subsystems (2)
lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

Please don't trim the Cc:. The bugs must be processed publicly to feed the oracle.

Jelle Foks <[email protected]> :

Quoted 1 line

Francois Romieu wrote:

[...]

Quoted 4 lines
Quoted 3 lines

Can you:
- send the output of a 'lspci -vvx'

See attached lspci.txt, the ethernet card chip, obviously, at 00:0b.0

Plain old 8169. Ok.

[...]

Quoted 17 lines
Quoted 3 lines

- send the output of mii-tool including hex dump of the registers with 2.6.20.4 and 2.6.21

$ sudo /sbin/mii-tool -v -v
Using SIOCGMIIPHY=0x8947
eth1: 10 Mbit, half duplex, link ok
  registers for MII PHY 32:
    0000 794d 001c c910 0de1 0020 0004 2001
    0000 0300 0000 1000 1007 f880 0000 3000
    0060 0c00 0000 0000 0060 0000 009a 0108
    2740 0088 0000 8000 8400 0000 0000 4830
  product info: vendor 00:07:32, model 17 rev 0
  basic mode:   10 Mbit, half duplex
  basic status: link ok
  capabilities: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD
  advertising:  100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD flow-control
  link partner: 10baseT-HD

1. Can you send the output of mii-tool on the other kernel too ?

2. Any change if you use the patch below on 2.6.21 ? No need to wait for minutes if it does not perform better btw.

drivers/net/r8169.c +2 -1
index 5b42176..d2082ef 100644
@@ -525,7 +525,8 @@ static unsigned int rtl8169_tbi_link_ok(void __iomem *ioaddr)
 
 static unsigned int rtl8169_xmii_link_ok(void __iomem *ioaddr)
 {
-	return RTL_R8(PHYstatus) & LinkStatus;
+	return (RTL_R8(PHYstatus) & LinkStatus) ? 1 :
+		(RTL_R8(PHYstatus) & LinkStatus);
 }
 
 static void rtl8169_tbi_reset_enable(void __iomem *ioaddr)
Signature · 3 lines
Ueimor

Anybody got a battery for my Ultra 10 ?
#2 lore raw
Quoted 2 lines · Francois Romieu

Please don't trim the Cc:. The bugs must be processed publicly to feed the oracle.

Ok.

Quoted 30 lines

Jelle Foks <[email protected]> :

Quoted 1 line

Francois Romieu wrote:

[...]

Quoted 4 lines
Quoted 3 lines

Can you:
- send the output of a 'lspci -vvx'

See attached lspci.txt, the ethernet card chip, obviously, at 00:0b.0

Plain old 8169. Ok.

[...]

Quoted 17 lines
Quoted 3 lines

- send the output of mii-tool including hex dump of the registers with 2.6.20.4 and 2.6.21

$ sudo /sbin/mii-tool -v -v
Using SIOCGMIIPHY=0x8947
eth1: 10 Mbit, half duplex, link ok
  registers for MII PHY 32:
    0000 794d 001c c910 0de1 0020 0004 2001
    0000 0300 0000 1000 1007 f880 0000 3000
    0060 0c00 0000 0000 0060 0000 009a 0108
    2740 0088 0000 8000 8400 0000 0000 4830
  product info: vendor 00:07:32, model 17 rev 0
  basic mode:   10 Mbit, half duplex
  basic status: link ok
  capabilities: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD
  advertising:  100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD flow-control
  link partner: 10baseT-HD
Quoted 2 lines

1. Can you send the output of mii-tool on the other kernel too ? From the 2.6.21 pristine, when the link stays down:

Using SIOCGMIIPHY=0x8947
eth1: no link
registers for MII PHY 32:

    1000 7949 001c c910 0de1 0000 0004 2001
    0000 0300 0000 1000 1007 f880 0000 3000
    0060 4000 0000 0040 0060 0000 0098 0108
    2740 0088 0000 8000 8400 0000 0000 0840

product info: vendor 00:07:32, model 17 rev 0
basic mode: autonegotiation enabled
basic status: no link
capabilities: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD
advertising: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD flow-control

Quoted 3 lines

2. Any change if you use the patch below on 2.6.21 ? No need to wait for minutes if it does not perform better btw.

No changes, link stays down, just like with 2.6.21 pristine.

Hope this helps,

Jelle.

Quoted 16 lines
drivers/net/r8169.c +2 -1
index 5b42176..d2082ef 100644
@@ -525,7 +525,8 @@ static unsigned int rtl8169_tbi_link_ok(void __iomem *ioaddr)
 
 static unsigned int rtl8169_xmii_link_ok(void __iomem *ioaddr)
 {
-	return RTL_R8(PHYstatus) & LinkStatus;
+	return (RTL_R8(PHYstatus) & LinkStatus) ? 1 :
+		(RTL_R8(PHYstatus) & LinkStatus);
 }
 
 static void rtl8169_tbi_reset_enable(void __iomem *ioaddr)