linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* PATCH: usb-uhci: interrupt out with urb->interval 0
@ 2003-04-17  8:31 Frode Isaksen
  2003-04-18  7:05 ` Greg KH
  0 siblings, 1 reply; 6+ messages in thread
From: Frode Isaksen @ 2003-04-17  8:31 UTC (permalink / raw)
  To: greg; +Cc: linux-kernel, weissg

A recent change (2.4.21) in the usb-uhci driver calls 
"uhci_clean_iso_step2" after the completion of one-shot (urb->interval 
0) interrupt out transfers. This call clears the list of descriptors. 
However, it crashes when trying to get the next desciptor in the "for" 
loop in the "process_interrupt" function, since the list of descriptors 
are already cleared. A simple change I did was to do a "break" to quit 
the "for" loop for interrupt out transfers with urb->interval 0.

Thanks,
Frode

--- drivers/usb/usb-uhci.c.orig	2003-04-16 15:39:04.000000000 +0200
+++ drivers/usb/usb-uhci.c	2003-04-16 15:39:56.000000000 +0200
@@ -2628,6 +2628,7 @@
  				// correct toggle after unlink
  				usb_dotoggle (urb->dev, usb_pipeendpoint (urb->pipe), usb_pipeout 
(urb->pipe));
  				clr_td_ioc(desc); // inactivate TD
+				break;
  			}
  		}
  	}


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: PATCH: usb-uhci: interrupt out with urb->interval 0
  2003-04-17  8:31 PATCH: usb-uhci: interrupt out with urb->interval 0 Frode Isaksen
@ 2003-04-18  7:05 ` Greg KH
  0 siblings, 0 replies; 6+ messages in thread
From: Greg KH @ 2003-04-18  7:05 UTC (permalink / raw)
  To: Frode Isaksen; +Cc: linux-kernel, weissg

On Thu, Apr 17, 2003 at 10:31:18AM +0200, Frode Isaksen wrote:
> A recent change (2.4.21)

Um, 2.4.21 is not out yet :)

> in the usb-uhci driver calls 
> "uhci_clean_iso_step2" after the completion of one-shot (urb->interval 
> 0) interrupt out transfers. This call clears the list of descriptors. 
> However, it crashes when trying to get the next desciptor in the "for" 
> loop in the "process_interrupt" function, since the list of descriptors 
> are already cleared. A simple change I did was to do a "break" to quit 
> the "for" loop for interrupt out transfers with urb->interval 0.

Hm, I thought someone tested this previously.  Do you have a test case
for this that I can try to duplicate the problem for?

Also, your patch will not apply against the latest (2.4.21-pre7) version
of this file.

thanks,

greg k-h

p.s. I'd recommend sending these kinds of patches to the linux-usb-devel
mailing list too.  That's where most of the Linux USB developers are.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: PATCH: usb-uhci: interrupt out with urb->interval 0
  2003-04-20  8:08 David Glance
@ 2003-04-20 13:32 ` David Glance
  0 siblings, 0 replies; 6+ messages in thread
From: David Glance @ 2003-04-20 13:32 UTC (permalink / raw)
  To: linux-kernel; +Cc: fisaksen, Greg KH

The timeout problem is solved (I increased the timeout on my side) - so 
just to confirm that the patch is still required though.

David Glance wrote:

> I am not subscribed to this list - please include me on the 'cc' line.
>
> Version: 2.4.21-pre6
> Subsystem: USB
> Driver: Lego USB Tower
>
> Writing one-short interrupt out transfers without this patch cause the 
> system to hang. Applying this patch fixes that (thankfully after 
> fsck'ing my disk a dozen times!) - however the driver (which works 
> still using usb-ohci on an ohci card) - doesn't work because the reads 
> are  failing - returning a ETIMEDOUT.
>
> I am assuming that the changes made (see below) - somehow have 
> affected other aspects of one-shot interrupt in transfers?
>
> Thanks
>
> David
>
>
> Frode wrote:
>
> A recent change (2.4.21) in the usb-uhci driver calls
> "uhci_clean_iso_step2" after the completion of one-shot (urb->interval
> 0) interrupt out transfers. This call clears the list of descriptors.
> However, it crashes when trying to get the next desciptor in the "for"
> loop in the "process_interrupt" function, since the list of descriptors
> are already cleared. A simple change I did was to do a "break" to quit
> the "for" loop for interrupt out transfers with urb->interval 0.
>
> Thanks,
> Frode
>
> --- drivers/usb/usb-uhci.c.orig 2003-04-16 15:39:04.000000000 +0200
> +++ drivers/usb/usb-uhci.c 2003-04-16 15:39:56.000000000 +0200
> @@ -2628,6 +2628,7 @@
>                                   // correct toggle after unlink
>                                   usb_dotoggle (urb->dev, 
> usb_pipeendpoint (urb->pipe), usb_pipeout
> (urb->pipe));
>                                   clr_td_ioc(desc); // inactivate TD
> + break;
>                           }
>                   }
>           }
>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: PATCH: usb-uhci: interrupt out with urb->interval 0
@ 2003-04-20  8:08 David Glance
  2003-04-20 13:32 ` David Glance
  0 siblings, 1 reply; 6+ messages in thread
From: David Glance @ 2003-04-20  8:08 UTC (permalink / raw)
  To: linux-kernel; +Cc: fisaksen, Greg KH

I am not subscribed to this list - please include me on the 
'cc' line.

Version: 2.4.21-pre6
Subsystem: USB
Driver: Lego USB Tower

Writing one-short interrupt out transfers without this patch 
cause the system to hang. Applying this patch fixes that 
(thankfully after fsck'ing my disk a dozen times!) - however 
the driver (which works still using usb-ohci on an ohci 
card) - doesn't work because the reads are  failing - 
returning a ETIMEDOUT.

I am assuming that the changes made (see below) - somehow 
have affected other aspects of one-shot interrupt in transfers?

Thanks

David


Frode wrote:

A recent change (2.4.21) in the usb-uhci driver calls
"uhci_clean_iso_step2" after the completion of one-shot 
(urb->interval
0) interrupt out transfers. This call clears the list of 
descriptors.
However, it crashes when trying to get the next desciptor in 
the "for"
loop in the "process_interrupt" function, since the list of 
descriptors
are already cleared. A simple change I did was to do a 
"break" to quit
the "for" loop for interrupt out transfers with urb->interval 0.

Thanks,
Frode

--- drivers/usb/usb-uhci.c.orig 2003-04-16 
15:39:04.000000000 +0200
+++ drivers/usb/usb-uhci.c 2003-04-16 15:39:56.000000000 +0200
@@ -2628,6 +2628,7 @@
                                   // correct toggle after 
unlink
                                   usb_dotoggle (urb->dev, 
usb_pipeendpoint (urb->pipe), usb_pipeout
(urb->pipe));
                                   clr_td_ioc(desc); // 
inactivate TD
+ break;
                           }
                   }
           }


^ permalink raw reply	[flat|nested] 6+ messages in thread

* PATCH: usb-uhci: interrupt out with urb->interval 0
@ 2003-04-17  7:20 Frode Isaksen
  0 siblings, 0 replies; 6+ messages in thread
From: Frode Isaksen @ 2003-04-17  7:20 UTC (permalink / raw)
  To: usb; +Cc: linux-kernel

A recent change (2.4.21) in the usb-uhci driver calls 
"uhci_clean_iso_step2" after the completion of one-shot (urb->interval 
0) interrupt out transfers. This call clears the list of descriptors. 
However, it crashes when trying to get the next desciptor in the "for" 
loop in the "process_interrupt" function, since the list of descriptors 
are already cleared. A simple change I did was to do a "break" to quit 
the "for" loop for interrupt out transfers with urb->interval 0.

Thanks,
Frode


--- drivers/usb/usb-uhci.c.orig	2003-04-16 15:39:04.000000000 +0200
+++ drivers/usb/usb-uhci.c	2003-04-16 15:39:56.000000000 +0200
@@ -2628,6 +2628,7 @@
  				// correct toggle after unlink
  				usb_dotoggle (urb->dev, usb_pipeendpoint (urb->pipe), usb_pipeout 
(urb->pipe));
  				clr_td_ioc(desc); // inactivate TD
+				break;
  			}
  		}
  	}


^ permalink raw reply	[flat|nested] 6+ messages in thread

* PATCH: usb-uhci: interrupt out with urb->interval 0
@ 2003-04-16 15:44 Frode Isaksen
  0 siblings, 0 replies; 6+ messages in thread
From: Frode Isaksen @ 2003-04-16 15:44 UTC (permalink / raw)
  To: usb; +Cc: linux-kernel

A recent change (2.4.21) in the usb-uhci driver calls 
"uhci_clean_iso_step2" after the completion of one-shot (urb->interval 
0) interrupt out transfers. This call clears the list of descriptors. 
However, it crashes when trying to get the next desciptor in the "for" 
loop in the "process_interrupt" function, since the list of descriptors 
are already cleared. A simple change I did was to do a "break" to quit 
the "for" loop for interrupt out transfers with urb->interval 0.

Thanks,
Frode


--- drivers/usb/usb-uhci.c.orig	2003-04-16 15:39:04.000000000 +0200
+++ drivers/usb/usb-uhci.c	2003-04-16 15:39:56.000000000 +0200
@@ -2628,6 +2628,7 @@
  				// correct toggle after unlink
  				usb_dotoggle (urb->dev, usb_pipeendpoint (urb->pipe), usb_pipeout 
(urb->pipe));
  				clr_td_ioc(desc); // inactivate TD
+				break;
  			}
  		}
  	}


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2003-04-20 13:18 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-04-17  8:31 PATCH: usb-uhci: interrupt out with urb->interval 0 Frode Isaksen
2003-04-18  7:05 ` Greg KH
  -- strict thread matches above, loose matches on Subject: below --
2003-04-20  8:08 David Glance
2003-04-20 13:32 ` David Glance
2003-04-17  7:20 Frode Isaksen
2003-04-16 15:44 Frode Isaksen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).