tbsdtv / linux_media

TBS linux open source drivers
https://github.com/tbsdtv/linux_media/wiki
Other
170 stars 79 forks source link

Corrupt streams after epg scan in tvheadend #172

Open tvhdeeptho opened 4 years ago

tvhdeeptho commented 4 years ago

The following refers to linux_media git vesion ae4de630e55ec48a2c170f0011a61ecaf456c2ed and to the tbs6909x card on linux 5.1

During and after epg scan in tvheadend, I see serious picture corruption (in part of the picture blocks of pixels are showing block distortion, sometimes there are audio glitches,...) on the live channel when 7 or 8 epg scans run in the background.

DURING the scan, it is sort of normal to see such issues ( bugs in tvheadend, because the new tvheadend code has issues with threads blocking each other?).

However, AFTER the scan these problems should disappear and they don't. Therefore I think there is a driver bug as well. See below.

Steps to reproduce:

  1. watch an FTA channel (e.g. BBC four hd)

  2. make tvheadend start a background epg scan. You can do this by adjusting the scheduler time in the "Over-the-air Cron multi-line:" setting of tvheadend After a while serious picture corruption starts to occur on the live channel. This happens frequently, e.g., several times per minute. When activating the continuity counter checking debug code in the drivers, more continuity counter errors seem to occur than usual

  3. wait until the scan finishes, or abort the epg scan after 20 minutes by restarting tvheadend

  4. retune to the live channel. No epg grabbing is in progress, but picture issues remain

  5. estart tvheadend and retune to live channel. Still picture issues

  6. stop tvheadend and perform modprobe -r tbsecp3; modprobe tbsecp3; restart tvheadend. picture quality is now OK. It is NOT needed to reload stid135

The fact that the problems disappears by reloading the module tbsecp3 points to a possible driver bug.

Additional information -the problems seem to improve if powersave is disabled on all tuners. Pixellation occurs less frequently -it also helps to disable the other tuner on the same rf frontend (e.g., disable adapter1 when adapter 0 is running the live stream)