Re: ehci frame index goes backwards?

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

 



On Wed, 24 Oct 2018, Daniel Goertzen wrote:

> I am developing a custom USB device that makes use of isochronous IN
> transfers.  It works fine from my laptop (xHCI) however on an embedded
> target (vortex86dx3, EHCI) I am seeing mysterious EFBIG errors.  After
> adding lots of debug to ehci-sched I discovered that the EHCI register
> "FRINDEX" which is supposed to increase monotonically, is actually
> taking a jump backwards:
> 
> [   25.576198] ehci-pci 0000:00:0a.1: scan_isoc
> ehci_read_frame_index(ehci)=12318
> [   25.576523] ehci-pci 0000:00:0a.1: iso_stream_schedule
> ehci_read_frame_index(ehci)=12292  <- (count goes down!?)

Even stranger, the difference between the two timestamps is only 325
us, during which time the frame index value should not increase by more
than 3.  But here we see it decreasing by 26!

> [   25.576550] ehci-pci 0000:00:0a.1: request c302d23e would overflow
> (4104+288 >= 4096)
> 
> The backwards jump screws up periodic scheduling and culminates in the
> EFBIG error I've been seeing.  I'm suspecting buggy EHCI hardware, but
> my question is... could anything else cause this?

Not anything else I can think of.

Alan Stern

> Other misc background facts:
> - Host is an Adlink CM1 PC104 module which contains a Vortex86 DX3.
> USB device is an LPC4323 operating full-speed.
> - I instigate the error by softbooting the system.  EFBIG typically
> happens within a minute or does not happen at all.
> - I also get EXDEV errors from "URB was too late" in sitd_complete().
> I suspect this is related to the problem above but don't fully
> understand the mechanism.
> 
> Thanks,
> Dan.




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

  Powered by Linux