Re: de2104x: interrupts before interrupt handler is registered
* Martin Michlmayr [EMAIL PROTECTED] [2006-03-07 05:11]: * Francois Romieu [EMAIL PROTECTED] [2006-03-06 22:17]: Not sure about this one, but... It seems to help. It's hard to say for sure because I don't have a foolproof way to reproduce this panic. It _usually_ occurs after copying a few hundred MB but there's no clear trigger. I've now copied a few GB around using a kernel with your patch and it hasn't crashed. I'm pretty sure now that your patch helps. I left the system running overnight and it was still alive in the morning after transferring ~10 GB. I do get all kind of underrun messages (see below) but the data got transferred alright. I then rebooted with the kernel that doesn't have your patch and it crashed after ~1 GB. (this was at about 3 GB, but the same goes on and on; but the network works.) eth0 Link encap:Ethernet HWaddr 00:80:C8:33:4F:96 inet addr:192.168.1.145 Bcast:192.168.1.255 Mask:255.255.255.0 inet6 addr: fe80::280:c8ff:fe33:4f96/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:1199533 errors:7 dropped:0 overruns:7 frame:0 TX packets:2344296 errors:396 dropped:252 overruns:396 carrier:0 collisions:0 txqueuelen:1000 RX bytes:64846004 (61.8 MiB) TX bytes:3479989567 (3.2 GiB) Interrupt:10 Base address:0x2000 loLink encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:8 errors:0 dropped:0 overruns:0 frame:0 TX packets:8 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:560 (560.0 b) TX bytes:560 (560.0 b) Adding 136512k swap on /dev/hda5. Priority:-1 extents:1 across:136512k EXT3 FS on hda1, internal journal device-mapper: 4.5.0-ioctl (2005-10-04) initialised: [EMAIL PROTECTED] eth0: enabling interface eth0: set link 10baseT auto eth0:mode 0x7ffc0040, sia 0x10c4,0xef01,0x,0x0008 eth0:set mode 0x7ffc0040, set sia 0xef01,0x,0x8 eth0: link up, media 10baseT auto NET: Registered protocol family 10 lo: Disabled Privacy Extensions IPv6 over IPv4 tunneling driver eth0: no IPv6 routers present kjournald starting. Commit interval 5 seconds EXT3 FS on dm-0, internal journal EXT3-fs: recovery complete. EXT3-fs: mounted filesystem with ordered data mode. eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb022 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb012 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0:
Re: de2104x: interrupts before interrupt handler is registered
* Martin Michlmayr [EMAIL PROTECTED] [2006-03-06 19:17]: There's another interrupt related bug in the driver, though. I There's yet another bug (or two). I just got another kernel panic: http://www.cyrius.com/tmp/de2104x_panic2.jpg (which I haven't been able to reproduce so far; this was without your latest patch applied, btw). This happened when I was doing DHCP while my server was not responding to DHCP. I wonder if it's related to another issue I've observed. This card is a D-Link DE 530 with both a BNC and RJ-45 connector. When I boot my machine without having the Ethernet cable plugged in, Linux thinks there's a BNC connection. When I plug in the cable, the link light on the card goes on but Linux doesn't seem to notice - in fact, when I then start DHCP again, the link light goes off again and Linux talks about BNC being up... [FWIW, Linux 2.4 doesn't handle this situation either. Under 2.4 the link light doesn't even come up.] dmesg: booting without the RJ-45 cable plugged in, doing DHCP, then plugging the RJ-45 cable in and doing DHCP again: hda: 4999680 sectors (2559 MB) w/256KiB Cache, CHS=4960/16/63, UDMA(33) hda: hda1 hda2 hda5 hda6 ACPI: PCI Interrupt :00:0b.0[A] - Link [LNKD] - GSI 10 (level, low) - IRQ 10 de0: SROM leaf offset 30, default media 10baseT auto de0: media block #0: 10baseT-FD de0: media block #1: BNC de0: media block #2: 10baseT-HD eth0: 21041 at 0xb8802000, 00:80:c8:33:4f:96, IRQ 10 Probing IDE interface ide1... Attempting manual resume kjournald starting. Commit interval 5 seconds EXT3-fs: mounted filesystem with ordered data mode. Real Time Clock Driver v1.12ac input: PC Speaker as /class/input/input1 FDC 0 is a post-1991 82077 parport: PnPBIOS parport detected. parport0: PC-style at 0x378, irq 7 [PCSPP,TRISTATE] Adding 136512k swap on /dev/hda5. Priority:-1 extents:1 across:136512k EXT3 FS on hda1, internal journal device-mapper: 4.5.0-ioctl (2005-10-04) initialised: [EMAIL PROTECTED] eth0: enabling interface eth0: set link 10baseT auto eth0:mode 0x7ffc0040, sia 0x10c4,0xef01,0x,0x0008 eth0:set mode 0x7ffc0040, set sia 0xef01,0x,0x8 eth0: set link BNC eth0:mode 0x7ffc, sia 0x10c4,0xef09,0xf7fd,0x0006 eth0:set mode 0x7ffc, set sia 0xef09,0xf7fd,0x6 eth0: link up, media BNC NET: Registered protocol family 10 lo: Disabled Privacy Extensions IPv6 over IPv4 tunneling driver eth0: no IPv6 routers present eth0: disabling interface eth0: timeout expired stopping DMA ACPI: PCI interrupt for device :00:0b.0 disabled eth0: enabling interface eth0: set link BNC eth0:mode 0x7ffc0040, sia 0x10c4,0xef09,0xf7fd,0x0006 eth0:set mode 0x7ffc0040, set sia 0xef09,0xf7fd,0x6 ADDRCONF(NETDEV_UP): eth0: link is not ready eth0: link up, media BNC ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready eth0: no IPv6 routers present As a comparison, this happens when I boot with the RJ-45 cable plugged in: ACPI: PCI Interrupt :00:0b.0[A] - Link [LNKD] - GSI 10 (level, low) - IRQ 10 de0: SROM leaf offset 30, default media 10baseT auto de0: media block #0: 10baseT-FD de0: media block #1: BNC de0: media block #2: 10baseT-HD eth0: 21041 at 0xb8802000, 00:80:c8:33:4f:96, IRQ 10 Probing IDE interface ide1... Attempting manual resume kjournald starting. Commit interval 5 seconds EXT3-fs: mounted filesystem with ordered data mode. Real Time Clock Driver v1.12ac input: PC Speaker as /class/input/input1 FDC 0 is a post-1991 82077 parport: PnPBIOS parport detected. parport0: PC-style at 0x378, irq 7 [PCSPP,TRISTATE] Adding 136512k swap on /dev/hda5. Priority:-1 extents:1 across:136512k EXT3 FS on hda1, internal journal device-mapper: 4.5.0-ioctl (2005-10-04) initialised: [EMAIL PROTECTED] eth0: enabling interface eth0: set link 10baseT auto eth0:mode 0x7ffc0040, sia 0x10c4,0xef01,0x,0x0008 eth0:set mode 0x7ffc0040, set sia 0xef01,0x,0x8 eth0: link up, media 10baseT auto NET: Registered protocol family 10 lo: Disabled Privacy Extensions IPv6 over IPv4 tunneling driver eth0: no IPv6 routers present -- Martin Michlmayr http://www.cyrius.com/ - To unsubscribe from this list: send the line unsubscribe netdev in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: de2104x: interrupts before interrupt handler is registered
* Francois Romieu [EMAIL PROTECTED] [2006-03-08 01:15]: netdev watchdog events appear in the dmesg of the patched driver. The driver survived it. So I'd say that the patch does its job. OTOH, if you ever saw the unpatched driver survive this event, yell now. No, I've never seen the unpatched driver survive. -- Martin Michlmayr http://www.cyrius.com/ - To unsubscribe from this list: send the line unsubscribe netdev in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: de2104x: interrupts before interrupt handler is registered
* Francois Romieu [EMAIL PROTECTED] [2006-03-05 19:59]: I have a system on which I can reproduce this bug 100%. While I have no idea how to fix the issue, I can provide debugging information and test a fix. (not compile-tested) Thanks a lot for your quick response, Francois. I can confirm that this patch fixes the problem for me. -err_out_hw: - spin_lock_irqsave(de-lock, flags); - de_stop_hw(de); - spin_unlock_irqrestore(de-lock, flags); flags is no longer used now, so we get a compilation warning. Updated patch below. Francois, can you please submit it with a proper changelog entry and your Signed-off-by. From: Francois Romieu [EMAIL PROTECTED] Signed-off-by: Martin Michlmayr [EMAIL PROTECTED] --- a/drivers/net/tulip/de2104x.c +++ b/drivers/net/tulip/de2104x.c @@ -1362,7 +1362,6 @@ static int de_open (struct net_device *d { struct de_private *de = dev-priv; int rc; - unsigned long flags; if (netif_msg_ifup(de)) printk(KERN_DEBUG %s: enabling interface\n, dev-name); @@ -1376,18 +1375,20 @@ static int de_open (struct net_device *d return rc; } - rc = de_init_hw(de); - if (rc) { - printk(KERN_ERR %s: h/w init failure, err=%d\n, - dev-name, rc); - goto err_out_free; - } + dw32(IntrMask, 0); rc = request_irq(dev-irq, de_interrupt, SA_SHIRQ, dev-name, dev); if (rc) { printk(KERN_ERR %s: IRQ %d request failure, err=%d\n, dev-name, dev-irq, rc); - goto err_out_hw; + goto err_out_free; + } + + rc = de_init_hw(de); + if (rc) { + printk(KERN_ERR %s: h/w init failure, err=%d\n, + dev-name, rc); + goto err_out_free_irq; } netif_start_queue(dev); @@ -1395,11 +1396,8 @@ static int de_open (struct net_device *d return 0; -err_out_hw: - spin_lock_irqsave(de-lock, flags); - de_stop_hw(de); - spin_unlock_irqrestore(de-lock, flags); - +err_out_free_irq: + free_irq(dev-irq, dev); err_out_free: de_free_rings(de); return rc; -- Martin Michlmayr http://www.cyrius.com/ - To unsubscribe from this list: send the line unsubscribe netdev in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: de2104x: interrupts before interrupt handler is registered
Martin Michlmayr [EMAIL PROTECTED] : [...] There's another interrupt related bug in the driver, though. I sometimes get a kernel panic when rsycing several 100 megs of data across the LAN. A picture showing the call trace can be found at http://www.cyrius.com/tmp/de2104x_panic.jpg Can you publish the .config ? -- Ueimor - To unsubscribe from this list: send the line unsubscribe netdev in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: de2104x: interrupts before interrupt handler is registered
* Francois Romieu [EMAIL PROTECTED] [2006-03-06 20:48]: There's another interrupt related bug in the driver, though. I sometimes get a kernel panic when rsycing several 100 megs of data across the LAN. A picture showing the call trace can be found at http://www.cyrius.com/tmp/de2104x_panic.jpg Can you publish the .config ? http://www.cyrius.com/tmp/config-2.6.16-rc5-486 By the way, I'm getting the following messages in dmesg: eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb00a eth0: tx err, status 0x7fffb002 eth0: tx err, status 0x7fffb032 eth0: tx err, status 0x7fffb002 -- Martin Michlmayr http://www.cyrius.com/ - To unsubscribe from this list: send the line unsubscribe netdev in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: de2104x: interrupts before interrupt handler is registered
Martin Michlmayr [EMAIL PROTECTED] : [...] http://www.cyrius.com/tmp/config-2.6.16-rc5-486 By the way, I'm getting the following messages in dmesg: netconsole appears enabled. Do you use it ? -- Ueimor - To unsubscribe from this list: send the line unsubscribe netdev in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: de2104x: interrupts before interrupt handler is registered
Martin Michlmayr [EMAIL PROTECTED] : [...] By the way, I'm getting the following messages in dmesg: eth0: tx err, status 0x7fffb002 Tx underrun. Is there anything which could induce a noticeable load on the PCI bus ? -- Ueimor - To unsubscribe from this list: send the line unsubscribe netdev in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: de2104x: interrupts before interrupt handler is registered
* Francois Romieu [EMAIL PROTECTED] [2006-03-06 21:54]: By the way, I'm getting the following messages in dmesg: eth0: tx err, status 0x7fffb002 Tx underrun. Is there anything which could induce a noticeable load on the PCI bus ? I was going to say no because I was simply copying some data via the network. However, it seems the situation is a bit more complicated than this. It seems that I only get these underruns using a specific hard drive. You see, the reason I'm rsyncing hundred of megabytes of data across my LAN is because my laptop hard drive is dying, so I put it in a PC as secondary master using an adapter. Interestingly enough, I don't get any Tx underruns when using a different disk. Which is strange because at the moment the disk is working fine (it sort of started dying but seems to behave right now), so I don't know why it would change anything. Maybe this makes sense to someone. By the way, I only get underruns when I rsync from the PC to another machine - not when I rsync from the other machine to the PC. -- Martin Michlmayr http://www.cyrius.com/ - To unsubscribe from this list: send the line unsubscribe netdev in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html