Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
On Sun, Mar 07, 2010 at 03:50:37PM +, Ben Hutchings wrote: On Sun, 2010-03-07 at 20:48 +0600, Mikhail Gusarov wrote: Twas brillig at 14:41:10 07.03.2010 UTC+00 when t...@cyrius.com did gyre and gimble: Just tested it. Works fine here (mDNS resolves without promisc mode on interface), thanks. MM Good to hear! That patch also included some debugging output. Can MM you please send the output from dmesg? Attached. [looking at dmesg: wow, looks like I just found wireless card I lost some time ago - it's mini-PCI slot in NAS :] [...] [ 424.35] device eth0 left promiscuous mode [ 424.35] rtl_set_rx_mode: mc_filter = { 0x80088000, 0x40004000 } [ 424.35] rtl_set_rx_mode: MAR = 0x4000400040004000 [ 424.35] rtl_set_rx_mode: MAR = 0x4000400080088000 [...] As I suspected, writing the high bits also changes the low bits so we must write high before low. The next question is whether doing that works for all r8169 variants or whether it needs to be conditional. Has this been forwarded to net...@vger.kernel.org already? Cheers, Moritz -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
On Sat, 2010-05-01 at 23:13 +0200, Moritz Muehlenhoff wrote: On Sun, Mar 07, 2010 at 03:50:37PM +, Ben Hutchings wrote: On Sun, 2010-03-07 at 20:48 +0600, Mikhail Gusarov wrote: Twas brillig at 14:41:10 07.03.2010 UTC+00 when t...@cyrius.com did gyre and gimble: Just tested it. Works fine here (mDNS resolves without promisc mode on interface), thanks. MM Good to hear! That patch also included some debugging output. Can MM you please send the output from dmesg? Attached. [looking at dmesg: wow, looks like I just found wireless card I lost some time ago - it's mini-PCI slot in NAS :] [...] [ 424.35] device eth0 left promiscuous mode [ 424.35] rtl_set_rx_mode: mc_filter = { 0x80088000, 0x40004000 } [ 424.35] rtl_set_rx_mode: MAR = 0x4000400040004000 [ 424.35] rtl_set_rx_mode: MAR = 0x4000400080088000 [...] As I suspected, writing the high bits also changes the low bits so we must write high before low. The next question is whether doing that works for all r8169 variants or whether it needs to be conditional. Has this been forwarded to net...@vger.kernel.org already? It has, and it has even been fixed upstream: commit 78f1cd02457252e1ffbc6caa44a17424a45286b8 Author: Francois Romieu rom...@fr.zoreil.com Date: Sat Mar 27 19:35:46 2010 -0700 r8169: fix broken register writes Sorry for not keeping this bug up-to-date. This change has not yet been part of any upstream release and I would like to wait until it is, to see whether this change causes a regression for other chips handled by the driver. Ben. -- Ben Hutchings Once a job is fouled up, anything done to improve it makes it worse. signature.asc Description: This is a digitally signed message part
Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
Twas brillig at 02:30:22 15.02.2010 UTC+01 when j...@inutil.org did gyre and gimble: Jon, Sjoerg, Mikhail, Wouter: can one of you please test this kernel to see if it works on the N2100: http://merkel.debian.org/~tbm/tmp/kernel/linux-image-2.6.32-trunk-iop32x_2.6.32-4_armel.deb MM Did anyone test the kernel build? Just tested it. Works fine here (mDNS resolves without promisc mode on interface), thanks. -- http://fossarchy.blogspot.com/ pgpKybzzZi6kI.pgp Description: PGP signature
Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
* Mikhail Gusarov dotted...@dottedmag.net [2010-03-07 20:18]: Just tested it. Works fine here (mDNS resolves without promisc mode on interface), thanks. Good to hear! That patch also included some debugging output. Can you please send the output from dmesg? Thanks. -- Martin Michlmayr http://www.cyrius.com/ -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
Twas brillig at 14:41:10 07.03.2010 UTC+00 when t...@cyrius.com did gyre and gimble: Just tested it. Works fine here (mDNS resolves without promisc mode on interface), thanks. MM Good to hear! That patch also included some debugging output. Can MM you please send the output from dmesg? Attached. [looking at dmesg: wow, looks like I just found wireless card I lost some time ago - it's mini-PCI slot in NAS :] -- http://fossarchy.blogspot.com/ pgpWRkj6NV6MS.pgp Description: PGP signature 15.01] pci :00:04.0: reg 20 io port: [0x9800-0x981f] [ 15.01] pci :00:04.0: supports D1 D2 [ 15.01] pci :00:04.0: PME# supported from D0 D1 D2 D3hot [ 15.01] pci :00:04.0: PME# disabled [ 15.01] pci :00:04.1: reg 20 io port: [0x9820-0x983f] [ 15.01] pci :00:04.1: supports D1 D2 [ 15.01] pci :00:04.1: PME# supported from D0 D1 D2 D3hot [ 15.01] pci :00:04.1: PME# disabled [ 15.01] pci :00:04.2: reg 10 32bit mmio: [0x800a1400-0x800a14ff] [ 15.01] pci :00:04.2: supports D1 D2 [ 15.01] pci :00:04.2: PME# supported from D0 D1 D2 D3hot [ 15.01] pci :00:04.2: PME# disabled [ 15.01] pci :00:05.0: reg 10 32bit mmio: [0x800a-0x800a0fff] [ 15.01] pci :00:05.0: PME# supported from D0 D3hot D3cold [ 15.01] pci :00:05.0: PME# disabled [ 15.01] PCI: bus0: Fast back to back transfers disabled [ 15.01] bio: create slab bio-0 at 0 [ 15.01] vgaarb: loaded [ 15.02] NET: Registered protocol family 2 [ 15.02] IP route cache hash table entries: 4096 (order: 2, 16384 bytes) [ 15.03] TCP established hash table entries: 16384 (order: 5, 131072 bytes) [ 15.03] TCP bind hash table entries: 16384 (order: 4, 65536 bytes) [ 15.03] TCP: Hash tables configured (established 16384 bind 16384) [ 15.03] TCP reno registered [ 15.03] NET: Registered protocol family 1 [ 15.03] Unpacking initramfs... [ 17.13] Freeing initrd memory: 6612K [ 17.13] NetWinder Floating Point Emulator V0.97 (double precision) [ 17.13] audit: initializing netlink socket (disabled) [ 17.13] type=2000 audit(17.130:1): initialized [ 17.14] VFS: Disk quotas dquot_6.5.2 [ 17.14] Dquot-cache hash table entries: 1024 (order 0, 4096 bytes) [ 17.14] msgmni has been set to 1007 [ 17.14] alg: No test for stdrng (krng) [ 17.15] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 253) [ 17.15] io scheduler noop registered [ 17.15] io scheduler anticipatory registered [ 17.15] io scheduler deadline registered [ 17.15] io scheduler cfq registered (default) [ 17.16] Serial: 8250/16550 driver, 2 ports, IRQ sharing disabled [ 17.16] serial8250.0: ttyS0 at MMIO 0xfe80 (irq = 0) is a 16550A [ 17.16] physmap platform flash device: 0100 at f000 [ 17.16] physmap-flash.0: Found 1 x16 devices at 0x0 in 16-bit bank [ 17.16] Intel/Sharp Extended Query Table at 0x0031 [ 17.16] Intel/Sharp Extended Query Table at 0x0031 [ 17.16] Using buffer write method [ 17.16] cfi_cmdset_0001: Erase suspend on write enabled [ 17.16] erase region 0: offset=0x0,size=0x2,blocks=128 [ 17.16] Searching for RedBoot partition table in physmap-flash.0 at offset 0xfe [ 17.48] 6 RedBoot partitions found on MTD device physmap-flash.0 [ 17.48] Creating 6 MTD partitions on physmap-flash.0: [ 17.48] 0x-0x0004 : RedBoot [ 17.48] 0x0004-0x00d4 : ramdisk [ 17.48] 0x00d4-0x00ea : kernel [ 17.48] 0x00ea-0x00fc : user [ 17.48] 0x00fc-0x00fc1000 : RedBoot config [ 17.48] mtd: partition RedBoot config doesn't end on an erase block -- force read-only [ 17.48] 0x00fe-0x0100 : FIS directory [ 17.49] mice: PS/2 mouse device common for all mice [ 17.49] i2c /dev entries driver [ 17.49] rtc-rs5c372 0-0032: rs5c372b found, 24hr, driver version 0.6 [ 17.49] rtc-rs5c372 0-0032: rtc core: registered rtc-rs5c372 as rtc0 [ 17.50] pca9532 0-0060: setting platform data [ 17.50] Registered led device: n2100:red:satafail0 [ 17.50] Registered led device: n2100:red:satafail1 [ 17.50] Registered led device: n2100:blue:usb [ 17.50] Registered led device: n2100:red:usb [ 17.50] Registered led device: n2100:orange:system [ 17.50] Registered led device: n2100:red:system [ 17.50] input: N2100 beeper as /devices/virtual/input/input0 [ 17.52] iop-adma iop-adma.0: Intel(R) IOP: ( cpy intr ) [ 17.54] iop-adma iop-adma.1: Intel(R) IOP: ( cpy intr ) [ 17.54] TCP cubic registered [ 17.54] NET: Registered protocol family 17 [ 17.54] XScale DSP coprocessor detected. [ 17.54] registered taskstats version 1 [
Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
On Sun, 2010-03-07 at 20:48 +0600, Mikhail Gusarov wrote: Twas brillig at 14:41:10 07.03.2010 UTC+00 when t...@cyrius.com did gyre and gimble: Just tested it. Works fine here (mDNS resolves without promisc mode on interface), thanks. MM Good to hear! That patch also included some debugging output. Can MM you please send the output from dmesg? Attached. [looking at dmesg: wow, looks like I just found wireless card I lost some time ago - it's mini-PCI slot in NAS :] [...] [ 424.35] device eth0 left promiscuous mode [ 424.35] rtl_set_rx_mode: mc_filter = { 0x80088000, 0x40004000 } [ 424.35] rtl_set_rx_mode: MAR = 0x4000400040004000 [ 424.35] rtl_set_rx_mode: MAR = 0x4000400080088000 [...] As I suspected, writing the high bits also changes the low bits so we must write high before low. The next question is whether doing that works for all r8169 variants or whether it needs to be conditional. Ben. -- Ben Hutchings The most exhausting thing in life is being insincere. - Anne Morrow Lindberg signature.asc Description: This is a digitally signed message part
Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
* Mikhail Gusarov dotted...@dottedmag.net [2010-02-15 08:33]: MM Did anyone test the kernel build? Sorry, don't have serial attached to recover in case of problems. Is it enough to unpack the kernel and modules and load it using kexec? I've never tried kexec. If it works, then sure. -- Martin Michlmayr http://www.cyrius.com/ -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20100215165549.gn1...@jirafa.cyrius.com
Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
On Mon, Jan 04, 2010 at 03:30:57PM +, Martin Michlmayr wrote: Jon, Sjoerg, Mikhail, Wouter: can one of you please test this kernel to see if it works on the N2100: http://merkel.debian.org/~tbm/tmp/kernel/linux-image-2.6.32-trunk-iop32x_2.6.32-4_armel.deb Did anyone test the kernel build? Cheers, Moritz * Ben Hutchings b...@decadent.org.uk [2009-10-16 04:27]: I'd like to get this bug fixed in some way for the N2100, either by setting all bits in the multicast hash for this specific hardware (assuming we can detect it programmatically) or by adjusting the way we generate the multicast hash. Vince, do you have a test for this specific hardware? I know it's MAC type 4 (RTL8169SB/RTL8110SB) but this bug seems to be more specific than that. Some time back it was discovered that in MMIO mode the 64-bit address registers need to be written high-bits-first on this hardware, because writing the high 32 bits clears the low 32 bits. Given that the multicast hash table is also a 64-bit register, maybe it suffers from a similar bug? It might be worth trying the following change: --- a/drivers/net/r8169.c +++ b/drivers/net/r8169.c @@ -3781,8 +3781,18 @@ static void rtl_set_rx_mode(struct net_device *dev) mc_filter[1] = swab32(data); } + pr_info(%s: mc_filter = { 0x%08x, 0x%08x }\n, __func__, + mc_filter[0], mc_filter[1]); + RTL_W32(MAR0 + 0, mc_filter[0]); RTL_W32(MAR0 + 4, mc_filter[1]); + pr_info(%s: MAR = 0x%08lx%08lx\n, __func__, + RTL_R32(MAR0 + 4), RTL_R32(MAR0 + 0)); + + RTL_W32(MAR0 + 4, mc_filter[1]); + RTL_W32(MAR0 + 0, mc_filter[0]); + pr_info(%s: MAR = 0x%08lx%08lx\n, __func__, + RTL_R32(MAR0 + 4), RTL_R32(MAR0 + 0)); RTL_W32(RxConfig, tmp); --- END --- Ben. -- Ben Hutchings The most exhausting thing in life is being insincere. - Anne Morrow Lindberg -- Martin Michlmayr http://www.cyrius.com/ -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20100215013022.ga21...@galadriel.inutil.org
Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
Twas brillig at 02:30:22 15.02.2010 UTC+01 when j...@inutil.org did gyre and gimble: Jon, Sjoerg, Mikhail, Wouter: can one of you please test this kernel to see if it works on the N2100: http://merkel.debian.org/~tbm/tmp/kernel/linux-image-2.6.32-trunk-iop32x_2.6.32-4_armel.deb MM Did anyone test the kernel build? Sorry, don't have serial attached to recover in case of problems. Is it enough to unpack the kernel and modules and load it using kexec? -- http://fossarchy.blogspot.com/ pgp7keWEHG83Y.pgp Description: PGP signature
Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
Jon, Sjoerg, Mikhail, Wouter: can one of you please test this kernel to see if it works on the N2100: http://merkel.debian.org/~tbm/tmp/kernel/linux-image-2.6.32-trunk-iop32x_2.6.32-4_armel.deb * Ben Hutchings b...@decadent.org.uk [2009-10-16 04:27]: I'd like to get this bug fixed in some way for the N2100, either by setting all bits in the multicast hash for this specific hardware (assuming we can detect it programmatically) or by adjusting the way we generate the multicast hash. Vince, do you have a test for this specific hardware? I know it's MAC type 4 (RTL8169SB/RTL8110SB) but this bug seems to be more specific than that. Some time back it was discovered that in MMIO mode the 64-bit address registers need to be written high-bits-first on this hardware, because writing the high 32 bits clears the low 32 bits. Given that the multicast hash table is also a 64-bit register, maybe it suffers from a similar bug? It might be worth trying the following change: --- a/drivers/net/r8169.c +++ b/drivers/net/r8169.c @@ -3781,8 +3781,18 @@ static void rtl_set_rx_mode(struct net_device *dev) mc_filter[1] = swab32(data); } + pr_info(%s: mc_filter = { 0x%08x, 0x%08x }\n, __func__, + mc_filter[0], mc_filter[1]); + RTL_W32(MAR0 + 0, mc_filter[0]); RTL_W32(MAR0 + 4, mc_filter[1]); + pr_info(%s: MAR = 0x%08lx%08lx\n, __func__, + RTL_R32(MAR0 + 4), RTL_R32(MAR0 + 0)); + + RTL_W32(MAR0 + 4, mc_filter[1]); + RTL_W32(MAR0 + 0, mc_filter[0]); + pr_info(%s: MAR = 0x%08lx%08lx\n, __func__, + RTL_R32(MAR0 + 4), RTL_R32(MAR0 + 0)); RTL_W32(RxConfig, tmp); --- END --- Ben. -- Ben Hutchings The most exhausting thing in life is being insincere. - Anne Morrow Lindberg -- Martin Michlmayr http://www.cyrius.com/ -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#407217: Multicast broken in r8169 for one version of Thecus N2100
I'd like to get this bug fixed in some way for the N2100, either by setting all bits in the multicast hash for this specific hardware (assuming we can detect it programmatically) or by adjusting the way we generate the multicast hash. Vince, do you have a test for this specific hardware? I know it's MAC type 4 (RTL8169SB/RTL8110SB) but this bug seems to be more specific than that. Some time back it was discovered that in MMIO mode the 64-bit address registers need to be written high-bits-first on this hardware, because writing the high 32 bits clears the low 32 bits. Given that the multicast hash table is also a 64-bit register, maybe it suffers from a similar bug? It might be worth trying the following change: --- a/drivers/net/r8169.c +++ b/drivers/net/r8169.c @@ -3781,8 +3781,18 @@ static void rtl_set_rx_mode(struct net_device *dev) mc_filter[1] = swab32(data); } + pr_info(%s: mc_filter = { 0x%08x, 0x%08x }\n, __func__, + mc_filter[0], mc_filter[1]); + RTL_W32(MAR0 + 0, mc_filter[0]); RTL_W32(MAR0 + 4, mc_filter[1]); + pr_info(%s: MAR = 0x%08lx%08lx\n, __func__, + RTL_R32(MAR0 + 4), RTL_R32(MAR0 + 0)); + + RTL_W32(MAR0 + 4, mc_filter[1]); + RTL_W32(MAR0 + 0, mc_filter[0]); + pr_info(%s: MAR = 0x%08lx%08lx\n, __func__, + RTL_R32(MAR0 + 4), RTL_R32(MAR0 + 0)); RTL_W32(RxConfig, tmp); --- END --- Ben. -- Ben Hutchings The most exhausting thing in life is being insincere. - Anne Morrow Lindberg signature.asc Description: This is a digitally signed message part