Mailing List archive

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

[vdr] Re: [linux-dvb] lockups with NEWSTRUCT



Klaus Schmidinger wrote:
> 
> Holger Waechtler wrote:
> >
> > Thanks, for spotting this out!
> >
> > Klaus: Could you please apply this fix?
> >
> > thanks,
> >
> > Holger
> 
> I have updated the CVS NEWSTRUCT driver and applied the fix suggested below.
> The first impression was very good: no more dropouts and no ARM crashes.
> 
> Then I started a recording on my second DVB card, and suddenly I had dropouts
> on my _first_ DVB card, which wasn't even involved in the recording.
> 
> When I replayed the recording there were no such dropouts, so the second
> card actually recorded just fine (note that my second DVB card is a budget card).
> 
> Bottom line: dropout and ARM crash problem solved, new problem with dropouts
> on first DVB card while recording on second card (I tried this several times
> and it was always reproducable).
> 
> Klaus

I'm afraid I have to revise this statement. When I applied the suggested fix to
VDR/eit.c I didn't realize that the sctFilterParams.pid was set _before_ the two
calls to memset(). So, as much as the modification appears to be correct since the
struct was not completely initialized, the fix caused the pid to be always 0, so
there was no filter set up at all any more. I noticed that yesterday, because
there was no more EPG information displayed in VDR.

The correct fix should look like this:

--- eit.c       2002/09/15 14:35:32     1.51
+++ eit.c       2002/09/20 16:24:17
@@ -1223,9 +1223,8 @@
 bool cSIProcessor::AddFilter(u_char pid, u_char tid)
 {
    dmxSctFilterParams sctFilterParams;
+   memset(&sctFilterParams, 0, sizeof(sctFilterParams));
    sctFilterParams.pid = pid;
-   memset(&sctFilterParams.filter.filter, 0, DMX_FILTER_SIZE);
-   memset(&sctFilterParams.filter.mask, 0, DMX_FILTER_SIZE);
    sctFilterParams.timeout = 0;
    sctFilterParams.flags = DMX_IMMEDIATE_START;
    sctFilterParams.filter.filter[0] = tid;

But unfortunately with this the dropouts are back again. Well, maybe this is
a hint for you, Holger, anyway. It would explain why the problem only occurs
when VDR is running, and not when only the driver is loaded.

Maybe there's even another problem in the eit.c code, so something would have
to be done differently with the NEWSTRUCT driver. Any hints here would be greatly
appreciated.

Klaus

> 
> > Jeremy Hall wrote:
> > > I have found it.
> > >
> > > In eit.c, look at where a new section filter is created.  I believe we
> > > have discussed this before, it is improper initialization of the filter, I
> > > seem to remember something about a mode or something not being
> > > initialized.
> > >
> > > The recommended fix was
> > >
> > > memset(&sctFilterParams,0,sizeof(sctFilterParams));
> > >
> > > instead of doing filter and mask separately.  Probably somebody long ago
> > > copied some code from somewhere that did it this way and didn't think
> > > about the API changes.
> > >
> > > _J
> > >
> > > In the new year, Holger Waechtler wrote:
> > >
> > >>Hi,
> > >>
> > >>I can reproduce this and will try to find the problem today.
> > >>
> > >>Holger
> > >>
> > >>
> > >>Jeremy Hall wrote:
> > >>
> > >>>Hello,
> > >>>
> > >>>I have been experimenting with vdr-1.1.10 and the NEWSTRUCT driver.  As I
> > >>>start a FTA channel, go into the menu, and scroll through the channels
> > >>>(but don't select one) Soon my vdr freezes.
> > >>>
> > >>>I am using REMOTE=KBD and DEBUG_OSD=1
> > >>>
> > >>>The machine has locked up, doesn't respond to pings etc, but the DVB card
> > >>>continues to display the FTA channel.
> > >>>
> > >>>This is with 2.4.19-RC1+LL+PREEMPT+firm timers.  This works out just fine
> > >>>with the head driver.  It is configured as a UP kernel.

-- 
_______________________________________________________________

Klaus Schmidinger                       Phone: +49-8635-6989-10
CadSoft Computer GmbH                   Fax:   +49-8635-6989-40
Hofmark 2                               Email:   kls@cadsoft.de
D-84568 Pleiskirchen, Germany           URL:     www.cadsoft.de
_______________________________________________________________




Home | Main Index | Thread Index