Hi,
I love poisoning ;-) This patch fixes another two oops-possibilities for
isochronous transfers.

Please apply additionally to my last patch.
-- 
         Georg Acher, [EMAIL PROTECTED]         
         http://www.in.tum.de/~acher/
          "Oh no, not again !" The bowl of petunias          
diff -u linux/drivers/usb/usb-uhci.c linux.afs/drivers/usb/usb-uhci.c
--- linux/drivers/usb/usb-uhci.c        Sat May 13 17:19:03 2000
+++ linux.afs/drivers/usb/usb-uhci.c    Sat May 13 17:34:17 2000
@@ -12,7 +12,7 @@
  * (C) Copyright 1999 Johannes Erdfelt
  * (C) Copyright 1999 Randy Dunlap
  *
- * $Id: usb-uhci.c,v 1.230 2000/05/13 12:50:29 acher Exp $
+ * $Id: usb-uhci.c,v 1.231 2000/05/13 15:34:17 acher Exp $
  */
 
 #include <linux/config.h>
@@ -48,7 +48,7 @@
 /* This enables an extra UHCI slab for memory debugging */
 #define DEBUG_SLAB
 
-#define VERSTR "$Revision: 1.230 $ time " __TIME__ " " __DATE__
+#define VERSTR "$Revision: 1.231 $ time " __TIME__ " " __DATE__
 
 #include <linux/usb.h>
 #include "usb-uhci.h"
@@ -1142,6 +1142,12 @@
 
                        if (!(urb->transfer_flags & USB_TIMEOUT_KILLED))
                                urb->status = -ENOENT;  // now the urb is really dead
+                       switch (usb_pipetype (pipe)) {
+                       case PIPE_ISOCHRONOUS:
+                       case PIPE_INTERRUPT:
+                               uhci_clean_iso_step2(s, urb_priv);
+                               break;
+                       }
        
                        usb_dec_dev_use (dev);
 #ifdef DEBUG_SLAB
@@ -1149,12 +1155,7 @@
 #else
                        kfree (urb_priv);
 #endif
-                       switch (usb_pipetype (pipe)) {
-                       case PIPE_ISOCHRONOUS:
-                       case PIPE_INTERRUPT:
-                               uhci_clean_iso_step2(s, urb_priv);
-                               break;
-                       }
+
                        list_del (&urb->urb_list);
                }
        }
@@ -2344,7 +2345,7 @@
        dbg("process iso urb %p, %li, %i, %i, %i 
%08x",urb,jiffies,UHCI_GET_CURRENT_FRAME(s),
            urb->number_of_packets,mode,desc->hw.td.status);
 
-       for (i = 0; p != &urb_priv->desc_list; p = p->next, i++) {
+       for (i = 0; p != &urb_priv->desc_list;  i++) {
                desc = list_entry (p, uhci_desc_t, desc_list);
                
                //uhci_show_td(desc);
@@ -2388,8 +2389,9 @@
                dbg("process_iso: %i: len:%d %08x status:%x",
                     i, urb->iso_frame_desc[i].actual_length, 
desc->hw.td.status,urb->iso_frame_desc[i].status);
 
-               delete_desc (desc);
                list_del (p);
+               p = p->next;
+               delete_desc (desc);
        }
        
        dbg("process_iso: exit %i (%d), actual_len %i", i, ret,urb->actual_length);

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to