diff options
author | Michael Krufky <mkrufky@linuxtv.org> | 2007-06-06 16:10:39 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2007-07-18 14:24:02 -0300 |
commit | 7a91a80a0d1a0a83a94e773ec6245b31b7c4ceed (patch) | |
tree | d524d57405944826d4a6c375af1a77bab22546a2 /include/media/tuner.h | |
parent | 018ec5440b4994f560cdde78be6fb10d7ab370d7 (diff) | |
download | linux-7a91a80a0d1a0a83a94e773ec6245b31b7c4ceed.tar.gz linux-7a91a80a0d1a0a83a94e773ec6245b31b7c4ceed.tar.bz2 linux-7a91a80a0d1a0a83a94e773ec6245b31b7c4ceed.zip |
V4L/DVB (5753): Tuner: create struct tuner_operations
Move tuner callback function pointers out of struct tuner, into
struct tuner_operations.
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'include/media/tuner.h')
-rw-r--r-- | include/media/tuner.h | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/include/media/tuner.h b/include/media/tuner.h index da821a027e76..88eaf8930203 100644 --- a/include/media/tuner.h +++ b/include/media/tuner.h @@ -183,6 +183,17 @@ struct tuner_setup { int (*tuner_callback) (void *dev, int command,int arg); }; +struct tuner_operations { + void (*set_tv_freq)(struct i2c_client *c, unsigned int freq); + void (*set_radio_freq)(struct i2c_client *c, unsigned int freq); + int (*has_signal)(struct i2c_client *c); + int (*is_stereo)(struct i2c_client *c); + int (*get_afc)(struct i2c_client *c); + void (*tuner_status)(struct i2c_client *c); + void (*standby)(struct i2c_client *c); + void (*release)(struct i2c_client *c); +}; + struct tuner { /* device */ struct i2c_client i2c; @@ -207,15 +218,7 @@ struct tuner { unsigned int config; int (*tuner_callback) (void *dev, int command,int arg); - /* function ptrs */ - void (*set_tv_freq)(struct i2c_client *c, unsigned int freq); - void (*set_radio_freq)(struct i2c_client *c, unsigned int freq); - int (*has_signal)(struct i2c_client *c); - int (*is_stereo)(struct i2c_client *c); - int (*get_afc)(struct i2c_client *c); - void (*tuner_status)(struct i2c_client *c); - void (*standby)(struct i2c_client *c); - void (*release)(struct i2c_client *c); + struct tuner_operations ops; }; extern unsigned const int tuner_count; |