Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 5 Nov 2006 21:31:06 GMT
From:      "O. Hartmann"<ohartman@zedat.fu-berlin.de>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   usb/105186: USB 2.0/ehci on FreeBSD 6.2-PRE/AMD64 crashes box
Message-ID:  <200611052131.kA5LV6CI010329@www.freebsd.org>
Resent-Message-ID: <200611052140.kA5LeQmH025653@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         105186
>Category:       usb
>Synopsis:       USB 2.0/ehci on FreeBSD 6.2-PRE/AMD64 crashes box
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    freebsd-usb
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Nov 05 21:40:26 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     O. Hartmann
>Release:        FreeBSD 6.2-PRE/AMD64
>Organization:
Freie Universität Berlin
>Environment:
FreeBSD foo.org 6.2-PRERELEASE FreeBSD 6.2-PRERELEASE #8: Sat Nov  4 11:23:20 UTC 2006     root@foo.org:/usr/obj/usr/src/sys/FOO  amd64

>Description:
FreeBSD 6.2-PRE/AMD64 crashes after first access of USB 2.0 devices, like external disk attached via USB or USB stick.

The crash occurs very rapidly after a fresh start of the box and accessing a backup drive (see appropriate dmesg output) writing data. Also accessing a USB stick very often results in a crash of the box!

One can alos trigger a crash by accessing the USB 2.0 device while box is under heavy load.

Doesn't matter whether SCHED_ULE or SCHED_4BSD is used.

Kernel uses ehci for performance reasons. 

Crashes occur in most cases on our AMD64 based boxes, the i386 based 32 Bit boxes with same OS version seem to be more robust.

As USB is widely used and many colleagues use USB sticks and USB backup/exchange external drives, usability and stability of USB becomes important.

dmesg part of USB device controller:

usb0: OHCI version 1.0, legacy support
usb0: <OHCI (generic) USB controller> on ohci0
usb0: USB revision 1.0
uhub0: nVidia OHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 10 ports with 10 removable, self powered
ehci0: <NVIDIA nForce4 USB 2.0 controller> mem 0xdcdfbc00-0xdcdfbcff irq 22 at device 11.1 on pci0
ehci0: [GIANT-LOCKED]
usb1: EHCI version 1.0
usb1: companion controller, 4 ports each: usb0
usb1: <NVIDIA nForce4 USB 2.0 controller> on ehci0
usb1: USB revision 2.0
uhub1: nVidia EHCI root hub, class 9/0, rev 2.00/1.00, addr 1
uhub1: 10 ports with 10 removable, self powered
umass0: Macpower &Tytech Tech USB2.0 Enclosure, rev 2.00/1.00, addr 2

dmesg part of USB 2.0 external HD:

da0 at umass-sim0 bus 0 target 0 lun 0
da0: <SAMSUNG S07GJ10Y304470 VM10> Fixed Direct Access SCSI-2 device 
da0: 40.000MB/s transfers
da0: 190782MB (390721968 512 byte sectors: 255H 63S/T 24321C)


dmesg USB stick:

umass1: vendor 0x0457 USB Mass Storage Device, rev 2.00/1.00, addr 3
da1 at umass-sim1 bus 1 target 0 lun 0
da1: <TinyDisk 2006-09-11 0.00> Removable Direct Access SCSI-2 device 
da1: 40.000MB/s transfers
da1: 1000MB (2048000 512 byte sectors: 64H 32S/T 1000C)
GEOM_LABEL: Label for provider da1 is msdosfs/STICK01.

>How-To-Repeat:
Attach USB 2.0 device to AMD64 box and do a lot of I/O ...
>Fix:
Nothing known. Switching back to USB 1.0/1.1 via ohci isn't a solution due to the worse performance.

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200611052131.kA5LV6CI010329>