NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: kern/48270: umass / ehci effectively hangs system during stresstest



The following reply was made to PR kern/48270; it has been noted by GNATS.

From: Nick Hudson <skrll%netbsd.org@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: m.ramakers%gmail.com@localhost, kern-bug-people%netbsd.org@localhost, 
 gnats-admin%netbsd.org@localhost, netbsd-bugs%netbsd.org@localhost
Subject: Re: kern/48270: umass / ehci effectively hangs system during stresstest
Date: Wed, 16 Oct 2013 08:25:45 +0100

 This is a multi-part message in MIME format.
 --------------000506050201040900010809
 Content-Type: text/plain; charset=ISO-8859-1; format=flowed
 Content-Transfer-Encoding: 7bit
 
 On 10/04/13 06:55, m.ramakers%gmail.com@localhost wrote:
 
 >> Number:         48270
 >> Synopsis:       umass / ehci effectively hangs system during stresstest
 >>
 
 Hi,
 
 Can you see if the attached patch helps it recover, please?
 
 Why it needs to recover is another matter.
 
 Nick
 
 --------------000506050201040900010809
 Content-Type: text/plain; charset=us-ascii;
  name="usbdi.c.diff"
 Content-Transfer-Encoding: 7bit
 Content-Disposition: attachment;
  filename="usbdi.c.diff"
 
 Index: sys/dev/usb/usbdi.c
 ===================================================================
 RCS file: /cvsroot/src/sys/dev/usb/usbdi.c,v
 retrieving revision 1.159
 diff -u -p -r1.159 usbdi.c
 --- sys/dev/usb/usbdi.c        4 Oct 2013 12:47:04 -0000       1.159
 +++ sys/dev/usb/usbdi.c        16 Oct 2013 07:22:10 -0000
 @@ -296,10 +296,16 @@ usbd_transfer(usbd_xfer_handle xfer)
        if (!(flags & USBD_NO_COPY) && size != 0 && !usbd_xfer_isread(xfer))
                memcpy(KERNADDR(dmap, 0), xfer->buffer, size);
  
 -      /* xfer is not valid after the transfer method unless synchronous */
 +      /*
 +       * xfer is not valid after the transfer method unless synchronous, or
 +       * there was and error
 +       */
        err = pipe->methods->transfer(xfer);
  
        if (err != USBD_IN_PROGRESS && err) {
 +              pipe->running = 0;
 +              SIMPLEQ_REMOVE_HEAD(&pipe->queue, next);
 +
                /* The transfer has not been queued, so free buffer. */
                if (xfer->rqflags & URQ_AUTO_DMABUF) {
                        struct usbd_bus *bus = pipe->device->bus;
 
 
 --------------000506050201040900010809--
 


Home | Main Index | Thread Index | Old Index