# USB2 freezes entire computer!

## don quixada

Hi, I just got a new motherboard (AMD A7V8X-X) with USB2 built-in (VT8235) and also a new processor (Athlon-XP +2400). Along with this splurge I got a portable USB1/2 hard-drive housing (by NSpire series NSP-340). But I've been having problems with my computer freezing when I copy large amounts of data over USB2. It freezes almost randomly during the transfer, i.e. I cannot predict when it will happen.

My kernel (2.4.20-gentoo-r9) has EHCI built-in and UHCI (Intel PIIX4, Via ...) as a module (otherwise my USB mouse won't work). I also have USB mass-storage as module, USB full HID built-in (including both sub-options /dev/hidev and HID input layer), and Preliminary USB device filesystem built-in.

Does any one have any suggestions so that my computer won't freeze? Can I slow down the data transfer rate a bit (as long as it's not as slow as USB1 of course)? Does anyone know what the problem is? Is the 2.6.x kernel any better?

I hope there is a solution out there, thanks.

dq

----------

## oumpah-pah

Do you see any error messages in the output of dmesg ? And did you enable CONFIG_USB_BANDWIDTH in your kernel (I'm not sure if 2.4 kernels have it) ?

----------

## don quixada

I built the CONFIG_USB_BANDWIDTH into my kernel (yes, 2.4 has it) and my computer still freezes during USB2 transfer. Here's some stuff from dmesg

```

# dmesg | grep usb

usb.c: hub driver claimed interface c24debc0

usb.c: kusbd: /sbin/hotplug add 1

usb.c: kusbd policy returned 0xfffffffe

usb.c: registered new driver hiddev

usb.c: registered new driver hid

usb-uhci.c: $Revision: 1.275 $ time 19:32:26 Jul 29 2004

usb-uhci.c: High bandwidth mode enabled

usb-uhci.c: USB UHCI at I/O 0xb800, IRQ 11

usb-uhci.c: Detected 2 ports

usb.c: new USB bus registered, assigned bus number 2

usb.c: kmalloc IF df982680, numif 1

usb.c: new device strings: Mfr=0, Product=2, SerialNumber=1

usb.c: USB device number 1 default language ID 0x0

usb.c: hub driver claimed interface df982680

usb.c: kusbd: /sbin/hotplug add 1

usb.c: kusbd policy returned 0xfffffffe

usb-uhci.c: USB UHCI at I/O 0xb400, IRQ 11

usb-uhci.c: Detected 2 ports

usb.c: new USB bus registered, assigned bus number 3

usb.c: kmalloc IF df982480, numif 1

usb.c: new device strings: Mfr=0, Product=2, SerialNumber=1

usb.c: USB device number 1 default language ID 0x0

usb.c: hub driver claimed interface df982480

usb.c: kusbd: /sbin/hotplug add 1

usb.c: kusbd policy returned 0xfffffffe

usb-uhci.c: USB UHCI at I/O 0xb000, IRQ 11

usb-uhci.c: Detected 2 ports

usb.c: new USB bus registered, assigned bus number 4

usb.c: kmalloc IF df982280, numif 1

usb.c: new device strings: Mfr=0, Product=2, SerialNumber=1

usb.c: USB device number 1 default language ID 0x0

usb.c: hub driver claimed interface df982280

usb.c: kusbd: /sbin/hotplug add 1

usb.c: kusbd policy returned 0xfffffffe

usb-uhci.c: v1.275:USB Universal Host Controller Interface driver

usb.c: registered new driver usb-storage

usb.c: kmalloc IF df0baf80, numif 1

usb.c: skipped 1 class/vendor specific interface descriptors

usb.c: new device strings: Mfr=1, Product=2, SerialNumber=0

usb.c: USB device number 2 default language ID 0x409

usb-uhci.c: interrupt, status 3, frame# 1453

input0: USB HID v1.00 Mouse [Microsoft Microsoft Wheel Mouse Opticalï¿½] on usb2:2.0

usb.c: hid driver claimed interface df0baf80

usb.c: kusbd: /sbin/hotplug add 2

usb.c: kusbd policy returned 0xfffffffe

usb.c: kmalloc IF de1666c0, numif 1

usb.c: new device strings: Mfr=56, Product=78, SerialNumber=100

usb.c: USB device number 2 default language ID 0x409

usb.c: usb-storage driver claimed interface de1666c0

usb.c: kusbd: /sbin/hotplug add 2

usb.c: kusbd policy returned 0xfffffffe

```

My entire dmesg output is huge. I'll post a chunk that seems relvant. I think this happened when I flipped on the usb drive after booting into Linux.

```

hcd/ehci-hub.c: GetStatus port 1 status 0x1803 POWER speed=2 CSC CONNECT

hub.c: port 1, portstatus 501, change 1, 480 Mb/s

hub.c: port 1 connection change

hub.c: port 1, portstatus 501, change 1, 480 Mb/s

hub.c: port 1, portstatus 501, change 0, 480 Mb/s

hub.c: port 1, portstatus 501, change 0, 480 Mb/s

hub.c: port 1, portstatus 501, change 0, 480 Mb/s

hub.c: port 1, portstatus 501, change 0, 480 Mb/s

hub.c: port 1, portstatus 511, change 0, 480 Mb/s

hub.c: port 1 of hub 1 not reset yet, waiting 10ms

hub.c: port 1, portstatus 511, change 0, 480 Mb/s

hub.c: port 1 of hub 1 not reset yet, waiting 10ms

hub.c: port 1, portstatus 511, change 0, 480 Mb/s

hub.c: port 1 of hub 1 not reset yet, waiting 200ms

hcd/ehci-hub.c: 00:10.3 port 1 high speed

hcd/ehci-hub.c: GetStatus port 1 status 0x1005 POWER speed=0 PE CONNECT

hub.c: port 1, portstatus 503, change 10, 480 Mb/s

hub.c: new USB device 00:10.3-1, assigned address 2

usb.c: kmalloc IF de1666c0, numif 1

usb.c: new device strings: Mfr=56, Product=78, SerialNumber=100

usb.c: USB device number 2 default language ID 0x409

Manufacturer: Cypress Semiconductor

Product: USB2.0 Storage Device

SerialNumber: DEF10796F708

hcd/ehci-q.c: ep 0-in qtd token 80040d40 --> status -32

hcd.c: giveback urb d39ce2c0 status -32 len 0

hcd/ehci-q.c: ep 0-out qtd token 80008d40 --> status -32

hcd.c: giveback urb d39ce2c0 status -32 len 0

scsi1 : SCSI emulation for USB Mass Storage devices

hcd/ehci-q.c: ep 8-in qtd token 800d8d40 --> status -32

hcd.c: giveback urb de1638c0 status -32 len 0

  Vendor: Maxtor 5  Model: T020H2            Rev:  0 0

  Type:   Direct-Access                      ANSI SCSI revision: 02

Attached scsi disk sda at scsi1, channel 0, id 0, lun 0

SCSI device sda: 40021632 512-byte hdwr sectors (20491 MB)

 /dev/scsi/host1/bus0/target0/lun0: p1 p2

WARNING: USB Mass Storage data integrity not assured

USB Mass Storage device found at 2

usb.c: usb-storage driver claimed interface de1666c0

usb.c: kusbd: /sbin/hotplug add 2

usb.c: kusbd policy returned 0xfffffffe

hcd/ehci-hub.c: GetStatus port 2 status 0x3402 OWNER POWER speed=1 CSC

hub.c: port 2, portstatus 0, change 1, 12 Mb/s

hub.c: port 2 connection change

hub.c: port 2, portstatus 0, change 1, 12 Mb/s

hub.c: port 3, portstatus 100, change 0, 12 Mb/s

hub.c: port 4, portstatus 100, change 0, 12 Mb/s

hub.c: port 5, portstatus 100, change 0, 12 Mb/s

hub.c: port 6, portstatus 100, change 0, 12 Mb/s

```

Also, it may be worth noting that after a crash, if I leave the drive turned on while booting, the computer hangs during the boot. Thanks for your help.

dq

----------

## oumpah-pah

As you can see, your device is connected at 12 Mb/s, which means USB 1.1. USB 2.0 would be 480 Mb/s. I'm sure that it can make your computer freeze when you copy a huge amount of data, because the connection is far too slow. But I've no idea about why it uses USB 1.1 instead of 2.0.

----------

## don quixada

Maybe it UHCI is conflicting with EHCI? I would disable UHCI, but then I wouldn't be able to use my mouse. Is there a way to get the mouse working with UHCI? Also, there's an UHCI alternate, maybe I should use that? Thanks for your help so far...

dq

----------

## oumpah-pah

You're right, you should try to disable UHCI in your kernel and use OHCI instead. Maybe it will work.

----------

## racoontje

Doesn't EHCI also support legacy USB1.1 devices?

AFAIK, I don't have OHCI/UHCI support in my kernel, but I do have an USB mouse.

----------

## oumpah-pah

That's true if your USB ports are all USB 2.0 compliant.

----------

## don quixada

Ok, I built every xHCI driver as a module and tried it out including having *only* the EHCI one (built-in-- not a module). And nothing worked! I still got the freeze, and my mouse didn't work very well, i.e. the scroll button only seems to work when I have the [*]EHCI/<M>UHCI combo with '/dev/mouse' in my XF86config. 

In 'dmesg' I still had the 480 -> 12 Mb/s even with only EHCI built.

My system currently only has usb2 ports (it has four-- and I think I have capability for two more).

Also, I came across a post saying that OHCI and EHCI conflict, just FYI...

Anyway, do you have any more ideas? Are other people having this problem too?

Thanks,

dq

----------

## shezi

Read this:

https://forums.gentoo.org/viewtopic.php?t=204342&highlight=usb+disk+hangs

and this:

https://forums.gentoo.org/viewtopic.php?t=218170&highlight=usb+disk+hangs

----------

