I meet a problem in my usb system.
We designed a complicated usb device system. On this
board, we have total 6 hubs,and 16 usb devices. The
usb devcies  are all USB 1.1 full speed devices. The
hub's upstream ports are 2.0 high speed. All these 16
devices are video compressor.

This board will connect to a Common Intel P4 PC
through an usb cable. PC has host controller and root
hub.
I designed the driver for these 16 video devices.
My problem, if I quit my application, stop my driver,
call my driver's release() function, then unplug the
usb cable, all the hubs and devices on my board can be
disconnected successfully by USB kernel. However if my
usb device is working, streaming video out to my host
PC by usb connection, I unplugged the usb cable which
means all hubs and devices on this board are gone(I
know this is rude), USB kernel try to disconnect all
the hubs and devices on my board, but somehow it hangs
there, and never go further.
I did some investigate:
The hang happened inside  ehci-hcd.c's
 Ehci_endpoint_disable()
The qh->state is always QH_STATE_UNLINK, the program
trapped into the endless loop

++++++++++++++++++++++++++++++++++++++++++++++++++

      case QH_STATE_UNLINK:         /* wait for hw to
finish? */

idle_timeout:

            spin_unlock_irqrestore (&ehci->lock,
flags);

            set_current_state (TASK_UNINTERRUPTIBLE);

            schedule_timeout (1);

            goto rescan;

++++++++++++++++++++++++++++++++++++++++++++++++

 

The end point which kernel go to disable are BULK
audio or BULK video.

I really do not know why the unlink procedures did not
finished or did not made it and change the qh->state
back to idle.

Any suggestion?

 

My kernel version is 2.6.10.

Eric Li 

 




-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
[email protected]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-users

Reply via email to