]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
V4L/DVB (4387): Add Kconfig infrastructure for dvb_attach
authorAndrew de Quincey <adq_dvb@lidskialf.net>
Tue, 8 Aug 2006 12:10:08 +0000 (09:10 -0300)
committerMauro Carvalho Chehab <mchehab@infradead.org>
Tue, 26 Sep 2006 14:53:25 +0000 (11:53 -0300)
Allow it to be en/disabled
Disable it in < 2.6.17 due to symbol_xxx() bug

Signed-off-by: Andrew de Quincey <adq_dvb@lidskialf.net>
Acked-by: Michael Krufky <mkrufky@linuxtv.org>
Acked-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
32 files changed:
drivers/media/dvb/bt8xx/dst.c
drivers/media/dvb/dvb-core/Kconfig
drivers/media/dvb/dvb-usb/Kconfig
drivers/media/dvb/frontends/bcm3510.h
drivers/media/dvb/frontends/cx22700.h
drivers/media/dvb/frontends/cx22702.h
drivers/media/dvb/frontends/cx24110.h
drivers/media/dvb/frontends/cx24123.h
drivers/media/dvb/frontends/dib3000.h
drivers/media/dvb/frontends/isl6421.h
drivers/media/dvb/frontends/l64781.h
drivers/media/dvb/frontends/lgdt330x.h
drivers/media/dvb/frontends/lnbp21.h
drivers/media/dvb/frontends/mt312.h
drivers/media/dvb/frontends/mt352.h
drivers/media/dvb/frontends/nxt200x.h
drivers/media/dvb/frontends/nxt6000.h
drivers/media/dvb/frontends/or51132.h
drivers/media/dvb/frontends/or51211.h
drivers/media/dvb/frontends/s5h1420.h
drivers/media/dvb/frontends/sp8870.h
drivers/media/dvb/frontends/sp887x.h
drivers/media/dvb/frontends/stv0297.h
drivers/media/dvb/frontends/stv0299.h
drivers/media/dvb/frontends/tda10021.h
drivers/media/dvb/frontends/tda1004x.h
drivers/media/dvb/frontends/tda8083.h
drivers/media/dvb/frontends/ves1820.h
drivers/media/dvb/frontends/ves1x93.h
drivers/media/dvb/frontends/zl10353.h
drivers/media/video/cx88/Kconfig
drivers/media/video/saa7134/Kconfig

index 91dea91b1a43a65fccbc2c2362bbd3d086959200..a853c14c61d33103c091e7682266478e586e4f46 100644 (file)
@@ -1716,8 +1716,10 @@ static void dst_release(struct dvb_frontend *fe)
 {
        struct dst_state *state = fe->demodulator_priv;
 
+#ifdef CONFIG_DVB_CORE_ATTACH
        if (state->dst_hw_cap & DST_TYPE_HAS_CA)
                symbol_put(dst_ca_attach);
+#endif
 
        kfree(state);
 }
index 12ee912a5705176af05f73be9e61ffa2e140687d..7853880617fc64168e096b4c0136f2dcd02ad4b5 100644 (file)
@@ -9,3 +9,14 @@ config DVB_CORE
          in-kernel drivers will select this automatically if needed.
          If unsure say N.
 
+config DVB_CORE_ATTACH
+       bool "Load and attach frontend modules as needed"
+       depends on DVB_CORE
+       depends on MODULES
+       help
+         Remove the static dependency of DVB card drivers on all
+         frontend modules for all possible card variants. Instead,
+         allow the card drivers to only load the frontend modules
+         they require. This saves several KBytes of memory.
+
+         If unsure say Y.
index 75824b77198ab2a2524f5d123c719455a1fdadfb..d9f13adc87a8138d7f2fd261881631888070195b 100644 (file)
@@ -86,10 +86,10 @@ config DVB_USB_UMT_010
 config DVB_USB_CXUSB
        tristate "Conexant USB2.0 hybrid reference design support"
        depends on DVB_USB
-       select DVB_CX22702
-       select DVB_LGDT330X
-       select DVB_MT352
-       select DVB_ZL10353
+       select DVB_CX22702 if !DVB_FE_CUSTOMISE
+       select DVB_LGDT330X if !DVB_FE_CUSTOMISE
+       select DVB_MT352 if !DVB_FE_CUSTOMISE
+       select DVB_ZL10353 if !DVB_FE_CUSTOMISE
        help
          Say Y here to support the Conexant USB2.0 hybrid reference design.
          Currently, only DVB and ATSC modes are supported, analog mode
@@ -101,8 +101,8 @@ config DVB_USB_CXUSB
 config DVB_USB_DIGITV
        tristate "Nebula Electronics uDigiTV DVB-T USB2.0 support"
        depends on DVB_USB
-       select DVB_NXT6000
-       select DVB_MT352
+       select DVB_NXT6000 if !DVB_FE_CUSTOMISE
+       select DVB_MT352 if !DVB_FE_CUSTOMISE
        help
          Say Y here to support the Nebula Electronics uDigitV USB2.0 DVB-T receiver.
 
index 80f5d0953d02635797ffdf9fc97ec242ebe01b1f..6dfa839a70224612c4fe72344c78fa080fca18e8 100644 (file)
@@ -34,7 +34,16 @@ struct bcm3510_config
        int (*request_firmware)(struct dvb_frontend* fe, const struct firmware **fw, char* name);
 };
 
+#if defined(CONFIG_DVB_BCM3510) || defined(CONFIG_DVB_BCM3510_MODULE)
 extern struct dvb_frontend* bcm3510_attach(const struct bcm3510_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* bcm3510_attach(const struct bcm3510_config* config,
+                                                 struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_BCM3510
 
 #endif
index dcd8979c1a15e2668b5a5a8a8c276b59366edbb2..10286cc29fb40e8245ea76aae8086499d6c71858 100644 (file)
@@ -31,7 +31,16 @@ struct cx22700_config
        u8 demod_address;
 };
 
+#if defined(CONFIG_DVB_CX22700) || defined(CONFIG_DVB_CX22700_MODULE)
 extern struct dvb_frontend* cx22700_attach(const struct cx22700_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* cx22700_attach(const struct cx22700_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_CX22700
 
 #endif // CX22700_H
index 7f2f241e5d4485985cfe0c0c23ddafd489e8add5..bc217ddf02c09f427c70822b6a4dd74106fa75db 100644 (file)
@@ -41,7 +41,16 @@ struct cx22702_config
        u8 output_mode;
 };
 
+#if defined(CONFIG_DVB_CX22702) || defined(CONFIG_DVB_CX22702_MODULE)
 extern struct dvb_frontend* cx22702_attach(const struct cx22702_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* cx22702_attach(const struct cx22702_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_CX22702
 
 #endif // CX22702_H
index 9c2b76e784f324afc67eede7de3e49da848e6d59..c9d5ae250ebb46296e43ea20fc728dd5b24af86a 100644 (file)
@@ -33,9 +33,6 @@ struct cx24110_config
        u8 demod_address;
 };
 
-extern struct dvb_frontend* cx24110_attach(const struct cx24110_config* config,
-                                          struct i2c_adapter* i2c);
-
 static inline int cx24110_pll_write(struct dvb_frontend *fe, u32 val) {
        int r = 0;
        u8 buf[] = {(u8) (val>>24), (u8) (val>>16), (u8) (val>>8)};
@@ -44,4 +41,16 @@ static inline int cx24110_pll_write(struct dvb_frontend *fe, u32 val) {
        return r;
 }
 
+#if defined(CONFIG_DVB_CX24110) || defined(CONFIG_DVB_CX24110_MODULE)
+extern struct dvb_frontend* cx24110_attach(const struct cx24110_config* config,
+                                          struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* cx24110_attach(const struct cx24110_config* config,
+                                                 struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_CX24110
+
 #endif // CX24110_H
index 9606f825935c8341f53b760e9c91f06e4146e9a8..6a8cb4c41adfb76d21145cd6e359bfcd400f106e 100644 (file)
@@ -32,7 +32,16 @@ struct cx24123_config
        int (*set_ts_params)(struct dvb_frontend* fe, int is_punctured);
 };
 
+#if defined(CONFIG_DVB_CX24123) || defined(CONFIG_DVB_CX24123_MODULE)
 extern struct dvb_frontend* cx24123_attach(const struct cx24123_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* cx24123_attach(const struct cx24123_config* config,
+                                                 struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_CX24123
 
 #endif /* CX24123_H */
index ec927628d2734cac2eee5ef633e5eb55de4d680e..d2ab7479012abf3060e40b4f6298a3af992c914b 100644 (file)
@@ -41,9 +41,28 @@ struct dib_fe_xfer_ops
        int (*tuner_pass_ctrl)(struct dvb_frontend *fe, int onoff, u8 pll_ctrl);
 };
 
+#if defined(CONFIG_DVB_DIB3000MB) || defined(CONFIG_DVB_DIB3000MB_MODULE)
 extern struct dvb_frontend* dib3000mb_attach(const struct dib3000_config* config,
                                             struct i2c_adapter* i2c, struct dib_fe_xfer_ops *xfer_ops);
+#else
+static inline struct dvb_frontend* dib3000mb_attach(const struct dib3000_config* config,
+                                            struct i2c_adapter* i2c, struct dib_fe_xfer_ops *xfer_ops)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_DIB3000MB
 
+#if defined(CONFIG_DVB_DIB3000MC) || defined(CONFIG_DVB_DIB3000MC_MODULE)
 extern struct dvb_frontend* dib3000mc_attach(const struct dib3000_config* config,
                                             struct i2c_adapter* i2c, struct dib_fe_xfer_ops *xfer_ops);
+#else
+static inline struct dvb_frontend* dib3000mc_attach(const struct dib3000_config* config,
+                                            struct i2c_adapter* i2c, struct dib_fe_xfer_ops *xfer_ops)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_DIB3000MC
+
 #endif // DIB3000_H
index b5deacfe6d2f10af63b57bc312d44bd77796613f..1916e3eb2df39c30d07b5bc889e80e0c08cc7d70 100644 (file)
 #define ISL6421_ISEL1  0x20
 #define ISL6421_DCL    0x40
 
+#if defined(CONFIG_DVB_ISL6421) || defined(CONFIG_DVB_ISL6421_MODULE)
 /* override_set and override_clear control which system register bits (above) to always set & clear */
 extern struct dvb_frontend *isl6421_attach(struct dvb_frontend *fe, struct i2c_adapter *i2c, u8 i2c_addr,
                          u8 override_set, u8 override_clear);
+#else
+static inline struct dvb_frontend *isl6421_attach(struct dvb_frontend *fe, struct i2c_adapter *i2c, u8 i2c_addr,
+                                                 u8 override_set, u8 override_clear)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_ISL6421
 
 #endif
index 83b8bc21027404563875208b3e559d2037ef287a..21ba4a2307601067348e4a0d50d774927357c6cb 100644 (file)
@@ -31,8 +31,16 @@ struct l64781_config
        u8 demod_address;
 };
 
-
+#if defined(CONFIG_DVB_L64781) || defined(CONFIG_DVB_L64781_MODULE)
 extern struct dvb_frontend* l64781_attach(const struct l64781_config* config,
                                          struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* l64781_attach(const struct l64781_config* config,
+                                         struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_L64781
 
 #endif // L64781_H
index bad903c6f0f8261111a6b1d2b7dfe3bdbabb9325..3f96b485584c663ce68deac95b0e32970aa83689 100644 (file)
@@ -52,8 +52,17 @@ struct lgdt330x_config
        int clock_polarity_flip;
 };
 
+#if defined(CONFIG_DVB_LGDT330X) || defined(CONFIG_DVB_LGDT330X_MODULE)
 extern struct dvb_frontend* lgdt330x_attach(const struct lgdt330x_config* config,
                                            struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* lgdt330x_attach(const struct lgdt330x_config* config,
+                                           struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_LGDT330X
 
 #endif /* LGDT330X_H */
 
index 8c2df67d81eecbcf8735ca1c47289cb3892e5beb..1fe1dd1793123985b813fda65b992c332e4162cb 100644 (file)
 
 #include <linux/dvb/frontend.h>
 
+#if defined(CONFIG_DVB_LNBP21) || defined(CONFIG_DVB_LNBP21_MODULE)
 /* override_set and override_clear control which system register bits (above) to always set & clear */
 extern struct dvb_frontend *lnbp21_attach(struct dvb_frontend *fe, struct i2c_adapter *i2c, u8 override_set, u8 override_clear);
+#else
+static inline struct dvb_frontend *lnbp21_attach(struct dvb_frontend *fe, struct i2c_adapter *i2c, u8 override_set, u8 override_clear)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_LNBP21
 
-#endif
+#endif // _LNBP21_H
index 666a1bd1c244ff0752c9b79a64d5abb08c5f7d07..7112fb4d58acb3a59db6c8313b9b83f309b71750 100644 (file)
@@ -34,8 +34,16 @@ struct mt312_config
        u8 demod_address;
 };
 
+#if defined(CONFIG_DVB_MT312) || defined(CONFIG_DVB_MT312_MODULE)
 struct dvb_frontend* vp310_mt312_attach(const struct mt312_config* config,
                                        struct i2c_adapter* i2c);
-
+#else
+static inline struct dvb_frontend* vp310_mt312_attach(const struct mt312_config* config,
+                                       struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_MT312
 
 #endif // MT312_H
index 0de2057f9d9cce990ee8893e22cf663846e6f2d1..0035c2e2d7c275ee8eb937304535ce643f2e8454 100644 (file)
@@ -51,8 +51,17 @@ struct mt352_config
        int (*demod_init)(struct dvb_frontend* fe);
 };
 
+#if defined(CONFIG_DVB_MT352) || defined(CONFIG_DVB_MT352_MODULE)
 extern struct dvb_frontend* mt352_attach(const struct mt352_config* config,
                                         struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* mt352_attach(const struct mt352_config* config,
+                                        struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_MT352
 
 static inline int mt352_write(struct dvb_frontend *fe, u8 *buf, int len) {
        int r = 0;
index 34d61735845be8199d3d75e3c89614250b8f57aa..2eb220e9806257e09352b3349509a520456cccf0 100644 (file)
@@ -45,8 +45,17 @@ struct nxt200x_config
        int (*set_ts_params)(struct dvb_frontend* fe, int is_punctured);
 };
 
+#if defined(CONFIG_DVB_NXT200X) || defined(CONFIG_DVB_NXT200X_MODULE)
 extern struct dvb_frontend* nxt200x_attach(const struct nxt200x_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* nxt200x_attach(const struct nxt200x_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_NXT200X
 
 #endif /* NXT200X_H */
 
index 117031d117082009c1fab69377059f29110f7a5a..9397393a6bd10ab63426d058af78b7eaa8cd1463 100644 (file)
@@ -33,7 +33,16 @@ struct nxt6000_config
        u8 clock_inversion:1;
 };
 
+#if defined(CONFIG_DVB_NXT6000) || defined(CONFIG_DVB_NXT6000_MODULE)
 extern struct dvb_frontend* nxt6000_attach(const struct nxt6000_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* nxt6000_attach(const struct nxt6000_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_NXT6000
 
 #endif // NXT6000_H
index 89658883abf5eb65a241b9b8f14bd024f8a9738d..9718be4fb8358ba33e436a7ea8d2edc9da2606b5 100644 (file)
@@ -34,8 +34,17 @@ struct or51132_config
        int (*set_ts_params)(struct dvb_frontend* fe, int is_punctured);
 };
 
+#if defined(CONFIG_DVB_OR51132) || defined(CONFIG_DVB_OR51132_MODULE)
 extern struct dvb_frontend* or51132_attach(const struct or51132_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* or51132_attach(const struct or51132_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_OR51132
 
 #endif // OR51132_H
 
index 13a5a3afbf8b1e8fe8f184a3448ec82f370420f7..10a5419f9e0041c3e3cbc74a94ce66153579696c 100644 (file)
@@ -37,8 +37,17 @@ struct or51211_config
        void (*sleep)(struct dvb_frontend * fe);
 };
 
+#if defined(CONFIG_DVB_OR51211) || defined(CONFIG_DVB_OR51211_MODULE)
 extern struct dvb_frontend* or51211_attach(const struct or51211_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* or51211_attach(const struct or51211_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_OR51211
 
 #endif // OR51211_H
 
index 4e39015fa67e38c17bf519e8f6b143ff81a2fb3f..efc54d7f3c5569681c68af061e95771cbcefbf0b 100644 (file)
@@ -34,7 +34,16 @@ struct s5h1420_config
        u8 invert:1;
 };
 
+#if defined(CONFIG_DVB_S5H1420) || defined(CONFIG_DVB_S5H1420_MODULE)
 extern struct dvb_frontend* s5h1420_attach(const struct s5h1420_config* config,
             struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* s5h1420_attach(const struct s5h1420_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_S5H1420
 
 #endif // S5H1420_H
index 93afbb969d6b57f7b54cc104fe575fc5ce4641f4..4cf27d3b10f2ef8d520d717b0a24236e9a7201a5 100644 (file)
@@ -35,7 +35,16 @@ struct sp8870_config
        int (*request_firmware)(struct dvb_frontend* fe, const struct firmware **fw, char* name);
 };
 
+#if defined(CONFIG_DVB_SP8870) || defined(CONFIG_DVB_SP8870_MODULE)
 extern struct dvb_frontend* sp8870_attach(const struct sp8870_config* config,
                                          struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* sp8870_attach(const struct sp8870_config* config,
+                                         struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_SP8870
 
 #endif // SP8870_H
index c44b0ebdf1e220e32dd2c10a469e106ba1401c9f..cab7ea644dfa485b4da728554379383cfd44cf4c 100644 (file)
@@ -17,7 +17,16 @@ struct sp887x_config
        int (*request_firmware)(struct dvb_frontend* fe, const struct firmware **fw, char* name);
 };
 
+#if defined(CONFIG_DVB_SP887X) || defined(CONFIG_DVB_SP887X_MODULE)
 extern struct dvb_frontend* sp887x_attach(const struct sp887x_config* config,
                                          struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* sp887x_attach(const struct sp887x_config* config,
+                                         struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_SP887X
 
 #endif // SP887X_H
index 1da5384fb985454b06f6aa8b027dba583853338d..760b80db43a57080ea66a92caf5c1cefccadd6c2 100644 (file)
@@ -42,7 +42,16 @@ struct stv0297_config
        u8 stop_during_read:1;
 };
 
+#if defined(CONFIG_DVB_STV0297) || defined(CONFIG_DVB_STV0297_MODULE)
 extern struct dvb_frontend* stv0297_attach(const struct stv0297_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* stv0297_attach(const struct stv0297_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_STV0297
 
 #endif // STV0297_H
index d1abaf978a03e15abfc5197217ff4dd24286fcb4..7ef25207081d2ee46b2b2f128ef3ea99c33b0fb1 100644 (file)
@@ -89,8 +89,17 @@ struct stv0299_config
        int (*set_symbol_rate)(struct dvb_frontend* fe, u32 srate, u32 ratio);
 };
 
+#if defined(CONFIG_DVB_STV0299) || defined(CONFIG_DVB_STV0299_MODULE)
 extern struct dvb_frontend* stv0299_attach(const struct stv0299_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* stv0299_attach(const struct stv0299_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_STV0299
 
 static inline int stv0299_writereg(struct dvb_frontend *fe, u8 reg, u8 val) {
        int r = 0;
index e77df5ed7807a1cbd8b715f1324a502b3ed9bff0..d68ae20c84129c92a6b17b6b37b58612cd420d17 100644 (file)
@@ -32,8 +32,17 @@ struct tda10021_config
        u8 demod_address;
 };
 
+#if defined(CONFIG_DVB_TDA10021) || defined(CONFIG_DVB_TDA10021_MODULE)
 extern struct dvb_frontend* tda10021_attach(const struct tda10021_config* config,
                                            struct i2c_adapter* i2c, u8 pwm);
+#else
+static inline struct dvb_frontend* tda10021_attach(const struct tda10021_config* config,
+                                           struct i2c_adapter* i2c, u8 pwm)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_TDA10021
 
 static inline int tda10021_writereg(struct dvb_frontend *fe, u8 reg, u8 val) {
        int r = 0;
index 7ffffa0c65f5251b4495fa74347dc262e66892a3..e28fca05734c30f9001549dce908e249442140fb 100644 (file)
@@ -71,11 +71,26 @@ struct tda1004x_config
        int (*request_firmware)(struct dvb_frontend* fe, const struct firmware **fw, char* name);
 };
 
+#if defined(CONFIG_DVB_TDA1004X) || defined(CONFIG_DVB_TDA1004X_MODULE)
 extern struct dvb_frontend* tda10045_attach(const struct tda1004x_config* config,
                                            struct i2c_adapter* i2c);
 
 extern struct dvb_frontend* tda10046_attach(const struct tda1004x_config* config,
                                            struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* tda10045_attach(const struct tda1004x_config* config,
+                                           struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+static inline struct dvb_frontend* tda10046_attach(const struct tda1004x_config* config,
+                                           struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_TDA1004X
 
 static inline int tda1004x_writereg(struct dvb_frontend *fe, u8 reg, u8 val) {
        int r = 0;
index e7a48f61ea2c6382e2e272f7f1b37f5e3c58d813..aae15bdce6ebafcc3d900c45117e473077344f50 100644 (file)
@@ -35,7 +35,16 @@ struct tda8083_config
        u8 demod_address;
 };
 
+#if defined(CONFIG_DVB_TDA8083) || defined(CONFIG_DVB_TDA8083_MODULE)
 extern struct dvb_frontend* tda8083_attach(const struct tda8083_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* tda8083_attach(const struct tda8083_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_TDA8083
 
 #endif // TDA8083_H
index 520f09522fbbd0bc7604738ea61c366801aef75c..f0c9dded39d77fea63914ebb82a329ee1d976e87 100644 (file)
@@ -41,7 +41,16 @@ struct ves1820_config
        u8 selagc:1;
 };
 
+#if defined(CONFIG_DVB_VES1820) || defined(CONFIG_DVB_VES1820_MODULE)
 extern struct dvb_frontend* ves1820_attach(const struct ves1820_config* config,
                                           struct i2c_adapter* i2c, u8 pwm);
+#else
+static inline struct dvb_frontend* ves1820_attach(const struct ves1820_config* config,
+                                          struct i2c_adapter* i2c, u8 pwm)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_VES1820
 
 #endif // VES1820_H
index ba88ae0855c994025b4a13c5e07ae65ab919bca7..395fed39b2865527aea538c434fa953c247a4e09 100644 (file)
@@ -40,7 +40,16 @@ struct ves1x93_config
        u8 invert_pwm:1;
 };
 
+#if defined(CONFIG_DVB_VES1X93) || defined(CONFIG_DVB_VES1X93_MODULE)
 extern struct dvb_frontend* ves1x93_attach(const struct ves1x93_config* config,
                                           struct i2c_adapter* i2c);
+#else
+static inline struct dvb_frontend* ves1x93_attach(const struct ves1x93_config* config,
+                                          struct i2c_adapter* i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_VES1X93
 
 #endif // VES1X93_H
index 15804b384e2d2cc6e8055320fbe295d3bd97cd40..6aec655d88141ffff43f54b4c925c5d06118eeea 100644 (file)
@@ -33,7 +33,16 @@ struct zl10353_config
        int no_tuner;
 };
 
+#if defined(CONFIG_DVB_ZL10353) || defined(CONFIG_DVB_ZL10353_MODULE)
 extern struct dvb_frontend* zl10353_attach(const struct zl10353_config *config,
                                           struct i2c_adapter *i2c);
+#else
+static inline struct dvb_frontend* zl10353_attach(const struct zl10353_config *config,
+                                          struct i2c_adapter *i2c)
+{
+       printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __FUNCTION__);
+       return NULL;
+}
+#endif // CONFIG_DVB_ZL10353
 
 #endif /* ZL10353_H */
index 7a94e6a11927bdf877b7f8440fc5b499adff002c..51d68f32aa068f9e7fa2c39d21ac31c56b7ae463 100644 (file)
@@ -1,7 +1,3 @@
-config VIDEO_CX88_VP3054
-       tristate
-       depends on VIDEO_CX88_DVB && DVB_MT352
-
 config VIDEO_CX88
        tristate "Conexant 2388x (bt878 successor) support"
        depends on VIDEO_DEV && PCI && I2C
@@ -52,6 +48,14 @@ config VIDEO_CX88_DVB
        depends on VIDEO_CX88 && DVB_CORE
        select VIDEO_BUF_DVB
        select DVB_PLL
+       select DVB_MT352 if !DVB_FE_CUSTOMISE
+       select DVB_ZL10353 if !DVB_FE_CUSTOMISE
+       select DVB_OR51132 if !DVB_FE_CUSTOMISE
+       select DVB_CX22702 if !DVB_FE_CUSTOMISE
+       select DVB_LGDT330X if !DVB_FE_CUSTOMISE
+       select DVB_NXT200X if !DVB_FE_CUSTOMISE
+       select DVB_CX24123 if !DVB_FE_CUSTOMISE
+       select DVB_ISL6421 if !DVB_FE_CUSTOMISE
        ---help---
          This adds support for DVB/ATSC cards based on the
          Conexant 2388x chip.
@@ -59,101 +63,12 @@ config VIDEO_CX88_DVB
          To compile this driver as a module, choose M here: the
          module will be called cx88-dvb.
 
-         You must also select one or more DVB/ATSC demodulators.
-         If you are unsure which you need, choose all of them.
-
-config VIDEO_CX88_DVB_ALL_FRONTENDS
-       bool "Build all supported frontends for cx2388x based TV cards"
-       default y
-       depends on VIDEO_CX88_DVB
-       select DVB_MT352
-       select VIDEO_CX88_VP3054
-       select DVB_ZL10353
-       select DVB_OR51132
-       select DVB_CX22702
-       select DVB_LGDT330X
-       select DVB_NXT200X
-       select DVB_CX24123
-       select DVB_ISL6421
-       ---help---
-         This builds cx88-dvb with all currently supported frontend
-         demodulators.  If you wish to tweak your configuration, and
-         only include support for the hardware that you need, choose N here.
-
-         If you are unsure, choose Y.
-
-config VIDEO_CX88_DVB_MT352
-       bool "Zarlink MT352 DVB-T Support"
-       default y
-       depends on VIDEO_CX88_DVB && !VIDEO_CX88_DVB_ALL_FRONTENDS
-       select DVB_MT352
-       ---help---
-         This adds DVB-T support for cards based on the
-         Connexant 2388x chip and the MT352 demodulator.
-
-config VIDEO_CX88_DVB_VP3054
-       bool "VP-3054 Secondary I2C Bus Support"
-       default y
-       depends on VIDEO_CX88_DVB_MT352
-       select VIDEO_CX88_VP3054
+config VIDEO_CX88_VP3054
+       tristate "VP-3054 Secondary I2C Bus Support"
+       default m
+       depends on VIDEO_CX88_DVB && DVB_MT352
        ---help---
          This adds DVB-T support for cards based on the
          Connexant 2388x chip and the MT352 demodulator,
          which also require support for the VP-3054
          Secondary I2C bus, such at DNTV Live! DVB-T Pro.
-
-config VIDEO_CX88_DVB_ZL10353
-       bool "Zarlink ZL10353 DVB-T Support"
-       default y
-       depends on VIDEO_CX88_DVB && !VIDEO_CX88_DVB_ALL_FRONTENDS
-       select DVB_ZL10353
-       ---help---
-         This adds DVB-T support for cards based on the
-         Connexant 2388x chip and the ZL10353 demodulator,
-         successor to the Zarlink MT352.
-
-config VIDEO_CX88_DVB_OR51132
-       bool "OR51132 ATSC Support"
-       default y
-       depends on VIDEO_CX88_DVB && !VIDEO_CX88_DVB_ALL_FRONTENDS
-       select DVB_OR51132
-       ---help---
-         This adds ATSC 8VSB and QAM64/256 support for cards based on the
-         Connexant 2388x chip and the OR51132 demodulator.
-
-config VIDEO_CX88_DVB_CX22702
-       bool "Conexant CX22702 DVB-T Support"
-       default y
-       depends on VIDEO_CX88_DVB && !VIDEO_CX88_DVB_ALL_FRONTENDS
-       select DVB_CX22702
-       ---help---
-         This adds DVB-T support for cards based on the
-         Connexant 2388x chip and the CX22702 demodulator.
-
-config VIDEO_CX88_DVB_LGDT330X
-       bool "LG Electronics DT3302/DT3303 ATSC Support"
-       default y
-       depends on VIDEO_CX88_DVB && !VIDEO_CX88_DVB_ALL_FRONTENDS
-       select DVB_LGDT330X
-       ---help---
-         This adds ATSC 8VSB and QAM64/256 support for cards based on the
-         Connexant 2388x chip and the LGDT3302/LGDT3303 demodulator.
-
-config VIDEO_CX88_DVB_NXT200X
-       bool "NXT2002/NXT2004 ATSC Support"
-       default y
-       depends on VIDEO_CX88_DVB && !VIDEO_CX88_DVB_ALL_FRONTENDS
-       select DVB_NXT200X
-       ---help---
-         This adds ATSC 8VSB and QAM64/256 support for cards based on the
-         Connexant 2388x chip and the NXT2002/NXT2004 demodulator.
-
-config VIDEO_CX88_DVB_CX24123
-       bool "Conexant CX24123 DVB-S Support"
-       default y
-       depends on VIDEO_CX88_DVB && !VIDEO_CX88_DVB_ALL_FRONTENDS
-       select DVB_CX24123
-       select DVB_ISL6421
-       ---help---
-         This adds DVB-S support for cards based on the
-         Connexant 2388x chip and the CX24123 demodulator.
index f5543166d1930fce988fc0c32f39abe5e57b4d08..59da79ce2efda40cf7b45758dd8928a7eb82915d 100644 (file)
@@ -41,53 +41,15 @@ config VIDEO_SAA7134_DVB
        select VIDEO_BUF_DVB
        select FW_LOADER
        select DVB_PLL
+       select DVB_MT352 if !DVB_FE_CUSTOMISE
+       select DVB_TDA1004X if !DVB_FE_CUSTOMISE
+       select DVB_NXT200X if !DVB_FE_CUSTOMISE
+       select DVB_TDA10086 if !DVB_FE_CUSTOMISE
+       select DVB_TDA826X if !DVB_FE_CUSTOMISE
+       select DVB_ISL6421 if !DVB_FE_CUSTOMISE
        ---help---
          This adds support for DVB cards based on the
          Philips saa7134 chip.
 
          To compile this driver as a module, choose M here: the
          module will be called saa7134-dvb.
-
-         You must also select one or more DVB demodulators.
-         If you are unsure which you need, choose all of them.
-
-config VIDEO_SAA7134_DVB_ALL_FRONTENDS
-       bool "Build all supported frontends for saa7134 based TV cards"
-       default y
-       depends on VIDEO_SAA7134_DVB
-       select DVB_MT352
-       select DVB_TDA1004X
-       select DVB_NXT200X
-       ---help---
-         This builds saa7134-dvb with all currently supported frontend
-         demodulators.  If you wish to tweak your configuration, and
-         only include support for the hardware that you need, choose N here.
-
-         If you are unsure, choose Y.
-
-config VIDEO_SAA7134_DVB_MT352
-       bool "Zarlink MT352 DVB-T Support"
-       default y
-       depends on VIDEO_SAA7134_DVB && !VIDEO_SAA7134_DVB_ALL_FRONTENDS
-       select DVB_MT352
-       ---help---
-         This adds DVB-T support for cards based on the
-         Philips saa7134 chip and the MT352 demodulator.
-
-config VIDEO_SAA7134_DVB_TDA1004X
-       bool "Phillips TDA10045H/TDA10046H DVB-T Support"
-       default y
-       depends on VIDEO_SAA7134_DVB && !VIDEO_SAA7134_DVB_ALL_FRONTENDS
-       select DVB_TDA1004X
-       ---help---
-         This adds DVB-T support for cards based on the
-         Philips saa7134 chip and the TDA10045H/TDA10046H demodulator.
-
-config VIDEO_SAA7134_DVB_NXT200X
-       bool "NXT2002/NXT2004 ATSC Support"
-       default y
-       depends on VIDEO_SAA7134_DVB && !VIDEO_SAA7134_DVB_ALL_FRONTENDS
-       select DVB_NXT200X
-       ---help---
-         This adds ATSC 8VSB and QAM64/256 support for cards based on the
-         Philips saa7134 chip and the NXT2002/NXT2004 demodulator.