sis190
Quoted 5 lines
Message du 11/06/05 01:46
De : "Francois Romieu" <[email protected]>Andrew Hutchings <[email protected]> :
[...]
Quoted 7 lines
Quoted 2 lines
Something went wrong on build. Getting 'syntax error before '}' token' on every line there is
_msleep(1);I have checked it again and the patch applies and compiles correctly against 2.6.12-rc6. So does the updated patch of the day:
http://www.fr.zoreil.com/people/francois/misc/20050611-2.6.12-rc-sis190-test.patch
Sorry, but it does not compile correctly if you define CONFIG_SIS190_NO_DELAY.
# diff -puN /usr/src/linux/drivers/net/sis190.c sis190.c --- /usr/src/linux/drivers/net/sis190.c 2005-06-11 09:16:41.000000000 +0200 +++ sis190.c 2005-06-11 10:20:01.000000000 +0200 @@ -43,8 +43,8 @@ #endif
#ifdef CONFIG_SIS190_NO_DELAY
-#define s_mdelay(d) do { (d) } while (0)
-#define s_msleep(d) do { (d) } while (0)
+#define s_mdelay(d) do { } while (0)
+#define s_msleep(d) do { } while (0) #else
#define s_mdelay(d) mdelay(d)
#define s_msleep(d) msleep(d)
So it works.
Quoted 10 lines
No need to use
SIS190_NO_DELAYso far. The media negotiation process has been changed. It is now allowed to take longer to complete (it should help).dmesg and ifconfig output will be welcome.
--
Ueimor
It still do not work :
#dmesg
...
sis190 Gigabit Ethernet driver 1.2 loaded
ACPI: PCI Interrupt 0000:00:04.0[A] -> Link [LNKD] -> GSI 10 (level, low) -> IRQ 10
PCI: Setting latency timer of device 0000:00:04.0 to 64
0000:00:04.0: sis190 at ffffc20000026c00 (IRQ: 10), 00:11:2f:e9:42:70
eth0: Enabling Auto-negotiation.
eth0: Link on unknown mode.
eth0: no IPv6 routers present
eth0: status = 20000008
eth0: status = 00000004
eth0: status = 20000008
eth0: status = 00000004
eth0: pad error. status = 00000000
eth0: pad error. status = 00000000
eth0: pad error. status = 00000000
eth0: pad error. status = 00000000
...
#ifconfig
eth0 Link encap:Ethernet HWaddr 00:11:2F:E9:42:70
inet6 addr: fe80::211:2fff:fee9:4270/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:8 errors:248 dropped:0 overruns:0 frame:248
TX packets:8 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:762 (762.0 b) TX bytes:1404 (1.3 KiB)
Interrupt:10 Base address:0xbeefI compared sis190_rx_interrupt() in old and new driver, and i tried :
diff -puN /usr/src/linux/drivers/net/sis190.c sis190.c
sis190.c 2005-06-11 10:20:01.000000000 +0200 renamed from usr/src/linux/drivers/net/sis190.c 2005-06-11 09:16:41.000000000 +0200 +1 -1
@@ -478,7 +478,7 @@ static int sis190_rx_interrupt(struct ne rmb(); status = le32_to_cpu(desc->PSize); - if (status & OWNbit) + if (desc->status & OWNbit) break; if (status & RxCRC) {
new test :
# dmesg ... sis190 Gigabit Ethernet driver 1.2 loaded ACPI: PCI Interrupt 0000:00:04.0[A] -> Link [LNKD] -> GSI 10 (level, low) -> IRQ 10 PCI: Setting latency timer of device 0000:00:04.0 to 64 0000:00:04.0: sis190 at ffffc20000026c00 (IRQ: 10), 00:11:2f:e9:42:70 eth0: Enabling Auto-negotiation. eth0: Link on unknown mode. eth0: no IPv6 routers present eth0: status = 22000008 eth0: status = 00000004 eth0: status = 20000008 eth0: status = 00000004 eth0: status = 20000040 eth0: status = 20000040 eth0: status = 20000040 eth0: status = 20000040 eth0: status = 20000008 eth0: status = 00000004 ...
#ifconfig
eth0 Link encap:Ethernet HWaddr 00:11:2F:E9:42:70
inet6 addr: fe80::211:2fff:fee9:4270/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:6 errors:0 dropped:0 overruns:0 frame:0 TX packets:3 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000
RX bytes:1206 (1.1 KiB) TX bytes:1026 (1.0 KiB) Interrupt:10 Base address:0xbeef
As you can see, no more RX errors, but the network script failed to establish the link.
On the other box (dhcp server) :
#dmesg
...
eth2: link down
eth2: link up, 100Mbps, full-duplex, lpa 0x41E0
DHCPREQUEST for 10.169.21.20 from 00:11:2f:e9:42:70 via eth2: unknown lease 10.169.21.20. DHCPDISCOVER from 00:11:2f:e9:42:70 via eth2
DHCPOFFER on 10.169.21.47 to 00:11:2f:e9:42:70 via eth2
DHCPDISCOVER from 00:11:2f:e9:42:70 via eth2
DHCPOFFER on 10.169.21.47 to 00:11:2f:e9:42:70 via eth2
DHCPDISCOVER from 00:11:2f:e9:42:70 via eth2
DHCPOFFER on 10.169.21.47 to 00:11:2f:e9:42:70 via eth2
...
I also tried without dhcp :
# ifconfig
eth0 Link encap:Ethernet HWaddr 00:11:2F:E9:42:70
inet addr:10.169.21.20 Bcast:10.169.23.255 Mask:255.255.252.0
inet6 addr: fe80::211:2fff:fee9:4270/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:59 errors:0 dropped:0 overruns:0 frame:0
TX packets:43 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:4148 (4.0 KiB) TX bytes:1806 (1.7 KiB)
Interrupt:10 Base address:0xbeefping failed both sides, though RX and TX counters were incremented.
Regards
Pascal
Pascal CHAPPERON <[email protected]> :
[...]
Quoted 1 line
Sorry, but it does not compile correctly if you define
CONFIG_SIS190_NO_DELAY.
The safe choice is to not define it. I did not make it clear enough.
[...]
sis190.c 2005-06-11 10:20:01.000000000 +0200 static int sis190_rx_interrupt(struct ne · line 484
Quoted 13 lines
I compared
sis190_rx_interrupt()in old and new driver, and i tried :
diff -puN/usr/src/linux/drivers/net/sis190.csis190.csis190.c 2005-06-11 10:20:01.000000000 +0200 renamed from usr/src/linux/drivers/net/sis190.c 2005-06-11 09:16:41.000000000 +0200 +1
-1@@ -478,7 +478,7 @@ static int sis190_rx_interrupt(struct ne rmb(); status = le32_to_cpu(desc->PSize); - if (status & OWNbit) + if (desc->status & OWNbit) break; if (status & RxCRC) {
Good catch.
[...]
Quoted 12 lines
I also tried without dhcp :
# ifconfig eth0 Link encap:Ethernet HWaddr 00:11:2F:E9:42:70 inet addr:10.169.21.20 Bcast:10.169.23.255 Mask:255.255.252.0 inet6 addr: fe80::211:2fff:fee9:4270/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:59 errors:0 dropped:0 overruns:0 frame:0 TX packets:43 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:4148 (4.0 KiB) TX bytes:1806 (1.7 KiB) Interrupt:10 Base address:0xbeef
Quoted 1 line
ping failed both sides, though RX and TX counters were incremented.
Can you reproduce the tests (dhcp/no dhcp) with the patch linked below and add a tcpdump -x output taken at the server as an addition to the usual information ?
http://www.fr.zoreil.com/people/francois/misc/20050611a-2.6.12-rc-sis190-test.patch
If you are in a hurry and have any output, I'll look at it today (~18h).
Thanks.
--
Ueimor