diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-10-28 12:35:11 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-10-28 12:35:11 -0400 |
commit | 0851668fdd97e526b2a41f794b785c204dd3d3e0 (patch) | |
tree | 4ef7c20a8be8393006c6fe9627eb29dd30877d61 /drivers/media/dvb/frontends/s5h1432.h | |
parent | 00ebb6382b8d9c7c15b5f8ad230670d8161d38dd (diff) | |
parent | 7655e594945289b418af39f6669fea4666a7b520 (diff) |
Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6
* 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (505 commits)
[media] af9015: Fix max I2C message size when used with tda18271
[media] IR: initialize ir_raw_event in few more drivers
[media] Guard a divide in v4l1 compat layer
[media] imon: fix nomouse modprobe option
[media] imon: remove redundant change_protocol call
[media] imon: fix my egregious brown paper bag w/rdev/idev split
[media] cafe_ccic: Configure ov7670 correctly
[media] ov7670: allow configuration of image size, clock speed, and I/O method
[media] af9015: support for DigitalNow TinyTwin v3 [1f4d:9016]
[media] af9015: map DigitalNow TinyTwin v2 remote
[media] DigitalNow TinyTwin remote controller
[media] af9015: RC fixes and improvements
videodev2.h.xml: Update to reflect the latest changes at videodev2.h
[media] v4l: document new Bayer and monochrome pixel formats
[media] DocBook/v4l: Add missing formats used on gspca cpia1 and sn9c2028
[media] firedtv: add parameter to fake ca_system_ids in CA_INFO
[media] tm6000: fix a macro coding style issue
tm6000: Remove some ugly debug code
[media] Nova-S-Plus audio line input
[media] [RFC,1/1] V4L2: Use new CAP bits in existing RDS capable drivers
...
Diffstat (limited to 'drivers/media/dvb/frontends/s5h1432.h')
-rw-r--r-- | drivers/media/dvb/frontends/s5h1432.h | 91 |
1 files changed, 91 insertions, 0 deletions
diff --git a/drivers/media/dvb/frontends/s5h1432.h b/drivers/media/dvb/frontends/s5h1432.h new file mode 100644 index 000000000000..b57438c32546 --- /dev/null +++ b/drivers/media/dvb/frontends/s5h1432.h | |||
@@ -0,0 +1,91 @@ | |||
1 | /* | ||
2 | * Samsung s5h1432 VSB/QAM demodulator driver | ||
3 | * | ||
4 | * Copyright (C) 2009 Bill Liu <Bill.Liu@Conexant.com> | ||
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 as published by | ||
8 | * the Free Software Foundation; either version 2 of the License, or | ||
9 | * (at your option) any later version. | ||
10 | * | ||
11 | * This program is distributed in the hope that it will be useful, | ||
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
14 | * GNU General Public License for more details. | ||
15 | * | ||
16 | * You should have received a copy of the GNU General Public License | ||
17 | * along with this program; if not, write to the Free Software | ||
18 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
19 | * | ||
20 | */ | ||
21 | |||
22 | #ifndef __S5H1432_H__ | ||
23 | #define __S5H1432_H__ | ||
24 | |||
25 | #include <linux/dvb/frontend.h> | ||
26 | |||
27 | #define S5H1432_I2C_TOP_ADDR (0x02 >> 1) | ||
28 | |||
29 | #define TAIWAN_HI_IF_FREQ_44_MHZ 44000000 | ||
30 | #define EUROPE_HI_IF_FREQ_36_MHZ 36000000 | ||
31 | #define IF_FREQ_6_MHZ 6000000 | ||
32 | #define IF_FREQ_3point3_MHZ 3300000 | ||
33 | #define IF_FREQ_3point5_MHZ 3500000 | ||
34 | #define IF_FREQ_4_MHZ 4000000 | ||
35 | |||
36 | struct s5h1432_config { | ||
37 | |||
38 | /* serial/parallel output */ | ||
39 | #define S5H1432_PARALLEL_OUTPUT 0 | ||
40 | #define S5H1432_SERIAL_OUTPUT 1 | ||
41 | u8 output_mode; | ||
42 | |||
43 | /* GPIO Setting */ | ||
44 | #define S5H1432_GPIO_OFF 0 | ||
45 | #define S5H1432_GPIO_ON 1 | ||
46 | u8 gpio; | ||
47 | |||
48 | /* MPEG signal timing */ | ||
49 | #define S5H1432_MPEGTIMING_CONTINOUS_INVERTING_CLOCK 0 | ||
50 | #define S5H1432_MPEGTIMING_CONTINOUS_NONINVERTING_CLOCK 1 | ||
51 | #define S5H1432_MPEGTIMING_NONCONTINOUS_INVERTING_CLOCK 2 | ||
52 | #define S5H1432_MPEGTIMING_NONCONTINOUS_NONINVERTING_CLOCK 3 | ||
53 | u16 mpeg_timing; | ||
54 | |||
55 | /* IF Freq for QAM and VSB in KHz */ | ||
56 | #define S5H1432_IF_3250 3250 | ||
57 | #define S5H1432_IF_3500 3500 | ||
58 | #define S5H1432_IF_4000 4000 | ||
59 | #define S5H1432_IF_5380 5380 | ||
60 | #define S5H1432_IF_44000 44000 | ||
61 | #define S5H1432_VSB_IF_DEFAULT s5h1432_IF_44000 | ||
62 | #define S5H1432_QAM_IF_DEFAULT s5h1432_IF_44000 | ||
63 | u16 qam_if; | ||
64 | u16 vsb_if; | ||
65 | |||
66 | /* Spectral Inversion */ | ||
67 | #define S5H1432_INVERSION_OFF 0 | ||
68 | #define S5H1432_INVERSION_ON 1 | ||
69 | u8 inversion; | ||
70 | |||
71 | /* Return lock status based on tuner lock, or demod lock */ | ||
72 | #define S5H1432_TUNERLOCKING 0 | ||
73 | #define S5H1432_DEMODLOCKING 1 | ||
74 | u8 status_mode; | ||
75 | }; | ||
76 | |||
77 | #if defined(CONFIG_DVB_S5H1432) || \ | ||
78 | (defined(CONFIG_DVB_S5H1432_MODULE) && defined(MODULE)) | ||
79 | extern struct dvb_frontend *s5h1432_attach(const struct s5h1432_config *config, | ||
80 | struct i2c_adapter *i2c); | ||
81 | #else | ||
82 | static inline struct dvb_frontend *s5h1432_attach(const struct s5h1432_config | ||
83 | *config, | ||
84 | struct i2c_adapter *i2c) | ||
85 | { | ||
86 | printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__); | ||
87 | return NULL; | ||
88 | } | ||
89 | #endif /* CONFIG_DVB_s5h1432 */ | ||
90 | |||
91 | #endif /* __s5h1432_H__ */ | ||