summaryrefslogtreecommitdiff
path: root/linux
diff options
context:
space:
mode:
authorMichael Krufky <mkrufky@linuxtv.org>2007-12-09 11:52:51 -0500
committerMichael Krufky <mkrufky@linuxtv.org>2007-12-09 11:52:51 -0500
commit446475ffbe175d4c8c7cd071681b0c2ea1385650 (patch)
treefae69ecdc13afb23943f618d7e937c02b2163abb /linux
parent1eb95e84c755878770c7a55f8fc226dd63170813 (diff)
downloadmediapointer-dvb-s2-446475ffbe175d4c8c7cd071681b0c2ea1385650.tar.gz
mediapointer-dvb-s2-446475ffbe175d4c8c7cd071681b0c2ea1385650.tar.bz2
tuner: add struct analog_demod_info to struct analog_tuner_ops
From: Michael Krufky <mkrufky@linuxtv.org> Store the analog demodulator name in fe.ops.analog_demod_ops.info.name Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Diffstat (limited to 'linux')
-rw-r--r--linux/drivers/media/video/tda8290.c6
-rw-r--r--linux/drivers/media/video/tda9887.c3
-rw-r--r--linux/drivers/media/video/tuner-core.c3
-rw-r--r--linux/drivers/media/video/tuner-driver.h7
4 files changed, 19 insertions, 0 deletions
diff --git a/linux/drivers/media/video/tda8290.c b/linux/drivers/media/video/tda8290.c
index 9bb37ed14..de663918a 100644
--- a/linux/drivers/media/video/tda8290.c
+++ b/linux/drivers/media/video/tda8290.c
@@ -662,6 +662,9 @@ static int tda8295_probe(struct tuner_i2c_props *i2c_props)
}
static struct analog_tuner_ops tda8290_tuner_ops = {
+ .info = {
+ .name = "TDA8290",
+ },
.set_params = tda8290_set_params,
.has_signal = tda8290_has_signal,
.standby = tda8290_standby,
@@ -670,6 +673,9 @@ static struct analog_tuner_ops tda8290_tuner_ops = {
};
static struct analog_tuner_ops tda8295_tuner_ops = {
+ .info = {
+ .name = "TDA8295",
+ },
.set_params = tda8295_set_params,
.has_signal = tda8295_has_signal,
.standby = tda8295_standby,
diff --git a/linux/drivers/media/video/tda9887.c b/linux/drivers/media/video/tda9887.c
index 965c9fe81..bd4173e41 100644
--- a/linux/drivers/media/video/tda9887.c
+++ b/linux/drivers/media/video/tda9887.c
@@ -647,6 +647,9 @@ static void tda9887_release(struct dvb_frontend *fe)
}
static struct analog_tuner_ops tda9887_tuner_ops = {
+ .info = {
+ .name = "TDA9887",
+ },
.set_params = tda9887_set_params,
.standby = tda9887_standby,
.tuner_status = tda9887_tuner_status,
diff --git a/linux/drivers/media/video/tuner-core.c b/linux/drivers/media/video/tuner-core.c
index 0d2648e27..3cbf47a7a 100644
--- a/linux/drivers/media/video/tuner-core.c
+++ b/linux/drivers/media/video/tuner-core.c
@@ -439,6 +439,9 @@ static void set_type(struct i2c_client *c, unsigned int type,
t->fe.ops.analog_demod_ops = &tuner_core_ops;
t->fe.analog_demod_priv = t;
+ } else {
+ strlcpy(t->i2c->name, ops->info.name,
+ sizeof(t->i2c->name));
}
tuner_dbg("type set to %s\n", t->i2c->name);
diff --git a/linux/drivers/media/video/tuner-driver.h b/linux/drivers/media/video/tuner-driver.h
index a215161d0..c245f501a 100644
--- a/linux/drivers/media/video/tuner-driver.h
+++ b/linux/drivers/media/video/tuner-driver.h
@@ -28,7 +28,14 @@
extern unsigned const int tuner_count;
+struct analog_demod_info {
+ char name[128];
+};
+
struct analog_tuner_ops {
+
+ struct analog_demod_info info;
+
void (*set_params)(struct dvb_frontend *fe,
struct analog_parameters *params);
int (*has_signal)(struct dvb_frontend *fe);