Mailing List archive

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

[linux-dvb] Re: vfree during spin_lock hold (Was: (In)consistency of DMX/DVR buffers and OSD ioctls)



On Thu, Mar 28, 2002 at 02:10:06AM +0100, Ralph Metzler wrote:
> Dr. Werner Fink writes:
>  >      during seeking for a better protection against dropouts of
>  > of a PES filter for DMX_PES_OTHER (AC3) using DMX_OUT_TAP caused
>  > by OSD popups, I've seen that within DmxDevSetBufferSize() in
>  > dmxdev.c that vfree() is called within a spin_lock_irq/spin_unlock_irq
>  > pair.  This seems to be a bug.  Enclosed a patch which changes this.
> 
> Correct, that is a bug.
> But 
> 
> +	void *mem=buffer->data;
> 
> should be
> 
> +	void *mem=buf->data;

Oops, yes you're right, sorry.  I've played with an AC3 Live Change for
VDR on DVB driver 0.9.4 with the still patch of Klaus and have seen an
oops on setting buffer size to zero (which should free the data buffer
instead).  Therefore I've looked onto the driver to find the reason.

>  > Also changed in this patch: hold spin_lock in DmxDevTSCallback()
>  > during copy buffers (seems to decrease dropouts caused by other
>  > activities on the system), 
> 
> OK, this also sounds fine.
> 
> Regarding the dropouts, do you really hear differences?
> Do you have an SMP system?

The VDR system at home is a UP only.  And it _seems_ to make
a difference ... maybe this is only a feeling which is wrong.

> On non-SMP systems spin_(un)lock() does nothing at all and 
> cannot make a difference.

Hmmm ... maybe I should test this on my SMP system at home but
for TV this one is really to loud.

> use reparent_to_init() for the
>  > kernel threads "arm_mon" and "fe_thread".
> 
> 
> For the frontend stuff this is fine, but does the ARM firmware 
> reloading in case of a firmware crash still work with this patch?

Im my experience it's better to reload the DVB driver in such
a case.  I've seen never an arm crash which recovers without
that.  Such crashes happens in replay mode of VDR with fast forward
or backward and OSD usage afterwards.
OK the change for the arm_mon thread makes also no difference at all
in such a case so forget about it ;^)


            Werner


-- 
Info:
To unsubscribe send a mail to listar@linuxtv.org with "unsubscribe linux-dvb" as subject.


Home | Main Index | Thread Index