summaryrefslogtreecommitdiff
path: root/linux/drivers/media/dvb/frontends/dib3000mc.h
diff options
context:
space:
mode:
authorTrent Piepho <xyzzy@speakeasy.org>2006-10-14 11:44:44 -0700
committerTrent Piepho <xyzzy@speakeasy.org>2006-10-14 11:44:44 -0700
commitabe7551960927241e089f9b21abc600cd08cbe43 (patch)
tree38e019324596a94de7cb9ccf820deb45e8032fc2 /linux/drivers/media/dvb/frontends/dib3000mc.h
parent687c7cc04cf2c33a622fbf17e7bd84bbd85b2c91 (diff)
downloadmediapointer-dvb-s2-abe7551960927241e089f9b21abc600cd08cbe43.tar.gz
mediapointer-dvb-s2-abe7551960927241e089f9b21abc600cd08cbe43.tar.bz2
Fix DBV_FE_CUSTOMISE for card drivers compiled into kernel
From: Trent Piepho <xyzzy@speakeasy.org> When a front-end is disabled, card drivers that use it are compiled with a stub version of the front-end's attach function. This way they have no references to the front-end's code and don't need it to be loaded. If a card driver is compiled into the kernel, and a front-end is a module, then that front-end is effectively disabled wrt the card driver. In this case, the card driver should get the stub version. This was not happening. The stub vs real attach function selection is changed so that when the front-end is a module the real attach function is only used if the card driver is a module as well. This means a module front-end will be supported by card drivers that are modules and not supported by card drivers compiled into the kernel. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Diffstat (limited to 'linux/drivers/media/dvb/frontends/dib3000mc.h')
-rw-r--r--linux/drivers/media/dvb/frontends/dib3000mc.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/linux/drivers/media/dvb/frontends/dib3000mc.h b/linux/drivers/media/dvb/frontends/dib3000mc.h
index 0d6fdef77..72d475760 100644
--- a/linux/drivers/media/dvb/frontends/dib3000mc.h
+++ b/linux/drivers/media/dvb/frontends/dib3000mc.h
@@ -39,7 +39,7 @@ struct dib3000mc_config {
#define DEFAULT_DIB3000MC_I2C_ADDRESS 16
#define DEFAULT_DIB3000P_I2C_ADDRESS 24
-#if defined(CONFIG_DVB_DIB3000MC) || defined(CONFIG_DVB_DIB3000MC_MODULE)
+#if defined(CONFIG_DVB_DIB3000MC) || (defined(CONFIG_DVB_DIB3000MC_MODULE) && defined(MODULE))
extern struct dvb_frontend * dib3000mc_attach(struct i2c_adapter *i2c_adap, u8 i2c_addr, struct dib3000mc_config *cfg);
#else
static inline struct dvb_frontend * dib3000mc_attach(struct i2c_adapter *i2c_adap, u8 i2c_addr, struct dib3000mc_config *cfg)