Bug 127248 - [ucom] panic while uplcom devices attach and detach
Summary: [ucom] panic while uplcom devices attach and detach
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: usb (show other bugs)
Version: 6.3-STABLE
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-usb (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-09-09 15:10 UTC by Alexey Lebedev
Modified: 2017-12-31 22:35 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexey Lebedev 2008-09-09 15:10:00 UTC
In our university we are using FreeBSD on Digital Alpha. We used to use DEC servers to connect our serial terminals to the servers via LAT (/usr/ports/net/latd). Now we're trying to replace the DEC servers with COM to USB adapters. We conneced all the terminals through the USB hub to one of our servers and it almost worked. We got getty prompt on the terminals but after awhile (in 10-20 minutes) getty prompt hands and in a few seconds the system crashes.

This is /var/run/dmesg.boot:

Copyright (c) 1992-2008 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 is a registered trademark of The FreeBSD Foundation.
FreeBSD 6.3-STABLE #2: Thu Aug  7 22:10:49 MSD 2008
    root@axp5.umc8.mai.ru:/usr/obj/usr/src/sys/AXP5
EB164
Digital AlphaPC 164LX 599 MHz, 598MHz
8192 byte page size, 1 processor.
CPU: EV56 (21164A) major=7 minor=2 extensions=0x1<BWX>
OSF PAL rev: 0x1000200020117
real memory  = 534691840 (509 MB)
avail memory = 512630784 (488 MB)
ath_hal: 0.9.20.3 (AR5210, AR5211, AR5212, RF5111, RF5112, RF2413, RF5413, REGOPS_FUNC)
cia0: <2117x Core Logic chipset>
cia0: Pyxis, pass 1
cia0: extended capabilities: 1<BWEN>
pcib0: <2117x PCI host bus adapter> on cia0
pci0: <PCI bus> on pcib0
ahc0: <Adaptec aic7899 Ultra160 SCSI adapter> port 0x10000-0x100ff mem 0x82040000-0x82040fff irq 0 at device 6.0 on pci0
ahc0: interrupting at CIA irq 0
ahc0: [GIANT-LOCKED]
aic7899: Ultra160 Wide Channel A, SCSI Id=7, 32/253 SCBs
ahc1: <Adaptec aic7899 Ultra160 SCSI adapter> port 0x10100-0x101ff mem 0x82041000-0x82041fff irq 7 at device 6.1 on pci0
ahc1: interrupting at CIA irq 7
ahc1: [GIANT-LOCKED]
aic7899: Ultra160 Wide Channel B, SCSI Id=7, 32/253 SCBs
uhci0: <VIA 83C572 USB controller> port 0x10300-0x1031f irq 1 at device 7.0 on pci0
uhci0: interrupting at CIA irq 1
uhci0: [GIANT-LOCKED]
usb0: <VIA 83C572 USB controller> on uhci0
usb0: USB revision 1.0
uhub0: VIA UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
uhci1: <VIA 83C572 USB controller> port 0x10320-0x1033f irq 8 at device 7.1 on pci0
uhci1: interrupting at CIA irq 8
uhci1: [GIANT-LOCKED]
usb1: <VIA 83C572 USB controller> on uhci1
usb1: USB revision 1.0
uhub1: VIA UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub1: 2 ports with 2 removable, self powered
pci0: <serial bus, USB> at device 7.2 (no driver attached)
isab0: <PCI-ISA bridge> at device 8.0 on pci0
isa0: <ISA bus> on isab0
rl0: <RealTek 8139 10/100BaseTX> port 0x10200-0x102ff mem 0x82042100-0x820421ff irq 3 at device 9.0 on pci0
miibus0: <MII bus> on rl0
rlphy0: <RealTek internal media interface> on miibus0
rlphy0:  10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
rl0: Ethernet address: 00:14:d1:11:03:cb
rl0: interrupting at CIA irq 3
atapci0: <SiI CMD 646 WDMA2 controller> port 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0x10350-0x1035f irq 5 at device 11.0 on pci0
ata0: <ATA channel 0> on atapci0
ata0: interrupting at ISA irq 14
ata1: <ATA channel 1> on atapci0
ata1: interrupting at ISA irq 15
atkbdc0: <Keyboard controller (i8042)> at port 0x60,0x64 on isa0
atkbd0: <AT Keyboard> irq 1 on atkbdc0
atkbd0: interrupting at ISA irq 1
atkbd0: [GIANT-LOCKED]
fdc0: <Enhanced floppy controller> at port 0x3f0-0x3f5,0x3f7 irq 6 drq 2 on isa0
fdc0: interrupting at ISA irq 6
fdc0: [FAST]
fd0: <1440-KB 3.5" drive> on fdc0 drive 0
mcclock0: <MC146818A real time clock> at port 0x70-0x71 on isa0
ppc0: <Parallel port> at port 0x3bc-0x3c3 irq 7 on isa0
ppc0: Generic chipset (EPP/NIBBLE) in COMPATIBLE mode
ppbus0: <Parallel port bus> on ppc0
lpt0: <Printer> on ppbus0
lpt0: Polled port
ppi0: <Parallel I/O> on ppbus0
ppc0: interrupting at ISA irq 7
sio0 at port 0x3f8-0x3ff irq 4 flags 0x10 on isa0
sio0: type 16550A, console
sio0: interrupting at ISA irq 4
sio1 at port 0x2f8-0x2ff irq 3 flags 0x80 on isa0
sio1: type 16550A
sio1: interrupting at ISA irq 3
uhub2: vendor 0x05e3 USB2.0 Hub, class 9/0, rev 2.00/7.02, addr 2
uhub2: 4 ports with 4 removable, self powered
uhub3: vendor 0x05e3 USB2.0 Hub, class 9/0, rev 2.00/7.02, addr 3
uhub3: 4 ports with 4 removable, self powered
ucom0: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 4
ucom1: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 5
uhub4: vendor 0x05e3 USB2.0 Hub, class 9/0, rev 2.00/7.02, addr 6
uhub4: 4 ports with 4 removable, self powered
ucom2: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 7
ucom3: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 8
ucom4: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 9
ucom5: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 10
ucom6: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 11
Timecounter "i8254" frequency 1193182 Hz quality 0
Timecounter "alpha" frequency 598802395 Hz quality 800
Timecounters tick every 0.976 msec
ipfw2 (+ipv6) initialized, divert enabled, rule-based forwarding enabled, default to deny, logging disabled
Waiting 5 seconds for SCSI devices to settle
acd0: CDRW <RICOH DVD+RW MP5240/1.19> at ata0-master WDMA2
da0 at ahc1 bus 0 target 0 lun 0
da0: <SEAGATE ST336737LW 0105> Fixed Direct Access SCSI-3 device 
da0: 160.000MB/s transfers (80.000MHz, offset 31, 16bit), Tagged Queueing Enabled
da0: 35242MB (72176566 512 byte sectors: 255H 63S/T 4492C)
da1 at ahc1 bus 0 target 1 lun 0
da1: <SEAGATE ST336737LW 0105> Fixed Direct Access SCSI-3 device 
da1: 160.000MB/s transfers (80.000MHz, offset 31, 16bit), Tagged Queueing Enabled
da1: 35242MB (72176566 512 byte sectors: 255H 63S/T 4492C)
cd0 at ata0 bus 0 target 0 lun 0
cd0: <RICOH DVD+RW MP5240 1.19> Removable CD-ROM SCSI-0 device 
cd0: 16.000MB/s transfers
cd0: Attempt to query device size failed: NOT READY, Medium not present
GEOM_MIRROR: Device gm0 created (id=1667621675).
GEOM_MIRROR: Device gm0: provider da0 detected.
GEOM_MIRROR: Device gm0: provider da1 detected.
GEOM_MIRROR: Device gm0: provider da1 activated.
GEOM_MIRROR: Device gm0: provider mirror/gm0 launched.
GEOM_MIRROR: Device gm0: rebuilding provider da0.
Trying to mount root from ufs:/dev/mirror/gm0a
WARNING: / was not properly dismounted
WARNING: /tmp was not properly dismounted
WARNING: /usr was not properly dismounted
fuse4bsd: version 0.3.9-pre1, FUSE ABI 7.8
rl0: promiscuous mode enabled
ucom3: ucomreadcb: IOERROR
ucom0: ucomreadcb: IOERROR
ucom6: ucomreadcb: IOERROR
ucom1: ucomreadcb: IOERROR
ucom2: ucomreadcb: IOERROR
ucom5: ucomreadcb: IOERROR
ucom4: ucomreadcb: IOERROR
uhub3: at uhub2 port 4 (addr 3) disconnected
ucom0: at uhub3 port 1 (addr 4) disconnected
ucom0: uplcom_set_line_status: STALLED
ucom0: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU0
ucom0: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
All threads purged from cuaU0
All threads purged from ttyU0
ucom0: detached
ucom1: at uhub3 port 2 (addr 5) disconnected
ucom1: uplcom_set_line_status: STALLED
ucom1: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU1
ucom1: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
All threads purged from cuaU1
All threads purged from ttyU1
ucom1: detached
uhub4: at uhub3 port 3 (addr 6) disconnected
ucom2: at uhub4 port 1 (addr 7) disconnected
ucom2: uplcom_set_line_status: STALLED
ucom2: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU2
ucom2: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
All threads purged from cuaU2
All threads purged from ttyU2
ucom2: detached
ucom3: at uhub4 port 2 (addr 8) disconnected
ucom3: uplcom_set_line_status: STALLED
All threads purged from cuaU3
All threads purged from ttyU3
ucom3: detached
ucom4: at uhub4 port 3 (addr 9) disconnected
ucom4: uplcom_set_line_status: STALLED
ucom4: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU4
ucom4: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
All threads purged from cuaU4
All threads purged from ttyU4
ucom4: detached
ucom5: at uhub4 port 4 (addr 10) disconnected
ucom5: uplcom_set_line_status: STALLED
ucom5: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU5
ucom5: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
All threads purged from cuaU5
All threads purged from ttyU5
ucom5: detached
uhub4: detached
ucom6: at uhub3 port 4 (addr 11) disconnected
ucom6: uplcom_set_line_status: STALLED
ucom6: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU6
ucom6: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
All threads purged from cuaU6
All threads purged from ttyU6
ucom6: detached
uhub3: detached
uhub3: vendor 0x05e3 USB2.0 Hub, class 9/0, rev 2.00/7.02, addr 3
uhub3: 4 ports with 4 removable, self powered
ucom0: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 4
ucom1: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 5
uhub4: vendor 0x05e3 USB2.0 Hub, class 9/0, rev 2.00/7.02, addr 6
uhub4: 4 ports with 4 removable, self powered
ucom2: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 7
ucom3: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 8
ucom4: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 9
ucom5: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 10
ucom6: Prolific Technology Inc. USB-Serial Controller, rev 1.10/3.00, addr 11
ucom4: ucomreadcb: IOERROR
ucom6: ucomreadcb: IOERROR
ucom5: ucomreadcb: IOERROR
ucom2: ucomreadcb: IOERROR
ucom1: ucomreadcb: IOERROR
ucom0: ucomreadcb: IOERROR
uhub2: at uhub1 port 2 (addr 2) disconnected
uhub3: at uhub2 port 4 (addr 3) disconnected
ucom0: at uhub3 port 1 (addr 4) disconnected
ucom0: uplcom_set_line_status: STALLED
ucom0: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU0
ucom0: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
Purging 2 threads from cuaU0
All threads purged from cuaU0
All threads purged from ttyU0
ucom0: detached
ucom1: at uhub3 port 2 (addr 5) disconnected
ucom1: uplcom_set_line_status: STALLED
ucom1: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU1
ucom1: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
Purging 2 threads from cuaU1
All threads purged from cuaU1
All threads purged from ttyU1
ucom1: detached
uhub4: at uhub3 port 3 (addr 6) disconnected
ucom2: at uhub4 port 1 (addr 7) disconnected
ucom2: uplcom_set_line_status: STALLED
ucom2: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU2
ucom2: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
Purging 2 threads from cuaU2
All threads purged from cuaU2
All threads purged from ttyU2
ucom2: detached
ucom3: at uhub4 port 2 (addr 8) disconnected
All threads purged from cuaU3
All threads purged from ttyU3
ucom3: detached
ucom4: at uhub4 port 3 (addr 9) disconnected
ucom4: uplcom_set_line_status: STALLED
ucom4: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU4
ucom4: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
Purging 2 threads from cuaU4
All threads purged from cuaU4
All threads purged from ttyU4
ucom4: detached
ucom5: at uhub4 port 4 (addr 10) disconnected
ucom5: uplcom_set_line_status: STALLED
ucom5: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU5
ucom5: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
Purging 2 threads from cuaU5
All threads purged from cuaU5
All threads purged from ttyU5
ucom5: detached
uhub4: detached
ucom6: at uhub3 port 4 (addr 11) disconnected
ucom6: uplcom_set_line_status: STALLED
ucom6: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU6
ucom6: uplcom_set_line_status: STALLED
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
Purging 2 threads from cuaU6
All threads purged from cuaU6
All threads purged from ttyU6

fatal kernel trap:

    trap entry     = 0x2 (memory management fault)
    cpuid          = 0
    faulting va    = 0x18
    type           = access violation
    cause          = load instructon
    pc             = 0xfffffc00005b9094
    ra             = 0xfffffc00005b9374
    sp             = 0xfffffe0010281a80
    curthread      = 0xfffffc001f510810
        pid = 27, comm = usb1

panic: trap
cpuid = 0
GEOM_MIRROR: Device gm0: rebuilding provider da0 stopped.
Uptime: 11m46s
Cannot dump. No dump device defined.
Automatic reboot in 15 seconds - press a key on the console to abort
Rebooting...


Let me know if you need any additional information.

Fix: 

Don't know how to fix the problem.
How-To-Repeat: To repeat the problem you need to connect many serial terminals via com->usb adapter to the server and run getty's on them, login and make some activities.
Comment 1 Gavin Atkinson freebsd_committer freebsd_triage 2008-09-10 17:17:30 UTC
State Changed
From-To: open->feedback

To submitter:  Are you able to compile the debugger into the kernel 
and obtain a backtrace next time it panics? 

Add the following to your kernel config file: 
options KDB 
options DDB 
options GDB 

Then when the machine crashes next, enter "bt" at the prompt? 
(Disclaimer: I've never used FreeBSD/alpha before, but this should work) 

By the way, my gut instinct is that this panic is caused by the fact the 
serial dongles seem to be disconnecting/reconnecting, and not specifically 
because the machine is an Alpha.  However, why they are disconnecting in 
the first place, I don't know.
Comment 2 Alexey Lebedev 2008-09-19 13:06:37 UTC
I've added KDB, GDB, DDB. That's the backtrace:

Tracing pid 28 tid 100026 td 0xfffffc001f510ac0
free_untl() at free_untl+0x114
free_unr() at free_unr+0xc4
devfs_free() at devfs_free+0x4c
destroy_devl() at destroy_devl+0x280
destroy_devl() at destroy_devl+0x78
destory_dev() at destroy_dev+0x24
ttyfree() at rryfree+0x30
ucom_detach() at ucom_detach+0x68
uplcom_detach() at uplcom_detach+0x48
device_detach() at device_detach+0x84
usb_disconnect_port() at usb_disconnect_port+0xf0
uhub_explore() at uhub_explore+0x214
uhub_explore() at uhub_explore+0x1cc
uhub_explore() at uhub_explore+0x1cc
uhub_explore() at uhub_explore+0x1cc
usb_discover() at usb_discover+0x48
usb_event_thread() at usb_event_thread+0xb8
fork_exit() at fork_exit+0xb0
exception_return() at exception_return
--- root of call fraph ---

I didn't find out how to copy this to email and just retyped it here by
hands, so there maybe some mistakes, even though i was very careful.
How to do that btw?
Comment 3 Gavin Atkinson freebsd_committer freebsd_triage 2009-04-16 13:47:29 UTC
State Changed
From-To: feedback->open

Feedback was received.
Comment 4 Gavin Atkinson freebsd_committer freebsd_triage 2009-04-16 13:49:29 UTC
Responsible Changed
From-To: freebsd-alpha->freebsd-usb

I suspect this isn't Alpha-specific.
Comment 5 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 08:01:14 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped