]>
Commit | Line | Data |
---|---|---|
1ae2c589 MP |
1 | /** |
2 | * Driver for Sharp IX2505V (marked B0017) DVB-S silicon tuner | |
3 | * | |
4 | * Copyright (C) 2010 Malcolm Priestley | |
5 | * | |
6 | * This program is free software; you can redistribute it and/or modify | |
7 | * it under the terms of the GNU General Public License Version 2, as | |
8 | * published by the Free Software Foundation. | |
9 | * | |
10 | * This program is distributed in the hope that it will be useful, | |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
13 | * GNU General Public License for more details. | |
14 | * | |
15 | * You should have received a copy of the GNU General Public License | |
16 | * along with this program; if not, write to the Free Software | |
17 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | |
18 | */ | |
19 | ||
20 | #ifndef DVB_IX2505V_H | |
21 | #define DVB_IX2505V_H | |
22 | ||
23 | #include <linux/i2c.h> | |
24 | #include "dvb_frontend.h" | |
25 | ||
26 | /** | |
27 | * Attach a ix2505v tuner to the supplied frontend structure. | |
28 | * | |
29 | * @param fe Frontend to attach to. | |
30 | * @param config ix2505v_config structure | |
31 | * @return FE pointer on success, NULL on failure. | |
32 | */ | |
33 | ||
34 | struct ix2505v_config { | |
35 | u8 tuner_address; | |
36 | ||
37 | /*Baseband AMP gain control 0/1=0dB(default) 2=-2bB 3=-4dB */ | |
38 | u8 tuner_gain; | |
39 | ||
40 | /*Charge pump output +/- 0=120 1=260 2=555 3=1200(default) */ | |
41 | u8 tuner_chargepump; | |
42 | ||
43 | /* delay after tune */ | |
44 | int min_delay_ms; | |
45 | ||
46 | /* disables reads*/ | |
47 | u8 tuner_write_only; | |
48 | ||
49 | }; | |
50 | ||
9b174527 | 51 | #if IS_REACHABLE(CONFIG_DVB_IX2505V) |
1ae2c589 MP |
52 | extern struct dvb_frontend *ix2505v_attach(struct dvb_frontend *fe, |
53 | const struct ix2505v_config *config, struct i2c_adapter *i2c); | |
54 | #else | |
55 | static inline struct dvb_frontend *ix2505v_attach(struct dvb_frontend *fe, | |
56 | const struct ix2505v_config *config, struct i2c_adapter *i2c) | |
57 | { | |
58 | printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__); | |
59 | return NULL; | |
60 | } | |
61 | #endif | |
62 | ||
63 | #endif /* DVB_IX2505V_H */ |