diff options
author | Michael Krufky <mkrufky@linuxtv.org> | 2007-12-09 11:52:51 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-01-25 16:03:28 -0500 |
commit | a55db8cd7f8a107f3abcb4c803b1873b2be63663 (patch) | |
tree | 0198ed8bcbddcaa1f2f8fe41f13ec9735e180176 /drivers | |
parent | ab1660503ac3af7febfcf987648509b484d4feda (diff) |
V4L/DVB (6786): tuner: add struct analog_demod_info to struct analog_tuner_ops
Store the analog demodulator name in fe.ops.analog_demod_ops.info.name
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/media/video/tda8290.c | 6 | ||||
-rw-r--r-- | drivers/media/video/tda9887.c | 3 | ||||
-rw-r--r-- | drivers/media/video/tuner-core.c | 3 | ||||
-rw-r--r-- | drivers/media/video/tuner-driver.h | 7 |
4 files changed, 19 insertions, 0 deletions
diff --git a/drivers/media/video/tda8290.c b/drivers/media/video/tda8290.c index d0d13bc61250..403f96f998ec 100644 --- a/drivers/media/video/tda8290.c +++ b/drivers/media/video/tda8290.c | |||
@@ -636,6 +636,9 @@ static int tda8295_probe(struct tuner_i2c_props *i2c_props) | |||
636 | } | 636 | } |
637 | 637 | ||
638 | static struct analog_tuner_ops tda8290_tuner_ops = { | 638 | static struct analog_tuner_ops tda8290_tuner_ops = { |
639 | .info = { | ||
640 | .name = "TDA8290", | ||
641 | }, | ||
639 | .set_params = tda8290_set_params, | 642 | .set_params = tda8290_set_params, |
640 | .has_signal = tda8290_has_signal, | 643 | .has_signal = tda8290_has_signal, |
641 | .standby = tda8290_standby, | 644 | .standby = tda8290_standby, |
@@ -644,6 +647,9 @@ static struct analog_tuner_ops tda8290_tuner_ops = { | |||
644 | }; | 647 | }; |
645 | 648 | ||
646 | static struct analog_tuner_ops tda8295_tuner_ops = { | 649 | static struct analog_tuner_ops tda8295_tuner_ops = { |
650 | .info = { | ||
651 | .name = "TDA8295", | ||
652 | }, | ||
647 | .set_params = tda8295_set_params, | 653 | .set_params = tda8295_set_params, |
648 | .has_signal = tda8295_has_signal, | 654 | .has_signal = tda8295_has_signal, |
649 | .standby = tda8295_standby, | 655 | .standby = tda8295_standby, |
diff --git a/drivers/media/video/tda9887.c b/drivers/media/video/tda9887.c index 98d45c4912bd..8a95f097ba23 100644 --- a/drivers/media/video/tda9887.c +++ b/drivers/media/video/tda9887.c | |||
@@ -636,6 +636,9 @@ static void tda9887_release(struct dvb_frontend *fe) | |||
636 | } | 636 | } |
637 | 637 | ||
638 | static struct analog_tuner_ops tda9887_tuner_ops = { | 638 | static struct analog_tuner_ops tda9887_tuner_ops = { |
639 | .info = { | ||
640 | .name = "TDA9887", | ||
641 | }, | ||
639 | .set_params = tda9887_set_params, | 642 | .set_params = tda9887_set_params, |
640 | .standby = tda9887_standby, | 643 | .standby = tda9887_standby, |
641 | .tuner_status = tda9887_tuner_status, | 644 | .tuner_status = tda9887_tuner_status, |
diff --git a/drivers/media/video/tuner-core.c b/drivers/media/video/tuner-core.c index 0cc190761e24..59e67c925758 100644 --- a/drivers/media/video/tuner-core.c +++ b/drivers/media/video/tuner-core.c | |||
@@ -410,6 +410,9 @@ static void set_type(struct i2c_client *c, unsigned int type, | |||
410 | 410 | ||
411 | t->fe.ops.analog_demod_ops = &tuner_core_ops; | 411 | t->fe.ops.analog_demod_ops = &tuner_core_ops; |
412 | t->fe.analog_demod_priv = t; | 412 | t->fe.analog_demod_priv = t; |
413 | } else { | ||
414 | strlcpy(t->i2c->name, ops->info.name, | ||
415 | sizeof(t->i2c->name)); | ||
413 | } | 416 | } |
414 | 417 | ||
415 | tuner_dbg("type set to %s\n", t->i2c->name); | 418 | tuner_dbg("type set to %s\n", t->i2c->name); |
diff --git a/drivers/media/video/tuner-driver.h b/drivers/media/video/tuner-driver.h index a215161d0241..c245f501a319 100644 --- a/drivers/media/video/tuner-driver.h +++ b/drivers/media/video/tuner-driver.h | |||
@@ -28,7 +28,14 @@ | |||
28 | 28 | ||
29 | extern unsigned const int tuner_count; | 29 | extern unsigned const int tuner_count; |
30 | 30 | ||
31 | struct analog_demod_info { | ||
32 | char name[128]; | ||
33 | }; | ||
34 | |||
31 | struct analog_tuner_ops { | 35 | struct analog_tuner_ops { |
36 | |||
37 | struct analog_demod_info info; | ||
38 | |||
32 | void (*set_params)(struct dvb_frontend *fe, | 39 | void (*set_params)(struct dvb_frontend *fe, |
33 | struct analog_parameters *params); | 40 | struct analog_parameters *params); |
34 | int (*has_signal)(struct dvb_frontend *fe); | 41 | int (*has_signal)(struct dvb_frontend *fe); |