Re: [PATCH] Request xc3028_release symbol when CONFIG_DVB_CORE_ATTACH is defined

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

 



On Mon, 7 May 2007, System Administrator wrote:
> On Mon, 2007-05-07 at 06:20 +1000, System Administrator wrote:
> > I think that the bug is that xc3028_attach is returning 0 to indicate
> > success whereas dvb_attach() is treating 0 as failure?
>
> Hello again,
>
> I have verified that this is indeed what is happening.  xc3028_tuner
> should be returning a pointer on success, not 0.  Here's a patch to fix
> that.

You're right, dvb_attach() expects the function will return a pointer, so
NULL == failure.

dvb_attach() does a symbol_put() on failure, but not on success, since it
needs to keep a reference to the module it attached to.  It's important
that symbol_get() (via symbol_request) is called _before_ the attach
function is called, and that symbol_put() is called _after_ the release
function.

_______________________________________________
linux-dvb mailing list
linux-dvb@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb

[Index of Archives]     [Linux Media]     [Video 4 Linux]     [Asterisk]     [Samba]     [Xorg]     [Xfree86]     [Linux USB]

  Powered by Linux