From owner-freebsd-bugs@FreeBSD.ORG Mon Dec 6 20:30:24 2004 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7B62116A4CF for ; Mon, 6 Dec 2004 20:30:24 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 25CE943D70 for ; Mon, 6 Dec 2004 20:30:24 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.1/8.13.1) with ESMTP id iB6KUOo0001741 for ; Mon, 6 Dec 2004 20:30:24 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.1/8.13.1/Submit) id iB6KUOAf001739; Mon, 6 Dec 2004 20:30:24 GMT (envelope-from gnats) Resent-Date: Mon, 6 Dec 2004 20:30:24 GMT Resent-Message-Id: <200412062030.iB6KUOAf001739@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Mike Tancsa Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 797FB16A4CE for ; Mon, 6 Dec 2004 20:27:02 +0000 (GMT) Received: from www.freebsd.org (www.freebsd.org [216.136.204.117]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3191343D2F for ; Mon, 6 Dec 2004 20:27:02 +0000 (GMT) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.13.1/8.13.1) with ESMTP id iB6KR1fm096685 for ; Mon, 6 Dec 2004 20:27:01 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.13.1/8.13.1/Submit) id iB6KR1jE096684; Mon, 6 Dec 2004 20:27:01 GMT (envelope-from nobody) Message-Id: <200412062027.iB6KR1jE096684@www.freebsd.org> Date: Mon, 6 Dec 2004 20:27:01 GMT From: Mike Tancsa To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-2.3 Subject: misc/74786: Smartlink Modem causes interrupt storm on RELENG_4 and RELENG_5 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Dec 2004 20:30:24 -0000 >Number: 74786 >Category: misc >Synopsis: Smartlink Modem causes interrupt storm on RELENG_4 and RELENG_5 >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Dec 06 20:30:23 GMT 2004 >Closed-Date: >Last-Modified: >Originator: Mike Tancsa >Release: RELENG_4 and RELENG_5 >Organization: Sentex Communications >Environment: 4.10-STABLE FreeBSD 4.10-STABLE #6: Fri Nov 26 and FreeBSD releng5-865.sentex.ca 5.3-STABLE FreeBSD 5.3-STABLE #1: Wed Dec 1 >Description: I think we have been bouncing around this issue for the past few months both on RELENG_4 and RELENG_5. In the past it has been somewhat difficult to reproduce, but now we can do it reliably. I dont think its a hardware issue as I can take the exact same 2 boxes with the exact same IRQ assignments and boot with OpenBSD and not run into an interrupt storm or freeze up the box. Swap back the RELENG_4 or RELENG_5 HD and again, I can produce an interrupt storm at will. I can also reproduce it on 2 different chipsets as well (VIA and Intel). The problem seems to be around how a PUC device (either a PCI modem or a PCI serial card) and the sharing of an interrupt (usually an USB controller). On RELENG_4, the box just locks up in a race trying to service an interrupt on IRQ 12 but remains unhandled. On RELENG_5, I actually catch an interrupt storm. e.g. I attach to sio4 (PUC modem) and Interrupt storm detected on "irq12: uhci1"; throttling interrupt source Looking at vmstat -i does indeed show a the rate getting throttled releng-5-pioneer# vmstat -i interrupt total rate irq0: clk 596719 99 irq1: atkbd0 2 0 irq4: sio0 1079 0 irq6: fdc0 1 0 irq8: rtc 763812 127 irq12: uhci1 5825 0 irq13: npx0 1 0 irq14: ata0 38727 6 irq15: vr0 ata1 1984 0 Total 1408150 235 releng-5-pioneer# where irq12 is the IRQ shared by the modem and the USB port. However, because all IRQ 12s get throttled, the modem is unusable. e.g. trying to cu -l /dev/cuaa4 and typing atz takes about 5 seconds. The problem is that the modem is not being seen as a PCI / PUC device and instead is being seen as an ISA SIO device ?? The following RELENG_5 and RELENG_4 patches seem to fix the problem. I wonder if the other modems listed in sio.c suffer the same fate ? # cat /var/run/dmesg.boot Copyright (c) 1992-2004 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD 4.10-STABLE #6: Fri Nov 26 13:52:22 EST 2004 mdtancsa@station.sentex.ca:/usr/obj/usr/src/sys/gas Timecounter "i8254" frequency 1193182 Hz Timecounter "TSC" frequency 2400411816 Hz CPU: Intel(R) Celeron(R) CPU 2.40GHz (2400.41-MHz 686-class CPU) Origin = "GenuineIntel" Id = 0xf33 Stepping = 3 Features=0xbfebfbff real memory = 267321344 (261056K bytes) config> q avail memory = 256221184 (250216K bytes) Preloaded elf kernel "kernel" at 0xc03d5000. Preloaded userconfig_script "/boot/kernel.conf" at 0xc03d509c. Warning: Pentium 4 CPU: PSE disabled Pentium Pro MTRR support enabled md0: Malloc disk Using $PIR table, 8 entries at 0xc00fded0 npx0: on motherboard npx0: INT 16 interface pcib0: on motherboard pci0: on pcib0 agp0: port 0xd000-0xd007 mem 0xfa400000-0xfa47ffff,0xf0000000-0xf7ffffff at device 2.0 on pci0 agp0: detected 892k stolen memory agp0: aperture size is 128M uhci0: port 0xc000-0xc01f irq 15 at device 29.0 on pci0 usb0: on uhci0 usb0: USB revision 1.0 uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub0: 2 ports with 2 removable, self powered uhci1: port 0xc400-0xc41f irq 5 at device 29.1 on pci0 usb1: on uhci1 usb1: USB revision 1.0 uhub1: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub1: 2 ports with 2 removable, self powered uhid0: APC Back-UPS ES 500 FW:801.e5.D USB FW:e5, rev 1.10/1.06, addr 2, iclass 3/0 uhci2: port 0xc800-0xc81f irq 10 at device 29.2 on pci0 usb2: on uhci2 usb2: USB revision 1.0 uhub2: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub2: 2 ports with 2 removable, self powered uhci3: port 0xcc00-0xcc1f irq 15 at device 29.3 on pci0 usb3: on uhci3 usb3: USB revision 1.0 uhub3: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub3: 2 ports with 2 removable, self powered pcib1: at device 30.0 on pci0 pci1: on pcib1 rl0: port 0xa000-0xa0ff mem 0xf9000000-0xf90000ff irq 15 at device 4.0 on pci1 rl0: Ethernet address: 00:50:fc:c7:c2:f8 miibus0: on rl0 rlphy0: on miibus0 rlphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto puc0: port 0xa400-0xa407 irq 12 at device 5.0 on pci1 sio2: type 16550A fxp0: port 0xa800-0xa83f mem 0xf9001000-0xf9001fff irq 11 at device 8.0 on pci1 fxp0: Ethernet address 00:01:80:56:75:7a inphy0: on miibus1 inphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto puc1: port 0xb000-0xb007,0xac00-0xac07 irq 10 at device 10.0 on pci1 sio3: type 16550A sio4: type 16550A puc2: port 0xb800-0xb807,0xb400-0xb407 irq 10 at device 10.1 on pci1 sio5: type 16550A sio6: type 16550A isab0: at device 31.0 on pci0 isa0: on isab0 atapci0: port 0xf000-0xf00f,0-0x3,0-0x7,0-0x3,0-0x7 irq 0 at device 31.1 on pci0 ata0: at 0x1f0 irq 14 on atapci0 ata1: at 0x170 irq 15 on atapci0 ichsmb0: port 0x5000-0x501f irq 12 at device 31.3 on pci0 smbus0: on ichsmb0 smb0: on smbus0 orm0: