diff options
author | Hartmut Hackmann <hartmut.hackmann@t-online.de> | 2007-04-27 11:31:12 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2007-04-27 14:43:31 -0400 |
commit | de956c1e0f89413a3837b642d592e2dff3e3eb78 (patch) | |
tree | 71f803d3854d497e63dbe728695250b16c0e0b18 /include/media/tuner.h | |
parent | b8195946228c749702dfe5995b98516ea4b04cdc (diff) |
V4L/DVB (5313): Added a config entry and a gpio function pointer to tuner struct
These entries mainly are to support configurations of the tda827x
silicon tuner with a preamplifier.
The values can be set throgh the attach inform or through
the extended TUNER_SET_TYPE_ADDR client call. The function pointer
will only be updated if the parameter is not NULL.
Since a typecast is necessary to set the pointer, i added a typedef for
this pointer (tuner_gpio_func_t) in tuner.h
Signed-off-by: Hartmut Hackmann <hartmut.hackmann@t-online.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'include/media/tuner.h')
-rw-r--r-- | include/media/tuner.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/media/tuner.h b/include/media/tuner.h index 99acf847365c..fe567129b22b 100644 --- a/include/media/tuner.h +++ b/include/media/tuner.h | |||
@@ -173,10 +173,15 @@ enum tuner_mode { | |||
173 | when the tuner is set to TV mode. | 173 | when the tuner is set to TV mode. |
174 | */ | 174 | */ |
175 | 175 | ||
176 | /* allows to access the GPIOs of the host (pci bridge) */ | ||
177 | typedef void (*tuner_gpio_func_t) (void *dev, int bit_no,int value); | ||
178 | |||
176 | struct tuner_setup { | 179 | struct tuner_setup { |
177 | unsigned short addr; /* I2C address */ | 180 | unsigned short addr; /* I2C address */ |
178 | unsigned int type; /* Tuner type */ | 181 | unsigned int type; /* Tuner type */ |
179 | unsigned int mode_mask; /* Allowed tuner modes */ | 182 | unsigned int mode_mask; /* Allowed tuner modes */ |
183 | unsigned int config; /* configuraion for more complex tuners */ | ||
184 | tuner_gpio_func_t gpio_func; | ||
180 | }; | 185 | }; |
181 | 186 | ||
182 | struct tuner { | 187 | struct tuner { |
@@ -210,6 +215,8 @@ struct tuner { | |||
210 | unsigned char tda827x_addr; | 215 | unsigned char tda827x_addr; |
211 | unsigned char tda827x_ver; | 216 | unsigned char tda827x_ver; |
212 | unsigned int sgIF; | 217 | unsigned int sgIF; |
218 | unsigned int config; | ||
219 | tuner_gpio_func_t gpio_func; | ||
213 | 220 | ||
214 | /* function ptrs */ | 221 | /* function ptrs */ |
215 | void (*set_tv_freq)(struct i2c_client *c, unsigned int freq); | 222 | void (*set_tv_freq)(struct i2c_client *c, unsigned int freq); |