From 72459008a1643c4804ee6688426d7c29a66a545b Mon Sep 17 00:00:00 2001 From: Michael Krufky Date: Sun, 16 Dec 2007 17:27:23 -0500 Subject: tuner: add set_config to struct analog_tuner_ops From: Michael Krufky Signed-off-by: Michael Krufky --- linux/drivers/media/video/tuner-driver.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'linux/drivers/media/video/tuner-driver.h') diff --git a/linux/drivers/media/video/tuner-driver.h b/linux/drivers/media/video/tuner-driver.h index 65ced4350..7f43dc68a 100644 --- a/linux/drivers/media/video/tuner-driver.h +++ b/linux/drivers/media/video/tuner-driver.h @@ -45,6 +45,9 @@ struct analog_tuner_ops { void (*standby)(struct dvb_frontend *fe); void (*release)(struct dvb_frontend *fe); int (*i2c_gate_ctrl)(struct dvb_frontend *fe, int enable); + + /** This is to allow setting tuner-specific configuration */ + int (*set_config)(struct dvb_frontend *fe, void *priv_cfg); }; struct tuner { -- cgit v1.2.3 From e204914b6924b0eda3d4a8adbe8334c5ed27d457 Mon Sep 17 00:00:00 2001 From: Michael Krufky Date: Sun, 16 Dec 2007 17:53:32 -0500 Subject: tuner: convert tda9887 to use TUNER_SET_CONFIG From: Michael Krufky Use TUNER_SET_CONFIG to set configuration in tda9887's private state structure, rather than storing tda9887-specific configuration within struct tuner. Update handling of TUNER_SET_CONFIG by tuner-core, to call &t->fe.ops.analog_demod_ops rather than &t->fe.ops.tuner_ops analog_demod_ops.set_config passes the request to tuner_ops.set_config, so this does not break other drivers. Signed-off-by: Michael Krufky --- linux/drivers/media/video/tuner-driver.h | 3 --- 1 file changed, 3 deletions(-) (limited to 'linux/drivers/media/video/tuner-driver.h') diff --git a/linux/drivers/media/video/tuner-driver.h b/linux/drivers/media/video/tuner-driver.h index 7f43dc68a..417753b7c 100644 --- a/linux/drivers/media/video/tuner-driver.h +++ b/linux/drivers/media/video/tuner-driver.h @@ -69,9 +69,6 @@ struct tuner { struct dvb_frontend fe; - /* used by tda9887 */ - unsigned int tda9887_config; - unsigned int config; int (*tuner_callback) (void *dev, int command,int arg); }; -- cgit v1.2.3 From 792fe12a080524a1a417780cc115efe7384a3223 Mon Sep 17 00:00:00 2001 From: Michael Krufky Date: Sun, 16 Dec 2007 20:02:26 -0500 Subject: tuner: remove struct tuner from tuner-driver.h From: Michael Krufky struct tuner holds state for tuner-core, only -- move it into tuner-core.c Signed-off-by: Michael Krufky --- linux/drivers/media/video/tuner-driver.h | 23 ----------------------- 1 file changed, 23 deletions(-) (limited to 'linux/drivers/media/video/tuner-driver.h') diff --git a/linux/drivers/media/video/tuner-driver.h b/linux/drivers/media/video/tuner-driver.h index 417753b7c..7b1adfaf7 100644 --- a/linux/drivers/media/video/tuner-driver.h +++ b/linux/drivers/media/video/tuner-driver.h @@ -50,27 +50,4 @@ struct analog_tuner_ops { int (*set_config)(struct dvb_frontend *fe, void *priv_cfg); }; -struct tuner { - /* device */ - struct i2c_client *i2c; - struct list_head list; /* list of tuners */ - - unsigned int type; /* chip type */ - - unsigned int mode; - unsigned int mode_mask; /* Combination of allowable modes */ - - unsigned int tv_freq; /* keep track of the current settings */ - unsigned int radio_freq; - unsigned int audmode; - v4l2_std_id std; - - int using_v4l2; - - struct dvb_frontend fe; - - unsigned int config; - int (*tuner_callback) (void *dev, int command,int arg); -}; - #endif /* __TUNER_DRIVER_H__ */ -- cgit v1.2.3 From a5484362451f73f18dafd3dbcf9fedac5ed07ee4 Mon Sep 17 00:00:00 2001 From: Michael Krufky Date: Sun, 16 Dec 2007 23:21:08 -0500 Subject: tuner: remove unneeded #includes from tuner-driver.h From: Michael Krufky Signed-off-by: Michael Krufky --- linux/drivers/media/video/tuner-driver.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'linux/drivers/media/video/tuner-driver.h') diff --git a/linux/drivers/media/video/tuner-driver.h b/linux/drivers/media/video/tuner-driver.h index 7b1adfaf7..5eaa30ccb 100644 --- a/linux/drivers/media/video/tuner-driver.h +++ b/linux/drivers/media/video/tuner-driver.h @@ -22,8 +22,6 @@ #ifndef __TUNER_DRIVER_H__ #define __TUNER_DRIVER_H__ -#include -#include #include "dvb_frontend.h" extern unsigned const int tuner_count; -- cgit v1.2.3