Commit 8c125f2c authored by Michael Krufky's avatar Michael Krufky Committed by Mauro Carvalho Chehab

V4L/DVB (6468): tda8290: auto-detect tda8290 or tda8295

Consolidate tda8290_attach() and tda8295_attach() into a single function,
tda829x_attach(), which will detect chip combinations tda8290 or tda8295 with
tda8275, tda8275a or tda18271.
Signed-off-by: default avatarMichael Krufky <mkrufky@linuxtv.org>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@infradead.org>
parent 393bf557
This diff is collapsed.
...@@ -23,8 +23,7 @@ ...@@ -23,8 +23,7 @@
#if defined(CONFIG_TUNER_TDA8290) || (defined(CONFIG_TUNER_TDA8290_MODULE) && defined(MODULE)) #if defined(CONFIG_TUNER_TDA8290) || (defined(CONFIG_TUNER_TDA8290_MODULE) && defined(MODULE))
extern int tda8290_probe(struct tuner *t); extern int tda8290_probe(struct tuner *t);
extern int tda8290_attach(struct tuner *t); extern int tda829x_attach(struct tuner *t);
extern int tda8295_attach(struct tuner *t);
#else #else
static inline int tda8290_probe(struct tuner *t) static inline int tda8290_probe(struct tuner *t)
{ {
...@@ -32,14 +31,7 @@ static inline int tda8290_probe(struct tuner *t) ...@@ -32,14 +31,7 @@ static inline int tda8290_probe(struct tuner *t)
return -EINVAL; return -EINVAL;
} }
static inline int tda8290_attach(struct tuner *t) static inline int tda829x_attach(struct tuner *t)
{
printk(KERN_INFO "%s: not probed - driver disabled by Kconfig\n",
__FUNCTION__);
return -EINVAL;
}
static inline int tda8295_attach(struct tuner *t)
{ {
printk(KERN_INFO "%s: not probed - driver disabled by Kconfig\n", printk(KERN_INFO "%s: not probed - driver disabled by Kconfig\n",
__FUNCTION__); __FUNCTION__);
......
...@@ -295,13 +295,9 @@ static void set_type(struct i2c_client *c, unsigned int type, ...@@ -295,13 +295,9 @@ static void set_type(struct i2c_client *c, unsigned int type,
microtune_attach(&t->fe, t->i2c.adapter, t->i2c.addr); microtune_attach(&t->fe, t->i2c.adapter, t->i2c.addr);
break; break;
case TUNER_PHILIPS_TDA8290: case TUNER_PHILIPS_TDA8290:
{
tda8290_attach(t);
break;
}
case TUNER_PHILIPS_TDA8295: case TUNER_PHILIPS_TDA8295:
{ {
tda8295_attach(t); tda829x_attach(t);
break; break;
} }
case TUNER_TEA5767: case TUNER_TEA5767:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment