Panic on attempt to write to USB 2.0 mass storage device.
Step to reproduce:
- attach USB flash
- mount it
- start copying files to mass storage
- try to get a list of files on flash via ls(1) several times
Unfortunately reproduction is not 100%
OpenBSD 5.4-beta (GENERIC) #0: Mon Jul 15 23:06:59 MSK 2013
[email protected]:/usr/src/sys/arch/amd64/compile/GENERIC
real mem = 4168839168 (3975MB)
avail mem = 4050149376 (3862MB)
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 2.4 @ 0xe0010 (80 entries)
bios0: vendor LENOVO version "7VET80WW (3.10 )" date 10/02/2009
bios0: LENOVO 406257G
acpi0 at bios0: rev 2
acpi0: sleep states S0 S3 S4 S5
acpi0: tables DSDT FACP SSDT ECDT APIC MCFG HPET SLIC BOOT SSDT SSDT SSDT SSDT
acpi0: wakeup devices LID_(S3) SLPB(S3) UART(S3) IGBE(S4) EXP0(S4) EXP1(S4)
EXP2(S4) EXP3(S4) EXP4(S4) PCI1(S4) USB0(S3) USB3(S3) USB5(S3) EHC0(S3)
EHC1(S3) HDEF(S4)
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpiec0 at acpi0
acpimadt0 at acpi0 addr 0xfee00000: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Intel(R) Core(TM)2 Duo CPU T9600 @ 2.80GHz, 798.14 MHz
cpu0:
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,XSAVE,NXE,LONG,LAHF,PERF
cpu0: 6MB 64b/line 16-way L2 cache
cpu0: smt 0, core 0, package 0
cpu0: apic clock running at 266MHz
cpu at mainbus0: not configured
ioapic0 at mainbus0: apid 1 pa 0xfec00000, version 20, 24 pins
ioapic0: misconfigured as apic 2, remapped to apid 1
acpimcfg0 at acpi0 addr 0xe0000000, bus 0-63
acpihpet0 at acpi0: 14318179 Hz
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus -1 (AGP_)
acpiprt2 at acpi0: bus 2 (EXP0)
acpiprt3 at acpi0: bus 3 (EXP1)
acpiprt4 at acpi0: bus 4 (EXP2)
acpiprt5 at acpi0: bus 5 (EXP3)
acpiprt6 at acpi0: bus 13 (EXP4)
acpiprt7 at acpi0: bus 21 (PCI1)
acpicpu0 at acpi0: C3, C2, C1, PSS
acpipwrres0 at acpi0: PUBS
acpitz0 at acpi0: critical temperature is 127 degC
acpitz1 at acpi0: critical temperature is 100 degC
acpibtn0 at acpi0: LID_
acpibtn1 at acpi0: SLPB
acpibat0 at acpi0: BAT0 model "42T4620" serial 929 type LION oem "Panasonic"
acpibat1 at acpi0: BAT1 not present
acpiac0 at acpi0: AC unit online
acpithinkpad0 at acpi0
acpidock0 at acpi0: GDCK not docked (0)
cpu0: Enhanced SpeedStep 798 MHz: speeds: 2801, 2800, 2133, 1600, 800 MHz
pci0 at mainbus0 bus 0
pchb0 at pci0 dev 0 function 0 "Intel GM45 Host" rev 0x07
vga1 at pci0 dev 2 function 0 "Intel GM45 Video" rev 0x07
intagp0 at vga1
agp0 at intagp0: aperture at 0xd0000000, size 0x10000000
inteldrm0 at vga1
drm0 at inteldrm0
inteldrm0: 1920x1200
wsdisplay0 at vga1 mux 1: console (std, vt100 emulation)
wsdisplay0: screen 1-5 added (std, vt100 emulation)
"Intel GM45 Video" rev 0x07 at pci0 dev 2 function 1 not configured
"Intel GM45 HECI" rev 0x07 at pci0 dev 3 function 0 not configured
em0 at pci0 dev 25 function 0 "Intel ICH9 IGP M" rev 0x03: msi, address
00:22:68:18:b1:0f
uhci0 at pci0 dev 26 function 0 "Intel 82801I USB" rev 0x03: apic 1 int 20
uhci1 at pci0 dev 26 function 1 "Intel 82801I USB" rev 0x03: apic 1 int 21
uhci2 at pci0 dev 26 function 2 "Intel 82801I USB" rev 0x03: apic 1 int 22
ehci0 at pci0 dev 26 function 7 "Intel 82801I USB" rev 0x03: apic 1 int 23
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 "Intel EHCI root hub" rev 2.00/1.00 addr 1
azalia0 at pci0 dev 27 function 0 "Intel 82801I HD Audio" rev 0x03: msi
azalia0: codecs: Conexant CX20561, 0x0000/0x0000, using Conexant CX20561
audio0 at azalia0
ppb0 at pci0 dev 28 function 0 "Intel 82801I PCIE" rev 0x03: msi
pci1 at ppb0 bus 2
ppb1 at pci0 dev 28 function 1 "Intel 82801I PCIE" rev 0x03: msi
pci2 at ppb1 bus 3
iwn0 at pci2 dev 0 function 0 "Intel WiFi Link 5100" rev 0x00: msi, MIMO 1T2R,
MoW, address 00:26:c6:41:b8:2e
ppb2 at pci0 dev 28 function 2 "Intel 82801I PCIE" rev 0x03: msi
pci3 at ppb2 bus 4
"Intel Turbo Memory" rev 0x11 at pci3 dev 0 function 0 not configured
ppb3 at pci0 dev 28 function 3 "Intel 82801I PCIE" rev 0x03: msi
pci4 at ppb3 bus 5
ppb4 at pci0 dev 28 function 4 "Intel 82801I PCIE" rev 0x03: msi
pci5 at ppb4 bus 13
uhci3 at pci0 dev 29 function 0 "Intel 82801I USB" rev 0x03: apic 1 int 16
uhci4 at pci0 dev 29 function 1 "Intel 82801I USB" rev 0x03: apic 1 int 17
uhci5 at pci0 dev 29 function 2 "Intel 82801I USB" rev 0x03: apic 1 int 18
ehci1 at pci0 dev 29 function 7 "Intel 82801I USB" rev 0x03: apic 1 int 19
usb1 at ehci1: USB revision 2.0
uhub1 at usb1 "Intel EHCI root hub" rev 2.00/1.00 addr 1
ppb5 at pci0 dev 30 function 0 "Intel 82801BAM Hub-to-PCI" rev 0x93
pci6 at ppb5 bus 21
cbb0 at pci6 dev 0 function 0 "Ricoh 5C476 CardBus" rev 0xba: apic 1 int 16
sdhc0 at pci6 dev 0 function 2 "Ricoh 5C822 SD/MMC" rev 0x21: apic 1 int 18
sdmmc0 at sdhc0
"Ricoh 5C843 MMC" rev 0x11 at pci6 dev 0 function 3 not configured
"Ricoh 5C592 Memory Stick" rev 0x11 at pci6 dev 0 function 4 not configured
"Ricoh 5C852 xD" rev 0x11 at pci6 dev 0 function 5 not configured
cardslot0 at cbb0 slot 0 flags 0
cardbus0 at cardslot0: bus 22 device 0 cacheline 0x10, lattimer 0xb0
pcmcia0 at cardslot0
pcib0 at pci0 dev 31 function 0 "Intel 82801IBM LPC" rev 0x03
ahci0 at pci0 dev 31 function 2 "Intel 82801I AHCI" rev 0x03: msi, AHCI 1.2
scsibus0 at ahci0: 32 targets
sd0 at scsibus0 targ 0 lun 0: <ATA, ST9500420AS, 0003> SCSI3 0/direct fixed
naa.5000c5001c185963
sd0: 476940MB, 512 bytes/sector, 976773168 sectors
cd0 at scsibus0 targ 1 lun 0: <Optiarc, DVD RW AD-7910S, 1.D2> ATAPI 5/cdrom
removable
ichiic0 at pci0 dev 31 function 3 "Intel 82801I SMBus" rev 0x03: apic 1 int 23
iic0 at ichiic0
usb2 at uhci0: USB revision 1.0
uhub2 at usb2 "Intel UHCI root hub" rev 1.00/1.00 addr 1
usb3 at uhci1: USB revision 1.0
uhub3 at usb3 "Intel UHCI root hub" rev 1.00/1.00 addr 1
usb4 at uhci2: USB revision 1.0
uhub4 at usb4 "Intel UHCI root hub" rev 1.00/1.00 addr 1
usb5 at uhci3: USB revision 1.0
uhub5 at usb5 "Intel UHCI root hub" rev 1.00/1.00 addr 1
usb6 at uhci4: USB revision 1.0
uhub6 at usb6 "Intel UHCI root hub" rev 1.00/1.00 addr 1
usb7 at uhci5: USB revision 1.0
uhub7 at usb7 "Intel UHCI root hub" rev 1.00/1.00 addr 1
isa0 at pcib0
isadma0 at isa0
pckbc0 at isa0 port 0x60/5
pckbd0 at pckbc0 (kbd slot)
pckbc0: using irq 1 for kbd slot
wskbd0 at pckbd0: console keyboard, using wsdisplay0
pms0 at pckbc0 (aux slot)
pckbc0: using irq 12 for aux slot
wsmouse0 at pms0 mux 0
pcppi0 at isa0 port 0x61
spkr0 at pcppi0
aps0 at isa0 port 0x1600/31
mtrr: Pentium Pro MTRR support
umass0 at uhub1 port 1 configuration 1 interface 0 "JetFlash Mass Storage
Device" rev 2.00/11.00 addr 2
umass0: using SCSI over Bulk-Only
scsibus1 at umass0: 2 targets, initiator 0
sd1 at scsibus1 targ 1 lun 0: <JetFlash, Transcend 8GB, 1100> SCSI0 0/direct
removable serial.85641000EDKY2VJ3KFO8
sd1: 7728MB, 512 bytes/sector, 15826944 sectors
ugen0 at uhub3 port 2 "Lenovo Computer Corp ThinkPad Bluetooth with Enhanced
Data Rate II" rev 2.00/3.99 addr 2
ugen1 at uhub7 port 2 "Lenovo Integrated Smart Card Reader" rev 2.00/1.00 addr 2
vscsi0 at root
scsibus2 at vscsi0: 256 targets
softraid0 at root
scsibus3 at softraid0: 256 targets
root on sd0a (42a595d9d805c358.a) swap on sd0b dump on sd0b
WARNING: / was not properly unmounted
ugen0 detached
ugen1 detached
ugen0 at uhub3 port 2 "Lenovo Computer Corp ThinkPad Bluetooth with Enhanced
Data Rate II" rev 2.00/3.99 addr 2
ugen1 at uhub7 port 2 "Lenovo Integrated Smart Card Reader" rev 2.00/1.00 addr 2
iwn0: RF switch: radio disabled
iwn0: Radio transmitter is off
ugen0 detached
sd1 detached
scsibus1 detached
umass0 detached
cdce0 at uhub1 port 1 configuration 1 interface 0 "Prolific Technology Inc.
USB-to-USB Bridge 2.0(PL2501)" rev 2.00/80.03 addr 2
cdce0: address 2a:cb:0a:82:de:00
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
upl0 at uhub0 port 1 "Prolific Technology Inc. USB-USB Bridge Cable 2.0" rev
2.00/80.02 addr 2
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
cdce0: watchdog timeout
cdce0: usb error on tx: TIMEOUT
ehci_idone: ex=0xffff80000050a600 is done!
cdce0 detached
ehci_idone: ex=0xffff8000012e9c00 is done!
upl0 detached
ugen1 detached
ugen0 at uhub3 port 2 "Lenovo Computer Corp ThinkPad Bluetooth with Enhanced
Data Rate II" rev 2.00/3.99 addr 2
ugen1 at uhub7 port 2 "Lenovo Integrated Smart Card Reader" rev 2.00/1.00 addr 2
umass0 at uhub1 port 1 configuration 1 interface 0 "JetFlash Mass Storage
Device" rev 2.00/11.00 addr 2
umass0: using SCSI over Bulk-Only
scsibus1 at umass0: 2 targets, initiator 0
sd1 at scsibus1 targ 1 lun 0: <JetFlash, Transcend 8GB, 1100> SCSI0 0/direct
removable serial.85641000EDKY2VJ3KFO8
sd1: 7728MB, 512 bytes/sector, 15826944 sectors
panic: ehci_device_clear_toggle: queue active
Stopped at Debugger+0x5: leave
RUN AT LEAST 'trace' AND 'ps' AND INCLUDE OUTPUT WHEN REPORTING THIS PANIC!
DO NOT EVEN BOTHER REPORTING THIS WITHOUT INCLUDING THAT INFORMATION!
ddb> PID PPID PGRP UID S FLAGS WAIT COMMAND
25906 17285 25906 0 3 0 denode mc
17285 17246 17285 1000 3 0x88 pause ksh
23764 17246 23764 1000 3 0 denode ksh
3856 24305 3856 1000 3 0x80 kqread tmux
12440 13884 12440 1000 3 0 bqwait cp
3538 1 3538 77 3 0x80 poll dhclient
22596 1 22596 0 3 0x80 poll dhclient
9412 26629 32490 1000 3 0x4100080 select remmina
9494 26629 32490 1000 3 0x4100080 select remmina
14687 26629 32490 1000 3 0x4100080 select remmina
2937 26629 32490 1000 3 0x4100080 poll remmina
25814 1 5555 1000 3 0x4100080 poll at-spi2-registry
31220 1 5555 1000 3 0x80 poll at-spi2-registry
16580 1 5555 1000 3 0x4100080 poll at-spi-bus-launc
1019 11400 5555 1000 3 0x80 poll dbus-daemon
19812 1 5555 1000 3 0x4100080 poll at-spi-bus-launc
19532 1 5555 1000 3 0x4100080 poll at-spi-bus-launc
11400 1 5555 1000 3 0x80 poll at-spi-bus-launc
32490 26629 32490 1000 3 0x80 poll remmina
5404 17246 5404 1000 3 0x80 ttyin ksh
14799 1901 1901 1000 3 0x80 select tclsh8.5
1901 26629 1901 1000 3 0x88 pause ksh
21838 26629 21838 1000 3 0x80 poll pidgin
15578 1 15105 1000 3 0x4100080 thrsleep mpd
29052 1 15105 1000 3 0x4100080 thrsleep mpd
5555 1 5555 1000 3 0x80 poll dbus-daemon
8306 1 27562 1000 3 0x80 select dbus-launch
17246 1 17246 1000 3 0x80 kqread tmux
15061 11261 15061 1000 3 0x80 kqread tmux
30230 26357 27142 1000 3 0x4100080 kqread soffice.bin
11261 26629 11261 1000 3 0x80 select xterm
14610 26357 27142 1000 3 0x4100080 netcon soffice.bin
9409 26357 27142 1000 3 0x4100080 thrsleep soffice.bin
32741 26357 27142 1000 3 0x80 poll soffice.bin
10249 26629 27142 1000 3 0x4100080 wait oosplash
12759 26629 27142 1000 3 0x4100080 thrsleep oosplash
32182 1 22694 1000 3 0x80 poll autocutsel
22101 1 29871 1000 3 0x80 poll autocutsel
20207 26629 27142 1000 3 0x80 poll xclock
26357 26629 27142 1000 3 0x80 piperd oosplash
7261 26629 27142 1000 3 0x80 select xbattbar
27794 1 29336 1000 3 0x80 select xbindkeys
10003 26629 27142 1000 3 0x80 select xidle
26629 27142 27142 1000 3 0x80 select cwm
3044 1 3044 1000 3 0x80 select ssh-agent
27142 21324 27142 1000 3 0x88 pause sh
21324 2854 21324 0 3 0x80 wait xdm
29125 7545 7545 0 3 0x80 netio Xorg
32400 1 32400 0 3 0x80 ttyin getty
25410 1 25410 0 3 0x80 ttyin getty
24305 1 24305 1000 3 0x88 pause ksh
15733 1 15733 1000 3 0 biowait ksh
13884 1 13884 1000 3 0x88 pause ksh
7545 2854 7545 35 3 0x80 select Xorg
2854 1 2854 0 3 0x88 pause xdm
26909 1 26909 0 3 0x80 select cron
7265 1 7265 0 3 0x80 htplev hotplugd
31676 1 31676 0 3 0x80 kqread apmd
30488 1 20363 0 3 0x4100080 nanosleep pcscd
16207 1 20363 0 3 0x4100080 nanosleep pcscd
28315 1 20363 0 3 0x80 select pcscd
22300 1 26863 566 3 0x80 kqread tor
16258 1 16258 548 3 0x80 poll polipo
7397 1 2034 1000 3 0x4100080 thrsleep btpd
8777 1 2034 1000 3 0x80 kqread btpd
7782 1 15105 1000 3 0x4100080 thrsleep mpd
15488 1 15105 1000 3 0x4100080 thrsleep mpd
29941 1 15105 1000 3 0x4100080 poll mpd
15105 1 15105 1000 3 0x80 poll mpd
9034 1 9034 99 3 0x80 poll sndiod
17051 1 17051 0 3 0x80 select lpd
5017 1 5017 0 3 0x80 select sshd
15699 4583 4583 100 3 0x80 kqread ldapd
4583 1 4583 0 3 0x80 kqread ldapd
6402 9334 5889 83 3 0x80 poll ntpd
9334 5889 5889 83 3 0x80 poll ntpd
5889 1 5889 0 3 0x80 poll ntpd
18891 31572 31572 74 3 0x80 bpf pflogd
31572 1 31572 0 3 0x80 netio pflogd
25893 2522 2522 73 3 0x80 poll syslogd
2522 1 2522 0 3 0x80 netio syslogd
12176 1 12176 0 3 0x80 mfsidl mount_mfs
15 0 0 0 3 0x100200 aiodoned aiodoned
14 0 0 0 3 0x100200 bqwait update
13 0 0 0 3 0x100200 cleaner cleaner
12 0 0 0 3 0x100200 reaper reaper
11 0 0 0 3 0x100200 pgdaemon pagedaemon
10 0 0 0 3 0x100200 bored crypto
9 0 0 0 3 0x100200 pftm pfpurge
8 0 0 0 3 0x100200 mmctsk sdmmc0
7 0 0 0 3 0x100200 usbtsk usbtask
6 0 0 0 3 0x100200 usbatsk usbatsk
5 0 0 0 3 0x100200 bored intelrel
4 0 0 0 3 0x40100200 acpi0 acpi0
3 0 0 0 2 0x100200 syswq
* 2 0 0 0 7 0x40100200 idle0
1 0 1 0 3 0x80 wait init
0 -1 0 0 3 0x200 scheduler swapper
ddb> Debugger() at Debugger+0x5
panic() at panic+0xe4
ehci_device_clear_toggle() at ehci_device_clear_toggle+0x27
umass_clear_endpoint_stall() at umass_clear_endpoint_stall+0x3e
usb_transfer_complete() at usb_transfer_complete+0x254
ehci_softintr() at ehci_softintr+0x35
softintr_dispatch() at softintr_dispatch+0x5d
Xsoftnet() at Xsoftnet+0x28
--- interrupt ---
end trace frame: 0x0, count: -8
0x8:
ddb> ds 0x292
es 0xdc50 acpi_pdirpa+0x96f0
fs 0xdc40 acpi_pdirpa+0x96e0
gs 0x916a acpi_pdirpa+0x4c0a
rdi 0x1
rsi 0
rbp 0xffff800032c2dc40
rbx 0xffffffff81755190 bwi_led_duration+0x2cf0
rdx 0x5
rcx 0x292
rax 0x1
r8 0xffff800032c2db60
r9 0xffff80002555ec00
r10 0xffffffff
r11 0x1
r12 0x100
r13 0xffff800032c2dc50
r14 0
r15 0
rip 0xffffffff813a3d25 Debugger+0x5
cs 0x8
rflags 0x202
rsp 0xffff800032c2dc40
ss 0x10
Debugger+0x5: leave
ddb> ehci0: reset timeout
ehci1: reset timeout
rebooting...
'usbdevs -vvv' output:
Controller /dev/usb0:
addr 1: high speed, self powered, config 1, EHCI root hub(0x0000),
Intel(0x8086), rev 1.00
port 1 powered
port 2 powered
port 3 powered
port 4 powered
port 5 powered
port 6 powered
Controller /dev/usb1:
addr 1: high speed, self powered, config 1, EHCI root hub(0x0000),
Intel(0x8086), rev 1.00
port 1 powered
port 2 addr 2: high speed, power 500 mA, config 1, Mass Storage
Device(0x1000), JetFlash(0x8564), rev 11.00, iSerialNumber 48P6EDKY2VJ3KFO8
port 3 powered
port 4 powered
port 5 powered
port 6 powered
Controller /dev/usb2:
addr 1: full speed, self powered, config 1, UHCI root hub(0x0000),
Intel(0x8086), rev 1.00
port 1 powered
port 2 powered
Controller /dev/usb3:
addr 1: full speed, self powered, config 1, UHCI root hub(0x0000),
Intel(0x8086), rev 1.00
port 1 powered
port 2 addr 2: full speed, self powered, config 1, ThinkPad Bluetooth with
Enhanced Data Rate II(0x2145), Lenovo Computer Corp(0x0a5c), rev 3.99
Controller /dev/usb4:
addr 1: full speed, self powered, config 1, UHCI root hub(0x0000),
Intel(0x8086), rev 1.00
port 1 powered
port 2 powered
Controller /dev/usb5:
addr 1: full speed, self powered, config 1, UHCI root hub(0x0000),
Intel(0x8086), rev 1.00
port 1 powered
port 2 powered
Controller /dev/usb6:
addr 1: full speed, self powered, config 1, UHCI root hub(0x0000),
Intel(0x8086), rev 1.00
port 1 powered
port 2 powered
Controller /dev/usb7:
addr 1: full speed, self powered, config 1, UHCI root hub(0x0000),
Intel(0x8086), rev 1.00
port 1 powered
port 2 addr 2: full speed, power 100 mA, config 1, Integrated Smart Card
Reader(0x1003), Lenovo(0x17ef), rev 1.00
--
sergeyb@