Re: Unable to reap urb after receiving signal using usbfs.

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

 



Dave Mielke wrote:
> [quoted lines by Peter Stuge on 2015/02/11 at 15:57 +0100]
> 
> >I would expect ioctl(fd, IOCTL_USBFS_REAPURBNDELAY, &urb) to either
> >return -1 with errno = ENODEV, or to return 0 with urb->status = ESHUTDOWN.
> 
> I just reverified. It's definitely returning -1 with EAGAIN.

That seems like a kernel bug to me.


> >What happens if you ioctl(fd, IOCTL_USBFS_DISCARDURB, ) instead of REAP?
> 
> If I give it the address of the urb I'm expecting, it returns 0,

That's good. So the code path for discarding the URB has no bug.

> and then the non-blocking reap changes to returning -1 with ENOENT.

..which also makes sense, because the urb was just discarded.


But I don't believe you should have to discard the URB when the
device disappears.


//Peter
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux