Skip to content

DVB-C USB transport stream broken #82

Closed

Description

@r10r

Hi,

I need some help debugging a USB transfer problem on my raspberry pi.

The problem is that the DVB Transport stream recorded from a USB DVB stick (cinergy htc stick)
attached to a usb hub which is attached to the raspberry pi is broken because packages are missing.
I plugged the USB DVB stick directly into the Pi's USB Port (with additional power) with the
same results. I use the latest media_build from linuxtv.org against the 3.1.9 raspberry pi kernel.
The same drivers from the media_build work perfectly with a 3.1.9 kernel on my thinkpad.

When turning on debugging in the DVB driver I get the following messages:

[  126.162705] tda18271: performing RF tracking filter calibration
[  128.056572] tda18271: RF tracking filter calibration complete
[  128.057855] em28xx #0/2-dvb: Using 5 buffers each with 64 x 940 bytes
[  129.052712] em28xx #0/2-dvb: ISO ERROR COUNT: 1.
[  129.052743] em28xx #0/2-dvb: URB packet 0, status -4001 [Unknown].
[  129.581352] em28xx #0/2-dvb: ISO ERROR COUNT: 1.
[  129.581384] em28xx #0/2-dvb: URB packet 0, status -4001 [Unknown].
[  129.872090] em28xx #0/2-dvb: ISO ERROR COUNT: 1.
[  129.872122] em28xx #0/2-dvb: URB packet 0, status -4001 [Unknown].
[  129.969224] em28xx #0/2-dvb: ISO ERROR COUNT: 1.
[  129.969258] em28xx #0/2-dvb: URB packet 44, status -4001 [Unknown].

My assumption is that the isochronous transfer is broken for the usb host driver.

The error code is defined in:

 drivers/usb/host/dwc_common_port/dwc_os.h:#define DWC_E_NO_STREAM_RES   4001

which is caused by a DWC_OTG_HC_XFER_FRAME_OVERRUN in the URB:

 dwc_otg/dwc_otg_hcd_intr.c:            frame_desc->status = -DWC_E_NO_STREAM_RES;

I'm a bit lost since I do not have any USB specific knowledge but I really want
to get the DVB Stick running. What can I do for further testing/debugging?
Thanks for your help!

Cheers,
Ruben

Activity

  1. Dexterp37 commented on Aug 13, 2012

    @Dexterp37

    I guess this is closely related to the problem we are experiencing with the Kinect as documented here

  2. r10r commented on Aug 15, 2012

    @r10r
    Author

    @Dexterp37 Do you have any solution for this problem? Or is there any work in progress?

  3. Dexterp37 commented on Aug 15, 2012

    @Dexterp37

    Sadly.. no :( I noticed that latest kernel source has update USB driver so I'm trying to compile the kernel from source and see if it helps.

  4. r10r commented on Aug 15, 2012

    @r10r
    Author

    Which kernel are you trying? The latest https://github.com/raspberrypi/linux.git from @popcornmix ? Please let me know if it works for you.

  5. Dexterp37 commented on Aug 16, 2012

    @Dexterp37

    At the moment I'm trying to compile the one from @popcornmix . I'll also give 3.2.x from https://github.com/bootc/linux/tree/rpi-3.2.23 a try. I'm still fighting with some cross compilation/fork issues with Cygwin on Windows.

  6. r10r commented on Aug 16, 2012

    @r10r
    Author

    I recommend you to use a debian VM for cross compilation. Setting up the toolchain there is really simple.
    Last version I tried was 921a3d1 - but maybe the newest commit df9a562 fixes something.

  7. r10r commented on Aug 18, 2012

    @r10r
    Author

    @Dexterp37 The error code has changed, but unfortunately USB isoc transfer is still broken with the latest raspberry pi kernel:

    [   71.135721] drxk: frontend initialized.
    [   71.195037] tda18271 0-0060: creating new instance
    [   71.199269] TDA18271HD/C2 detected @ 0-0060
    [   71.262233] drxk: status = 0x639260d9
    [   71.262270] drxk: detected a drx-3926k, spin A3, xtal 20.250 MHz
    [   75.581431] DRXK driver version 0.9.4300
    [   75.927370] DVB: registering new adapter (em28xx #0)
    [   75.927412] DVB: registering adapter 0 frontend 0 (DRXK DVB-C DVB-T)...
    [   75.938859] em28xx #0: Successfully loaded em28xx-dvb
    [   75.938895] Em28xx: Initialized (Em28xx dvb Extension) extension
    [  122.687711] tda18271: performing RF tracking filter calibration
    [  124.590611] tda18271: RF tracking filter calibration complete
    [  124.591786] em28xx #0/2-dvb: Using 5 buffers each with 64 x 940 bytes
    [  126.187359] em28xx #0/2-dvb: ISO ERROR COUNT: 1.
    [  126.187393] em28xx #0/2-dvb: URB packet 11, status -63 [Buffer error (overrun)].
    [  126.195557] em28xx #0/2-dvb: ISO ERROR COUNT: 1.
    [  126.195581] em28xx #0/2-dvb: URB packet 0, status -63 [Buffer error (overrun)].
    
  8. r10r commented on Aug 18, 2012

    @r10r
    Author

    @Dexterp37 You can try the patch from #29 (comment). With this patch I can at least use the TPLink wireless dongle and my USB keyboard together.

  9. popcornmix commented on Aug 20, 2012

    @popcornmix
    Collaborator

    Can you try latest firmware with:
    dwc_otg.microframe_schedule=1
    added to cmdline.txt

  10. r10r commented on Aug 20, 2012

    @r10r
    Author

    Hi thanks for the info. I already tried 0872b20 with the microframe scheduler patch? I already tried the microframe scheduler patch before - USB is more stable, but isoc transfer is still broken.

  11. Dexterp37 commented on Aug 25, 2012

    @Dexterp37

    I can confirm that the transfer is still broken. Tried this morning with latest kernel + microframe schedule and Microsoft Kinect.

  12. ghollingworth commented on Aug 31, 2012

    @ghollingworth

    Can you do a lsusb -v to output the endpoint information, just be interested to see if it's highbandwidth isochronous endpoints that are the problem...

    Likely issue is that it's just the same high latency problem we're seeing elsewhere (i.e. interrupts are disabled for long enough that we miss processing the isochronous requests until the source overrun's its buffers)

    Gordon

  13. Dexterp37 commented on Aug 31, 2012

    @Dexterp37

    @ghollingworth this is my lsusb -v for Microsoft Kinect. This was done by directly connecting to the pi, without an hub. If you need I can provide a lsusb -v listing with an hub too.

    http://pastebin.com/wxY7NQCT

  14. r10r commented on Aug 31, 2012

    @r10r
    Author

    @ghollingworth you can find the output from lsusb -v at https://gist.github.com/3549890. The output from the DVB-C stick is below the full output.

    Are you working on this issue Gordon? Is this similar to the spinlock problem in the sdhci driver?

  15. r10r commented on Aug 31, 2012

    @r10r
    Author
  16. 127 remaining items

  17. added a commit that references this issue on Jan 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions