David: The following patch addresses the problem the Paul raised, concerning whether the root hub status irq timer should be allowed to run during a suspend.
I'm not sure that this does exactly what you would like. My reasoning is that the timer should run as long as the URB is linked. Just as with non-root hubs, if you want the periodic interrogations to stop during a suspend then the URB should be unlinked. So I moved the check for whether the HC is running to the place where the timer is first started when the URB is submitted, instead of checking whenever the timer expires. Alan Stern # This is a BitKeeper generated patch for the following project: # Project Name: greg k-h's linux 2.5 USB kernel tree # This patch format is intended for GNU patch command version 2.5 or higher. # This patch includes the following deltas: # ChangeSet 1.1648 -> 1.1649 # drivers/usb/core/hcd.c 1.104 -> 1.105 # # The following is the BitKeeper ChangeSet Log # -------------------------------------------- # 03/06/09 [EMAIL PROTECTED] 1.1649 # Allow the root hub status timer to run during PM suspend. # -------------------------------------------- # diff -Nru a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c --- a/drivers/usb/core/hcd.c Mon Jun 9 12:17:23 2003 +++ b/drivers/usb/core/hcd.c Mon Jun 9 12:17:23 2003 @@ -459,7 +459,8 @@ /* rh_timer protected by hcd_data_lock */ if (hcd->rh_timer.data || urb->status != -EINPROGRESS - || urb->transfer_buffer_length < len) { + || urb->transfer_buffer_length < len + || !HCD_IS_RUNNING (hcd->state)) { dev_dbg (hcd->controller, "not queuing rh status urb, stat %d\n", urb->status); @@ -489,11 +490,10 @@ local_irq_save (flags); spin_lock (&urb->lock); - /* do nothing if the hc is gone or the urb's been unlinked */ + /* do nothing if the urb's been unlinked */ if (!urb->dev || urb->status != -EINPROGRESS - || (hcd = urb->dev->bus->hcpriv) == 0 - || !HCD_IS_RUNNING (hcd->state)) { + || (hcd = urb->dev->bus->hcpriv) == 0) { spin_unlock (&urb->lock); local_irq_restore (flags); return; ------------------------------------------------------- This SF.net email is sponsored by: Etnus, makers of TotalView, The best thread debugger on the planet. Designed with thread debugging features you've never dreamed of, try TotalView 6 free at www.etnus.com. _______________________________________________ [EMAIL PROTECTED] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel