Re: idea on how to break the static dependencies on demodulator modules

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

 



On Fri, 12 May 2006, Johannes Stezenbach wrote:
> You know, instead of messing with *all* frontend drivers
> and the internals of dvb_unregister_frontend(), I think
> it would be much better to:

I agree with you, it would be better, but I can't think of a way to do it.

> - add dvb_attach() and dvb_detach() functions
> - leave frontend drivers unmodified
> - so nothing changes for out-of-tree STB like users like tuxbox

How can dvb_detach() work, satisfy your three requirements here, AND still
work with chained front-ends?

Without chained frontends, it's easy enough (*):

int dvb_detach(struct dvb_frontend* fe)
{
	void *addr = (void*)fe->ops->release;
	dvb_unregister_frontend(fe);
	symbol_put_addr(addr);
}

But this doesn't work at all with chained frontends.

(*) This assumes, currently correctly, that foo_attach() and foo_release() are
in the same module and that symbol_put/get does module level ref counting and
not symbol level.

_______________________________________________

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