Re: [v4l-dvb-maintainer] 2.6.19-rc1: DVB frontend selection causes compile errors

Trent Piepho
2006-10-14T13:32:52Z

On Fri, 13 Oct 2006, Randy Dunlap wrote:
> On Mon, 09 Oct 2006 04:27:26 -0400 Michael Krufky wrote:
> > Adrian Bunk wrote:
> > >> +#if defined(CONFIG_DVB_TDA10086) || defined(CONFIG_DVB_TDA10086_MODULE)
> > >
> > > this breaks with CONFIG_VIDEO_SAA7134_DVB=y, CONFIG_DVB_TDA1004X=m.
> > >
> > > #if defined(CONFIG_DVB_TDA10086) || (defined(CONFIG_DVB_TDA10086_MODULE) && defined(MODULE))

I'd do this ^^^.

> > > might work, but the whole manual frontend selection IMHO looks a bit
> > > fragile.
> > >
> >
> > That's never going to work -- If the card driver is build as y, then the frontend must also be built y...

The frontend must only be built as 'y' if it the card driver (built as 'y')
wants to use it. There is no reason you couldn't compile a card driver
into the kernel, and set one of the supported front-ends to be a module, so
that a different card driver, compiled as a module, could use it. For
instance, use 'y' for all built-in hardware and then 'm' for hot-pluggable
USB devices and their front-ends.

> Where is the connection between the card driver and the frontend(s)?
> Is it in card driver source files or frontend source files
> or in Kconfig files? I looked but didn't see it (in Kconfig).

It's in the card driver source files. They call (only) a xxxx_attach()
function to get the frontend. The Kconfig entry for a card driver has
'select' lines for all the front-ends it can use, when DVB_FE_CUSTOMISE is
turned off. When DVB_FE_CUSTOMISE is on, the user must turn on the
front-ends they want.