Re: How should we handle isochronous underruns?

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

 



On Thu, Jul 18, 2013 at 3:24 AM, Alan Stern <stern@xxxxxxxxxxxxxxxxxxx> wrote:
> On Thu, 4 Jul 2013, Alan Stern wrote:
>
>> On Thu, 4 Jul 2013, Ming Lei wrote:
>>
>> > >> If so, your coming change may break ABI because as you described
>> > >> that "the flag should be set in the first URB of a new stream", but
>> > >> some user-space drivers may not set it before. Even USB audio driver
>> > >> doesn't set it in current -next tree.
>
> I had some more ideas about this.  Instead of requiring drivers to set
> URB_ISO_ASAP on just the first URB of an isochronous stream, we could
> ask drivers to call usb_reset_endpoint() between streams.  This would
> tell the HCD that the next URB marks the start of a new stream, with no
> need for a special flag.

This idea still requires changes from old drivers.

Also it might be not appropriate to call usb_reset_endpoint() in this case
because other host controller's implementation may do other unnecessary
thing for this situation.

>
> Another possibility, which would be even simpler, is for HCDs to assume
> that if the endpoint's queue has been empty for more than 100 ms then a
> new stream is starting.  Then drivers wouldn't have to do anything
> special at all.  (Unless they are stopping and restarting streams very
> rapidly, in which case something like usb_reset_endpoint() would be

In this case, we may use changing altsetting to decide start of streaming.

> necessary.)

IMO, this one should be OK, and looks it is a bit similar with unlinking
empty interrupt qh.


Thanks,
-- 
Ming Lei
--
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