akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 1 | /* |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 2 | em28xx-cards.c - driver for Empia EM2800/EM2820/2840 USB |
| 3 | video capture devices |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 4 | |
Mauro Carvalho Chehab | f7abcd3 | 2005-11-08 21:38:25 -0800 | [diff] [blame] | 5 | Copyright (C) 2005 Ludovico Cavedon <cavedon@sssup.it> |
| 6 | Markus Rechberger <mrechberger@gmail.com> |
Mauro Carvalho Chehab | 2e7c6dc | 2006-04-03 07:53:40 -0300 | [diff] [blame] | 7 | Mauro Carvalho Chehab <mchehab@infradead.org> |
Mauro Carvalho Chehab | f7abcd3 | 2005-11-08 21:38:25 -0800 | [diff] [blame] | 8 | Sascha Sommer <saschasommer@freenet.de> |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 9 | |
| 10 | This program is free software; you can redistribute it and/or modify |
| 11 | it under the terms of the GNU General Public License as published by |
| 12 | the Free Software Foundation; either version 2 of the License, or |
| 13 | (at your option) any later version. |
| 14 | |
| 15 | This program is distributed in the hope that it will be useful, |
| 16 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 17 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 18 | GNU General Public License for more details. |
| 19 | |
| 20 | You should have received a copy of the GNU General Public License |
| 21 | along with this program; if not, write to the Free Software |
| 22 | Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
| 23 | */ |
| 24 | |
| 25 | #include <linux/init.h> |
| 26 | #include <linux/module.h> |
Tejun Heo | 5a0e3ad | 2010-03-24 17:04:11 +0900 | [diff] [blame] | 27 | #include <linux/slab.h> |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 28 | #include <linux/delay.h> |
| 29 | #include <linux/i2c.h> |
| 30 | #include <linux/usb.h> |
| 31 | #include <media/tuner.h> |
Hans Verkuil | 2474ed4 | 2006-03-19 12:35:57 -0300 | [diff] [blame] | 32 | #include <media/msp3400.h> |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 33 | #include <media/saa7115.h> |
| 34 | #include <media/tvp5150.h> |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 35 | #include <media/tvaudio.h> |
| 36 | #include <media/i2c-addr.h> |
Mauro Carvalho Chehab | 1f6173e | 2005-11-08 21:37:16 -0800 | [diff] [blame] | 37 | #include <media/tveeprom.h> |
Mauro Carvalho Chehab | 9bb13a6 | 2006-01-09 15:25:37 -0200 | [diff] [blame] | 38 | #include <media/v4l2-common.h> |
Hans Verkuil | 38f9d30 | 2008-07-23 05:09:15 -0300 | [diff] [blame] | 39 | #include <media/v4l2-chip-ident.h> |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 40 | |
Mauro Carvalho Chehab | f7abcd3 | 2005-11-08 21:38:25 -0800 | [diff] [blame] | 41 | #include "em28xx.h" |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 42 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 43 | #define DRIVER_NAME "em28xx" |
| 44 | |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 45 | static int tuner = -1; |
| 46 | module_param(tuner, int, 0444); |
| 47 | MODULE_PARM_DESC(tuner, "tuner type"); |
| 48 | |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 49 | static unsigned int disable_ir; |
| 50 | module_param(disable_ir, int, 0444); |
| 51 | MODULE_PARM_DESC(disable_ir, "disable infrared remote support"); |
| 52 | |
Devin Heitmueller | e2a1b79 | 2009-05-27 23:44:10 -0300 | [diff] [blame] | 53 | static unsigned int disable_usb_speed_check; |
| 54 | module_param(disable_usb_speed_check, int, 0444); |
| 55 | MODULE_PARM_DESC(disable_usb_speed_check, |
| 56 | "override min bandwidth requirement of 480M bps"); |
| 57 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 58 | static unsigned int card[] = {[0 ... (EM28XX_MAXBOARDS - 1)] = UNSET }; |
| 59 | module_param_array(card, int, NULL, 0444); |
| 60 | MODULE_PARM_DESC(card, "card type"); |
| 61 | |
| 62 | /* Bitmask marking allocated devices from 0 to EM28XX_MAXBOARDS */ |
| 63 | static unsigned long em28xx_devused; |
| 64 | |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 65 | struct em28xx_hash_table { |
| 66 | unsigned long hash; |
| 67 | unsigned int model; |
| 68 | unsigned int tuner; |
| 69 | }; |
| 70 | |
Mauro Carvalho Chehab | 0ec202d | 2008-11-25 13:16:13 -0300 | [diff] [blame] | 71 | /* |
| 72 | * Reset sequences for analog/digital modes |
| 73 | */ |
| 74 | |
| 75 | /* Reset for the most [analog] boards */ |
| 76 | static struct em28xx_reg_seq default_analog[] = { |
| 77 | {EM28XX_R08_GPIO, 0x6d, ~EM_GPIO_4, 10}, |
| 78 | { -1, -1, -1, -1}, |
| 79 | }; |
| 80 | |
| 81 | /* Reset for the most [digital] boards */ |
| 82 | static struct em28xx_reg_seq default_digital[] = { |
| 83 | {EM28XX_R08_GPIO, 0x6e, ~EM_GPIO_4, 10}, |
| 84 | { -1, -1, -1, -1}, |
| 85 | }; |
| 86 | |
| 87 | /* Board Hauppauge WinTV HVR 900 analog */ |
| 88 | static struct em28xx_reg_seq hauppauge_wintv_hvr_900_analog[] = { |
| 89 | {EM28XX_R08_GPIO, 0x2d, ~EM_GPIO_4, 10}, |
| 90 | {0x05, 0xff, 0x10, 10}, |
| 91 | { -1, -1, -1, -1}, |
| 92 | }; |
| 93 | |
| 94 | /* Board Hauppauge WinTV HVR 900 digital */ |
| 95 | static struct em28xx_reg_seq hauppauge_wintv_hvr_900_digital[] = { |
| 96 | {EM28XX_R08_GPIO, 0x2e, ~EM_GPIO_4, 10}, |
| 97 | {EM2880_R04_GPO, 0x04, 0x0f, 10}, |
| 98 | {EM2880_R04_GPO, 0x0c, 0x0f, 10}, |
| 99 | { -1, -1, -1, -1}, |
| 100 | }; |
| 101 | |
| 102 | /* Boards - EM2880 MSI DIGIVOX AD and EM2880_BOARD_MSI_DIGIVOX_AD_II */ |
| 103 | static struct em28xx_reg_seq em2880_msi_digivox_ad_analog[] = { |
| 104 | {EM28XX_R08_GPIO, 0x69, ~EM_GPIO_4, 10}, |
| 105 | { -1, -1, -1, -1}, |
| 106 | }; |
| 107 | |
| 108 | /* Boards - EM2880 MSI DIGIVOX AD and EM2880_BOARD_MSI_DIGIVOX_AD_II */ |
Mauro Carvalho Chehab | 0ec202d | 2008-11-25 13:16:13 -0300 | [diff] [blame] | 109 | |
| 110 | /* Board - EM2870 Kworld 355u |
| 111 | Analog - No input analog */ |
Mauro Carvalho Chehab | 0ec202d | 2008-11-25 13:16:13 -0300 | [diff] [blame] | 112 | |
Franklin Meng | d7de5d8 | 2009-06-06 17:05:02 -0300 | [diff] [blame] | 113 | /* Board - EM2882 Kworld 315U digital */ |
| 114 | static struct em28xx_reg_seq em2882_kworld_315u_digital[] = { |
| 115 | {EM28XX_R08_GPIO, 0xff, 0xff, 10}, |
| 116 | {EM28XX_R08_GPIO, 0xfe, 0xff, 10}, |
| 117 | {EM2880_R04_GPO, 0x04, 0xff, 10}, |
| 118 | {EM2880_R04_GPO, 0x0c, 0xff, 10}, |
| 119 | {EM28XX_R08_GPIO, 0x7e, 0xff, 10}, |
| 120 | { -1, -1, -1, -1}, |
| 121 | }; |
| 122 | |
| 123 | static struct em28xx_reg_seq em2882_kworld_315u_tuner_gpio[] = { |
| 124 | {EM2880_R04_GPO, 0x08, 0xff, 10}, |
| 125 | {EM2880_R04_GPO, 0x0c, 0xff, 10}, |
| 126 | {EM2880_R04_GPO, 0x08, 0xff, 10}, |
| 127 | {EM2880_R04_GPO, 0x0c, 0xff, 10}, |
| 128 | { -1, -1, -1, -1}, |
| 129 | }; |
| 130 | |
Robert Krakora | 6e7b9ea | 2009-01-18 21:59:34 -0300 | [diff] [blame] | 131 | static struct em28xx_reg_seq kworld_330u_analog[] = { |
| 132 | {EM28XX_R08_GPIO, 0x6d, ~EM_GPIO_4, 10}, |
| 133 | {EM2880_R04_GPO, 0x00, 0xff, 10}, |
| 134 | { -1, -1, -1, -1}, |
| 135 | }; |
| 136 | |
| 137 | static struct em28xx_reg_seq kworld_330u_digital[] = { |
| 138 | {EM28XX_R08_GPIO, 0x6e, ~EM_GPIO_4, 10}, |
| 139 | {EM2880_R04_GPO, 0x08, 0xff, 10}, |
| 140 | { -1, -1, -1, -1}, |
| 141 | }; |
| 142 | |
Devin Heitmueller | 1985922 | 2009-06-19 00:33:54 -0300 | [diff] [blame] | 143 | /* Evga inDtube |
| 144 | GPIO0 - Enable digital power (s5h1409) - low to enable |
| 145 | GPIO1 - Enable analog power (tvp5150/emp202) - low to enable |
| 146 | GPIO4 - xc3028 reset |
| 147 | GOP3 - s5h1409 reset |
| 148 | */ |
| 149 | static struct em28xx_reg_seq evga_indtube_analog[] = { |
| 150 | {EM28XX_R08_GPIO, 0x79, 0xff, 60}, |
| 151 | { -1, -1, -1, -1}, |
| 152 | }; |
| 153 | |
| 154 | static struct em28xx_reg_seq evga_indtube_digital[] = { |
| 155 | {EM28XX_R08_GPIO, 0x7a, 0xff, 1}, |
| 156 | {EM2880_R04_GPO, 0x04, 0xff, 10}, |
| 157 | {EM2880_R04_GPO, 0x0c, 0xff, 1}, |
| 158 | { -1, -1, -1, -1}, |
| 159 | }; |
| 160 | |
Jarod Wilson | 7e48b30 | 2010-03-07 17:55:43 -0300 | [diff] [blame] | 161 | /* |
| 162 | * KWorld PlusTV 340U and UB435-Q (ATSC) GPIOs map: |
| 163 | * EM_GPIO_0 - currently unknown |
| 164 | * EM_GPIO_1 - LED disable/enable (1 = off, 0 = on) |
| 165 | * EM_GPIO_2 - currently unknown |
| 166 | * EM_GPIO_3 - currently unknown |
| 167 | * EM_GPIO_4 - TDA18271HD/C1 tuner (1 = active, 0 = in reset) |
| 168 | * EM_GPIO_5 - LGDT3304 ATSC/QAM demod (1 = active, 0 = in reset) |
| 169 | * EM_GPIO_6 - currently unknown |
| 170 | * EM_GPIO_7 - currently unknown |
| 171 | */ |
| 172 | static struct em28xx_reg_seq kworld_a340_digital[] = { |
| 173 | {EM28XX_R08_GPIO, 0x6d, ~EM_GPIO_4, 10}, |
| 174 | { -1, -1, -1, -1}, |
| 175 | }; |
| 176 | |
Devin Heitmueller | d5b3ba9 | 2009-07-08 21:51:35 -0300 | [diff] [blame] | 177 | /* Pinnacle Hybrid Pro eb1a:2881 */ |
| 178 | static struct em28xx_reg_seq pinnacle_hybrid_pro_analog[] = { |
Devin Heitmueller | 4401044 | 2009-07-08 22:18:15 -0300 | [diff] [blame] | 179 | {EM28XX_R08_GPIO, 0xfd, ~EM_GPIO_4, 10}, |
Devin Heitmueller | d5b3ba9 | 2009-07-08 21:51:35 -0300 | [diff] [blame] | 180 | { -1, -1, -1, -1}, |
| 181 | }; |
| 182 | |
| 183 | static struct em28xx_reg_seq pinnacle_hybrid_pro_digital[] = { |
| 184 | {EM28XX_R08_GPIO, 0x6e, ~EM_GPIO_4, 10}, |
| 185 | {EM2880_R04_GPO, 0x04, 0xff, 100},/* zl10353 reset */ |
| 186 | {EM2880_R04_GPO, 0x0c, 0xff, 1}, |
| 187 | { -1, -1, -1, -1}, |
| 188 | }; |
| 189 | |
Michel Garnier | cec4e6c | 2010-10-16 14:42:01 -0300 | [diff] [blame^] | 190 | static struct em28xx_reg_seq terratec_cinergy_USB_XS_FR_analog[] = { |
| 191 | {EM28XX_R08_GPIO, 0x6d, ~EM_GPIO_4, 10}, |
| 192 | {EM2880_R04_GPO, 0x00, 0xff, 10}, |
| 193 | { -1, -1, -1, -1}, |
| 194 | }; |
| 195 | |
| 196 | static struct em28xx_reg_seq terratec_cinergy_USB_XS_FR_digital[] = { |
| 197 | {EM28XX_R08_GPIO, 0x6e, ~EM_GPIO_4, 10}, |
| 198 | {EM2880_R04_GPO, 0x08, 0xff, 10}, |
| 199 | { -1, -1, -1, -1}, |
| 200 | }; |
| 201 | |
Antti Palosaari | 285eb1a | 2009-09-15 14:42:13 -0300 | [diff] [blame] | 202 | /* eb1a:2868 Reddo DVB-C USB TV Box |
| 203 | GPIO4 - CU1216L NIM |
| 204 | Other GPIOs seems to be don't care. */ |
| 205 | static struct em28xx_reg_seq reddo_dvb_c_usb_box[] = { |
| 206 | {EM28XX_R08_GPIO, 0xfe, 0xff, 10}, |
| 207 | {EM28XX_R08_GPIO, 0xde, 0xff, 10}, |
| 208 | {EM28XX_R08_GPIO, 0xfe, 0xff, 10}, |
| 209 | {EM28XX_R08_GPIO, 0xff, 0xff, 10}, |
| 210 | {EM28XX_R08_GPIO, 0x7f, 0xff, 10}, |
| 211 | {EM28XX_R08_GPIO, 0x6f, 0xff, 10}, |
| 212 | {EM28XX_R08_GPIO, 0xff, 0xff, 10}, |
| 213 | {-1, -1, -1, -1}, |
| 214 | }; |
Devin Heitmueller | d5b3ba9 | 2009-07-08 21:51:35 -0300 | [diff] [blame] | 215 | |
Mauro Carvalho Chehab | 0ec202d | 2008-11-25 13:16:13 -0300 | [diff] [blame] | 216 | /* Callback for the most boards */ |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 217 | static struct em28xx_reg_seq default_tuner_gpio[] = { |
Mauro Carvalho Chehab | 0ec202d | 2008-11-25 13:16:13 -0300 | [diff] [blame] | 218 | {EM28XX_R08_GPIO, EM_GPIO_4, EM_GPIO_4, 10}, |
| 219 | {EM28XX_R08_GPIO, 0, EM_GPIO_4, 10}, |
| 220 | {EM28XX_R08_GPIO, EM_GPIO_4, EM_GPIO_4, 10}, |
| 221 | { -1, -1, -1, -1}, |
| 222 | }; |
| 223 | |
Vitaly Wool | 2bd1d9e | 2009-03-04 08:27:52 -0300 | [diff] [blame] | 224 | /* Mute/unmute */ |
| 225 | static struct em28xx_reg_seq compro_unmute_tv_gpio[] = { |
| 226 | {EM28XX_R08_GPIO, 5, 7, 10}, |
| 227 | { -1, -1, -1, -1}, |
| 228 | }; |
| 229 | |
| 230 | static struct em28xx_reg_seq compro_unmute_svid_gpio[] = { |
| 231 | {EM28XX_R08_GPIO, 4, 7, 10}, |
| 232 | { -1, -1, -1, -1}, |
| 233 | }; |
| 234 | |
| 235 | static struct em28xx_reg_seq compro_mute_gpio[] = { |
| 236 | {EM28XX_R08_GPIO, 6, 7, 10}, |
| 237 | { -1, -1, -1, -1}, |
| 238 | }; |
| 239 | |
Mauro Carvalho Chehab | 766ed64 | 2009-05-24 00:46:01 -0300 | [diff] [blame] | 240 | /* Terratec AV350 */ |
| 241 | static struct em28xx_reg_seq terratec_av350_mute_gpio[] = { |
| 242 | {EM28XX_R08_GPIO, 0xff, 0x7f, 10}, |
| 243 | { -1, -1, -1, -1}, |
| 244 | }; |
| 245 | |
| 246 | static struct em28xx_reg_seq terratec_av350_unmute_gpio[] = { |
| 247 | {EM28XX_R08_GPIO, 0xff, 0xff, 10}, |
| 248 | { -1, -1, -1, -1}, |
| 249 | }; |
Mauro Carvalho Chehab | 02e7804 | 2009-06-29 11:35:05 -0300 | [diff] [blame] | 250 | |
| 251 | static struct em28xx_reg_seq silvercrest_reg_seq[] = { |
| 252 | {EM28XX_R08_GPIO, 0xff, 0xff, 10}, |
| 253 | {EM28XX_R08_GPIO, 0x01, 0xf7, 10}, |
| 254 | { -1, -1, -1, -1}, |
| 255 | }; |
| 256 | |
Mauro Carvalho Chehab | 694a101 | 2009-11-26 21:26:13 -0300 | [diff] [blame] | 257 | static struct em28xx_reg_seq vc211a_enable[] = { |
| 258 | {EM28XX_R08_GPIO, 0xff, 0x07, 10}, |
| 259 | {EM28XX_R08_GPIO, 0xff, 0x0f, 10}, |
| 260 | {EM28XX_R08_GPIO, 0xff, 0x0b, 10}, |
| 261 | { -1, -1, -1, -1}, |
| 262 | }; |
| 263 | |
Andrea.Amorosi76@gmail.com | 7ca7ef6 | 2010-02-09 17:53:38 -0300 | [diff] [blame] | 264 | static struct em28xx_reg_seq dikom_dk300_digital[] = { |
| 265 | {EM28XX_R08_GPIO, 0x6e, ~EM_GPIO_4, 10}, |
| 266 | {EM2880_R04_GPO, 0x08, 0xff, 10}, |
| 267 | { -1, -1, -1, -1}, |
| 268 | }; |
| 269 | |
Mauro Carvalho Chehab | 694a101 | 2009-11-26 21:26:13 -0300 | [diff] [blame] | 270 | |
Mauro Carvalho Chehab | 0ec202d | 2008-11-25 13:16:13 -0300 | [diff] [blame] | 271 | /* |
| 272 | * Board definitions |
| 273 | */ |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 274 | struct em28xx_board em28xx_boards[] = { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 275 | [EM2750_BOARD_UNKNOWN] = { |
Mauro Carvalho Chehab | 8b22079 | 2009-07-12 10:56:21 -0300 | [diff] [blame] | 276 | .name = "EM2710/EM2750/EM2751 webcam grabber", |
Mauro Carvalho Chehab | 3d3215c | 2009-08-10 10:29:27 -0300 | [diff] [blame] | 277 | .xclk = EM28XX_XCLK_FREQUENCY_20MHZ, |
Mauro Carvalho Chehab | 8a2e699 | 2009-07-12 10:26:36 -0300 | [diff] [blame] | 278 | .tuner_type = TUNER_ABSENT, |
| 279 | .is_webcam = 1, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 280 | .input = { { |
| 281 | .type = EM28XX_VMUX_COMPOSITE1, |
| 282 | .vmux = 0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 283 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | b80fd2d | 2009-07-14 21:08:22 -0300 | [diff] [blame] | 284 | .gpio = silvercrest_reg_seq, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 285 | } }, |
| 286 | }, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 287 | [EM2800_BOARD_UNKNOWN] = { |
| 288 | .name = "Unknown EM2800 video grabber", |
| 289 | .is_em2800 = 1, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 290 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 291 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | 1c67e76 | 2008-11-27 07:46:59 -0300 | [diff] [blame] | 292 | .tuner_type = TUNER_ABSENT, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 293 | .input = { { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 294 | .type = EM28XX_VMUX_COMPOSITE1, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 295 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 296 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 297 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 298 | .type = EM28XX_VMUX_SVIDEO, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 299 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 300 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 301 | } }, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 302 | }, |
| 303 | [EM2820_BOARD_UNKNOWN] = { |
Mauro Carvalho Chehab | a2070c6 | 2008-11-25 07:05:06 -0300 | [diff] [blame] | 304 | .name = "Unknown EM2750/28xx video grabber", |
| 305 | .tuner_type = TUNER_ABSENT, |
Mauro Carvalho Chehab | b04fb66 | 2009-07-13 01:28:21 -0300 | [diff] [blame] | 306 | .is_webcam = 1, /* To enable sensor probe */ |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 307 | }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 308 | [EM2750_BOARD_DLCW_130] = { |
| 309 | /* Beijing Huaqi Information Digital Technology Co., Ltd */ |
| 310 | .name = "Huaqi DLCW-130", |
| 311 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Mauro Carvalho Chehab | a2070c6 | 2008-11-25 07:05:06 -0300 | [diff] [blame] | 312 | .xclk = EM28XX_XCLK_FREQUENCY_48MHZ, |
Mauro Carvalho Chehab | 8a2e699 | 2009-07-12 10:26:36 -0300 | [diff] [blame] | 313 | .tuner_type = TUNER_ABSENT, |
| 314 | .is_webcam = 1, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 315 | .input = { { |
| 316 | .type = EM28XX_VMUX_COMPOSITE1, |
| 317 | .vmux = 0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 318 | .amux = EM28XX_AMUX_VIDEO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 319 | } }, |
| 320 | }, |
Markus Rechberger | 4d17d08 | 2006-02-07 06:25:39 -0200 | [diff] [blame] | 321 | [EM2820_BOARD_KWORLD_PVRTV2800RF] = { |
Markus Rechberger | 33ccaa3 | 2006-02-07 06:25:41 -0200 | [diff] [blame] | 322 | .name = "Kworld PVR TV 2800 RF", |
Mauro Carvalho Chehab | ed08631 | 2008-01-24 06:59:20 -0300 | [diff] [blame] | 323 | .tuner_type = TUNER_TEMIC_PAL, |
Markus Rechberger | 4d17d08 | 2006-02-07 06:25:39 -0200 | [diff] [blame] | 324 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 325 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 326 | .input = { { |
Markus Rechberger | 4d17d08 | 2006-02-07 06:25:39 -0200 | [diff] [blame] | 327 | .type = EM28XX_VMUX_COMPOSITE1, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 328 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 329 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 330 | }, { |
Markus Rechberger | 4d17d08 | 2006-02-07 06:25:39 -0200 | [diff] [blame] | 331 | .type = EM28XX_VMUX_SVIDEO, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 332 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 333 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 334 | } }, |
Markus Rechberger | 4d17d08 | 2006-02-07 06:25:39 -0200 | [diff] [blame] | 335 | }, |
Douglas Schilling Landgraf | f7fe3e6 | 2009-01-19 09:31:55 -0300 | [diff] [blame] | 336 | [EM2820_BOARD_GADMEI_TVR200] = { |
| 337 | .name = "Gadmei TVR200", |
| 338 | .tuner_type = TUNER_LG_PAL_NEW_TAPC, |
| 339 | .tda9887_conf = TDA9887_PRESENT, |
| 340 | .decoder = EM28XX_SAA711X, |
| 341 | .input = { { |
| 342 | .type = EM28XX_VMUX_TELEVISION, |
| 343 | .vmux = SAA7115_COMPOSITE2, |
| 344 | .amux = EM28XX_AMUX_LINE_IN, |
| 345 | }, { |
| 346 | .type = EM28XX_VMUX_COMPOSITE1, |
| 347 | .vmux = SAA7115_COMPOSITE0, |
| 348 | .amux = EM28XX_AMUX_LINE_IN, |
| 349 | }, { |
| 350 | .type = EM28XX_VMUX_SVIDEO, |
| 351 | .vmux = SAA7115_SVIDEO3, |
| 352 | .amux = EM28XX_AMUX_LINE_IN, |
| 353 | } }, |
| 354 | }, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 355 | [EM2820_BOARD_TERRATEC_CINERGY_250] = { |
| 356 | .name = "Terratec Cinergy 250 USB", |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 357 | .tuner_type = TUNER_LG_PAL_NEW_TAPC, |
Mauro Carvalho Chehab | ac07bb7 | 2009-09-08 14:04:41 -0300 | [diff] [blame] | 358 | .has_ir_i2c = 1, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 359 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 360 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 361 | .input = { { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 362 | .type = EM28XX_VMUX_TELEVISION, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 363 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 364 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 365 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 366 | .type = EM28XX_VMUX_COMPOSITE1, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 367 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 368 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 369 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 370 | .type = EM28XX_VMUX_SVIDEO, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 371 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 372 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 373 | } }, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 374 | }, |
| 375 | [EM2820_BOARD_PINNACLE_USB_2] = { |
| 376 | .name = "Pinnacle PCTV USB 2", |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 377 | .tuner_type = TUNER_LG_PAL_NEW_TAPC, |
Mauro Carvalho Chehab | ac07bb7 | 2009-09-08 14:04:41 -0300 | [diff] [blame] | 378 | .has_ir_i2c = 1, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 379 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 380 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 381 | .input = { { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 382 | .type = EM28XX_VMUX_TELEVISION, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 383 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 384 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 385 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 386 | .type = EM28XX_VMUX_COMPOSITE1, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 387 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 388 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 389 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 390 | .type = EM28XX_VMUX_SVIDEO, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 391 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 392 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 393 | } }, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 394 | }, |
| 395 | [EM2820_BOARD_HAUPPAUGE_WINTV_USB_2] = { |
| 396 | .name = "Hauppauge WinTV USB 2", |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 397 | .tuner_type = TUNER_PHILIPS_FM1236_MK3, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 398 | .tda9887_conf = TDA9887_PRESENT | |
Nicola Soranzo | a1a6ee7 | 2009-02-10 23:28:24 -0300 | [diff] [blame] | 399 | TDA9887_PORT1_ACTIVE | |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 400 | TDA9887_PORT2_ACTIVE, |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 401 | .decoder = EM28XX_TVP5150, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 402 | .has_msp34xx = 1, |
Mauro Carvalho Chehab | ac07bb7 | 2009-09-08 14:04:41 -0300 | [diff] [blame] | 403 | .has_ir_i2c = 1, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 404 | .input = { { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 405 | .type = EM28XX_VMUX_TELEVISION, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 406 | .vmux = TVP5150_COMPOSITE0, |
Hans Verkuil | 2474ed4 | 2006-03-19 12:35:57 -0300 | [diff] [blame] | 407 | .amux = MSP_INPUT_DEFAULT, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 408 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 409 | .type = EM28XX_VMUX_SVIDEO, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 410 | .vmux = TVP5150_SVIDEO, |
Hans Verkuil | 0715172 | 2006-04-01 18:03:23 -0300 | [diff] [blame] | 411 | .amux = MSP_INPUT(MSP_IN_SCART1, MSP_IN_TUNER1, |
| 412 | MSP_DSP_IN_SCART, MSP_DSP_IN_SCART), |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 413 | } }, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 414 | }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 415 | [EM2820_BOARD_DLINK_USB_TV] = { |
| 416 | .name = "D-Link DUB-T210 TV Tuner", |
| 417 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 418 | .tuner_type = TUNER_LG_PAL_NEW_TAPC, |
| 419 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 420 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 421 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 422 | .type = EM28XX_VMUX_TELEVISION, |
| 423 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 424 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 425 | }, { |
| 426 | .type = EM28XX_VMUX_COMPOSITE1, |
| 427 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 428 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 429 | }, { |
| 430 | .type = EM28XX_VMUX_SVIDEO, |
| 431 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 432 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 433 | } }, |
| 434 | }, |
| 435 | [EM2820_BOARD_HERCULES_SMART_TV_USB2] = { |
| 436 | .name = "Hercules Smart TV USB 2.0", |
| 437 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 438 | .tuner_type = TUNER_LG_PAL_NEW_TAPC, |
| 439 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 440 | .decoder = EM28XX_SAA711X, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 441 | .input = { { |
| 442 | .type = EM28XX_VMUX_TELEVISION, |
| 443 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 444 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 445 | }, { |
| 446 | .type = EM28XX_VMUX_COMPOSITE1, |
| 447 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 448 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 449 | }, { |
| 450 | .type = EM28XX_VMUX_SVIDEO, |
| 451 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 452 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 453 | } }, |
| 454 | }, |
| 455 | [EM2820_BOARD_PINNACLE_USB_2_FM1216ME] = { |
| 456 | .name = "Pinnacle PCTV USB 2 (Philips FM1216ME)", |
| 457 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 458 | .tuner_type = TUNER_PHILIPS_FM1216ME_MK3, |
| 459 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 460 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 461 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 462 | .type = EM28XX_VMUX_TELEVISION, |
| 463 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 464 | .amux = EM28XX_AMUX_VIDEO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 465 | }, { |
| 466 | .type = EM28XX_VMUX_COMPOSITE1, |
| 467 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 468 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 469 | }, { |
| 470 | .type = EM28XX_VMUX_SVIDEO, |
| 471 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 472 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 473 | } }, |
| 474 | }, |
| 475 | [EM2820_BOARD_GADMEI_UTV310] = { |
| 476 | .name = "Gadmei UTV310", |
| 477 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 478 | .tuner_type = TUNER_TNF_5335MF, |
| 479 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 480 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 481 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 482 | .type = EM28XX_VMUX_TELEVISION, |
| 483 | .vmux = SAA7115_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 484 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 485 | }, { |
| 486 | .type = EM28XX_VMUX_COMPOSITE1, |
| 487 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 488 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 489 | }, { |
| 490 | .type = EM28XX_VMUX_SVIDEO, |
| 491 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 492 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 493 | } }, |
| 494 | }, |
| 495 | [EM2820_BOARD_LEADTEK_WINFAST_USBII_DELUXE] = { |
| 496 | .name = "Leadtek Winfast USB II Deluxe", |
| 497 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 498 | .tuner_type = TUNER_PHILIPS_FM1216ME_MK3, |
Magnus Alm | ca39d84 | 2009-11-13 05:48:24 -0300 | [diff] [blame] | 499 | .has_ir_i2c = 1, |
| 500 | .tvaudio_addr = 0x58, |
| 501 | .tda9887_conf = TDA9887_PRESENT | |
| 502 | TDA9887_PORT2_ACTIVE | |
| 503 | TDA9887_QSS, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 504 | .decoder = EM28XX_SAA711X, |
Magnus Alm | ca39d84 | 2009-11-13 05:48:24 -0300 | [diff] [blame] | 505 | .adecoder = EM28XX_TVAUDIO, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 506 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 507 | .type = EM28XX_VMUX_TELEVISION, |
Magnus Alm | ca39d84 | 2009-11-13 05:48:24 -0300 | [diff] [blame] | 508 | .vmux = SAA7115_COMPOSITE4, |
| 509 | .amux = EM28XX_AMUX_AUX, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 510 | }, { |
| 511 | .type = EM28XX_VMUX_COMPOSITE1, |
Magnus Alm | ca39d84 | 2009-11-13 05:48:24 -0300 | [diff] [blame] | 512 | .vmux = SAA7115_COMPOSITE5, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 513 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 514 | }, { |
| 515 | .type = EM28XX_VMUX_SVIDEO, |
Magnus Alm | ca39d84 | 2009-11-13 05:48:24 -0300 | [diff] [blame] | 516 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 517 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 518 | } }, |
Magnus Alm | ca39d84 | 2009-11-13 05:48:24 -0300 | [diff] [blame] | 519 | .radio = { |
| 520 | .type = EM28XX_RADIO, |
| 521 | .amux = EM28XX_AMUX_AUX, |
| 522 | } |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 523 | }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 524 | [EM2820_BOARD_VIDEOLOGY_20K14XUSB] = { |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 525 | .name = "Videology 20K14XUSB USB2.0", |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 526 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Mauro Carvalho Chehab | 8a2e699 | 2009-07-12 10:26:36 -0300 | [diff] [blame] | 527 | .tuner_type = TUNER_ABSENT, |
| 528 | .is_webcam = 1, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 529 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 530 | .type = EM28XX_VMUX_COMPOSITE1, |
| 531 | .vmux = 0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 532 | .amux = EM28XX_AMUX_VIDEO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 533 | } }, |
| 534 | }, |
Mauro Carvalho Chehab | 02e7804 | 2009-06-29 11:35:05 -0300 | [diff] [blame] | 535 | [EM2820_BOARD_SILVERCREST_WEBCAM] = { |
| 536 | .name = "Silvercrest Webcam 1.3mpix", |
| 537 | .tuner_type = TUNER_ABSENT, |
Mauro Carvalho Chehab | c43221d | 2009-07-12 10:23:23 -0300 | [diff] [blame] | 538 | .is_webcam = 1, |
Mauro Carvalho Chehab | 02e7804 | 2009-06-29 11:35:05 -0300 | [diff] [blame] | 539 | .input = { { |
| 540 | .type = EM28XX_VMUX_COMPOSITE1, |
| 541 | .vmux = 0, |
| 542 | .amux = EM28XX_AMUX_VIDEO, |
| 543 | .gpio = silvercrest_reg_seq, |
| 544 | } }, |
| 545 | }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 546 | [EM2821_BOARD_SUPERCOMP_USB_2] = { |
| 547 | .name = "Supercomp USB 2.0 TV", |
| 548 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 549 | .tuner_type = TUNER_PHILIPS_FM1236_MK3, |
| 550 | .tda9887_conf = TDA9887_PRESENT | |
| 551 | TDA9887_PORT1_ACTIVE | |
| 552 | TDA9887_PORT2_ACTIVE, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 553 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 554 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 555 | .type = EM28XX_VMUX_TELEVISION, |
| 556 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 557 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 558 | }, { |
| 559 | .type = EM28XX_VMUX_COMPOSITE1, |
| 560 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 561 | .amux = EM28XX_AMUX_VIDEO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 562 | }, { |
| 563 | .type = EM28XX_VMUX_SVIDEO, |
| 564 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 565 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 566 | } }, |
| 567 | }, |
| 568 | [EM2821_BOARD_USBGEAR_VD204] = { |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 569 | .name = "Usbgear VD204v9", |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 570 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Mauro Carvalho Chehab | 1c67e76 | 2008-11-27 07:46:59 -0300 | [diff] [blame] | 571 | .tuner_type = TUNER_ABSENT, /* Capture only device */ |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 572 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 573 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 574 | .type = EM28XX_VMUX_COMPOSITE1, |
| 575 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 576 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 577 | }, { |
| 578 | .type = EM28XX_VMUX_SVIDEO, |
| 579 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 580 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 581 | } }, |
| 582 | }, |
| 583 | [EM2860_BOARD_NETGMBH_CAM] = { |
| 584 | /* Beijing Huaqi Information Digital Technology Co., Ltd */ |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 585 | .name = "NetGMBH Cam", |
| 586 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Mauro Carvalho Chehab | 8a2e699 | 2009-07-12 10:26:36 -0300 | [diff] [blame] | 587 | .tuner_type = TUNER_ABSENT, |
| 588 | .is_webcam = 1, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 589 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 590 | .type = EM28XX_VMUX_COMPOSITE1, |
| 591 | .vmux = 0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 592 | .amux = EM28XX_AMUX_VIDEO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 593 | } }, |
| 594 | }, |
| 595 | [EM2860_BOARD_TYPHOON_DVD_MAKER] = { |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 596 | .name = "Typhoon DVD Maker", |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 597 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | 1c67e76 | 2008-11-27 07:46:59 -0300 | [diff] [blame] | 598 | .tuner_type = TUNER_ABSENT, /* Capture only device */ |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 599 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 600 | .type = EM28XX_VMUX_COMPOSITE1, |
| 601 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 602 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 603 | }, { |
| 604 | .type = EM28XX_VMUX_SVIDEO, |
| 605 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 606 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 607 | } }, |
| 608 | }, |
| 609 | [EM2860_BOARD_GADMEI_UTV330] = { |
| 610 | .name = "Gadmei UTV330", |
| 611 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 612 | .tuner_type = TUNER_TNF_5335MF, |
| 613 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 614 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 615 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 616 | .type = EM28XX_VMUX_TELEVISION, |
| 617 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 618 | .amux = EM28XX_AMUX_VIDEO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 619 | }, { |
| 620 | .type = EM28XX_VMUX_COMPOSITE1, |
| 621 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 622 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 623 | }, { |
| 624 | .type = EM28XX_VMUX_SVIDEO, |
| 625 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 626 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 627 | } }, |
| 628 | }, |
Mauro Carvalho Chehab | 6d888a6 | 2009-08-30 13:05:56 -0300 | [diff] [blame] | 629 | [EM2861_BOARD_GADMEI_UTV330PLUS] = { |
| 630 | .name = "Gadmei UTV330+", |
| 631 | .tuner_type = TUNER_TNF_5335MF, |
| 632 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 633 | .ir_codes = RC_MAP_GADMEI_RM008Z, |
Mauro Carvalho Chehab | 6d888a6 | 2009-08-30 13:05:56 -0300 | [diff] [blame] | 634 | .decoder = EM28XX_SAA711X, |
| 635 | .xclk = EM28XX_XCLK_FREQUENCY_12MHZ, |
| 636 | .input = { { |
| 637 | .type = EM28XX_VMUX_TELEVISION, |
| 638 | .vmux = SAA7115_COMPOSITE2, |
| 639 | .amux = EM28XX_AMUX_VIDEO, |
| 640 | }, { |
| 641 | .type = EM28XX_VMUX_COMPOSITE1, |
| 642 | .vmux = SAA7115_COMPOSITE0, |
| 643 | .amux = EM28XX_AMUX_LINE_IN, |
| 644 | }, { |
| 645 | .type = EM28XX_VMUX_SVIDEO, |
| 646 | .vmux = SAA7115_SVIDEO3, |
| 647 | .amux = EM28XX_AMUX_LINE_IN, |
| 648 | } }, |
| 649 | }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 650 | [EM2860_BOARD_TERRATEC_HYBRID_XS] = { |
| 651 | .name = "Terratec Cinergy A Hybrid XS", |
| 652 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 653 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 654 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 655 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 656 | |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 657 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 658 | .type = EM28XX_VMUX_TELEVISION, |
| 659 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 660 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 661 | .gpio = hauppauge_wintv_hvr_900_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 662 | }, { |
| 663 | .type = EM28XX_VMUX_COMPOSITE1, |
| 664 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 665 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 666 | .gpio = hauppauge_wintv_hvr_900_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 667 | }, { |
| 668 | .type = EM28XX_VMUX_SVIDEO, |
| 669 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 670 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 671 | .gpio = hauppauge_wintv_hvr_900_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 672 | } }, |
| 673 | }, |
| 674 | [EM2861_BOARD_KWORLD_PVRTV_300U] = { |
| 675 | .name = "KWorld PVRTV 300U", |
| 676 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 677 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 678 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 679 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 680 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 681 | .type = EM28XX_VMUX_TELEVISION, |
| 682 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 683 | .amux = EM28XX_AMUX_VIDEO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 684 | }, { |
| 685 | .type = EM28XX_VMUX_COMPOSITE1, |
| 686 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 687 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 688 | }, { |
| 689 | .type = EM28XX_VMUX_SVIDEO, |
| 690 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 691 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 692 | } }, |
| 693 | }, |
| 694 | [EM2861_BOARD_YAKUMO_MOVIE_MIXER] = { |
| 695 | .name = "Yakumo MovieMixer", |
Nicola Soranzo | a1a6ee7 | 2009-02-10 23:28:24 -0300 | [diff] [blame] | 696 | .tuner_type = TUNER_ABSENT, /* Capture only device */ |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 697 | .decoder = EM28XX_TVP5150, |
| 698 | .input = { { |
| 699 | .type = EM28XX_VMUX_TELEVISION, |
| 700 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 701 | .amux = EM28XX_AMUX_VIDEO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 702 | }, { |
| 703 | .type = EM28XX_VMUX_COMPOSITE1, |
| 704 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 705 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 706 | }, { |
| 707 | .type = EM28XX_VMUX_SVIDEO, |
| 708 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 709 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 710 | } }, |
| 711 | }, |
Devin Heitmueller | 443fed9 | 2010-03-19 23:53:12 -0300 | [diff] [blame] | 712 | [EM2860_BOARD_TVP5150_REFERENCE_DESIGN] = { |
| 713 | .name = "EM2860/TVP5150 Reference Design", |
| 714 | .tuner_type = TUNER_ABSENT, /* Capture only device */ |
| 715 | .decoder = EM28XX_TVP5150, |
| 716 | .input = { { |
| 717 | .type = EM28XX_VMUX_COMPOSITE1, |
| 718 | .vmux = TVP5150_COMPOSITE1, |
| 719 | .amux = EM28XX_AMUX_LINE_IN, |
| 720 | }, { |
| 721 | .type = EM28XX_VMUX_SVIDEO, |
| 722 | .vmux = TVP5150_SVIDEO, |
| 723 | .amux = EM28XX_AMUX_LINE_IN, |
| 724 | } }, |
| 725 | }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 726 | [EM2861_BOARD_PLEXTOR_PX_TV100U] = { |
| 727 | .name = "Plextor ConvertX PX-TV100U", |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 728 | .tuner_type = TUNER_TNF_5335MF, |
Mauro Carvalho Chehab | 0a6e44d | 2009-07-29 01:39:12 -0300 | [diff] [blame] | 729 | .xclk = EM28XX_XCLK_I2S_MSB_TIMING | |
| 730 | EM28XX_XCLK_FREQUENCY_12MHZ, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 731 | .tda9887_conf = TDA9887_PRESENT, |
| 732 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | 0a6e44d | 2009-07-29 01:39:12 -0300 | [diff] [blame] | 733 | .has_msp34xx = 1, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 734 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 735 | .type = EM28XX_VMUX_TELEVISION, |
| 736 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 737 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 0a6e44d | 2009-07-29 01:39:12 -0300 | [diff] [blame] | 738 | .gpio = pinnacle_hybrid_pro_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 739 | }, { |
| 740 | .type = EM28XX_VMUX_COMPOSITE1, |
| 741 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 742 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 0a6e44d | 2009-07-29 01:39:12 -0300 | [diff] [blame] | 743 | .gpio = pinnacle_hybrid_pro_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 744 | }, { |
| 745 | .type = EM28XX_VMUX_SVIDEO, |
| 746 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 747 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 0a6e44d | 2009-07-29 01:39:12 -0300 | [diff] [blame] | 748 | .gpio = pinnacle_hybrid_pro_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 749 | } }, |
| 750 | }, |
Mauro Carvalho Chehab | 1c67e76 | 2008-11-27 07:46:59 -0300 | [diff] [blame] | 751 | |
| 752 | /* Those boards with em2870 are DVB Only*/ |
| 753 | |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 754 | [EM2870_BOARD_TERRATEC_XS] = { |
| 755 | .name = "Terratec Cinergy T XS", |
| 756 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
| 757 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 758 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 759 | }, |
| 760 | [EM2870_BOARD_TERRATEC_XS_MT2060] = { |
| 761 | .name = "Terratec Cinergy T XS (MT2060)", |
| 762 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
| 763 | .tuner_type = TUNER_ABSENT, /* MT2060 */ |
| 764 | }, |
| 765 | [EM2870_BOARD_KWORLD_350U] = { |
| 766 | .name = "Kworld 350 U DVB-T", |
| 767 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
| 768 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 769 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 770 | }, |
| 771 | [EM2870_BOARD_KWORLD_355U] = { |
| 772 | .name = "Kworld 355 U DVB-T", |
| 773 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
| 774 | }, |
| 775 | [EM2870_BOARD_PINNACLE_PCTV_DVB] = { |
| 776 | .name = "Pinnacle PCTV DVB-T", |
| 777 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
| 778 | .tuner_type = TUNER_ABSENT, /* MT2060 */ |
Mauro Carvalho Chehab | a2070c6 | 2008-11-25 07:05:06 -0300 | [diff] [blame] | 779 | /* djh - I have serious doubts this is right... */ |
| 780 | .xclk = EM28XX_XCLK_IR_RC5_MODE | |
| 781 | EM28XX_XCLK_FREQUENCY_10MHZ, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 782 | }, |
| 783 | [EM2870_BOARD_COMPRO_VIDEOMATE] = { |
| 784 | .name = "Compro, VideoMate U3", |
| 785 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
| 786 | .tuner_type = TUNER_ABSENT, /* MT2060 */ |
| 787 | }, |
Mauro Carvalho Chehab | 1c67e76 | 2008-11-27 07:46:59 -0300 | [diff] [blame] | 788 | |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 789 | [EM2880_BOARD_TERRATEC_HYBRID_XS_FR] = { |
| 790 | .name = "Terratec Hybrid XS Secam", |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 791 | .has_msp34xx = 1, |
| 792 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 793 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 794 | .decoder = EM28XX_TVP5150, |
Catimimi | 6563801 | 2010-02-18 18:06:32 -0300 | [diff] [blame] | 795 | .has_dvb = 1, |
Michel Garnier | cec4e6c | 2010-10-16 14:42:01 -0300 | [diff] [blame^] | 796 | .dvb_gpio = terratec_cinergy_USB_XS_FR_digital, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 797 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 798 | .type = EM28XX_VMUX_TELEVISION, |
| 799 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 800 | .amux = EM28XX_AMUX_VIDEO, |
Michel Garnier | cec4e6c | 2010-10-16 14:42:01 -0300 | [diff] [blame^] | 801 | .gpio = terratec_cinergy_USB_XS_FR_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 802 | }, { |
| 803 | .type = EM28XX_VMUX_COMPOSITE1, |
| 804 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 805 | .amux = EM28XX_AMUX_LINE_IN, |
Michel Garnier | cec4e6c | 2010-10-16 14:42:01 -0300 | [diff] [blame^] | 806 | .gpio = terratec_cinergy_USB_XS_FR_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 807 | }, { |
| 808 | .type = EM28XX_VMUX_SVIDEO, |
| 809 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 810 | .amux = EM28XX_AMUX_LINE_IN, |
Michel Garnier | cec4e6c | 2010-10-16 14:42:01 -0300 | [diff] [blame^] | 811 | .gpio = terratec_cinergy_USB_XS_FR_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 812 | } }, |
| 813 | }, |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 814 | [EM2880_BOARD_HAUPPAUGE_WINTV_HVR_900] = { |
Aidan Thornton | 122d158 | 2007-11-20 15:25:08 -0300 | [diff] [blame] | 815 | .name = "Hauppauge WinTV HVR 900", |
Aidan Thornton | 122d158 | 2007-11-20 15:25:08 -0300 | [diff] [blame] | 816 | .tda9887_conf = TDA9887_PRESENT, |
| 817 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 818 | .tuner_gpio = default_tuner_gpio, |
Mauro Carvalho Chehab | 5add9a6 | 2007-11-22 12:08:53 -0300 | [diff] [blame] | 819 | .mts_firmware = 1, |
Mauro Carvalho Chehab | a2070c6 | 2008-11-25 07:05:06 -0300 | [diff] [blame] | 820 | .has_dvb = 1, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 821 | .dvb_gpio = hauppauge_wintv_hvr_900_digital, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 822 | .ir_codes = RC_MAP_HAUPPAUGE_NEW, |
Aidan Thornton | 122d158 | 2007-11-20 15:25:08 -0300 | [diff] [blame] | 823 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 824 | .input = { { |
Aidan Thornton | 122d158 | 2007-11-20 15:25:08 -0300 | [diff] [blame] | 825 | .type = EM28XX_VMUX_TELEVISION, |
| 826 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 827 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 828 | .gpio = hauppauge_wintv_hvr_900_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 829 | }, { |
Aidan Thornton | 122d158 | 2007-11-20 15:25:08 -0300 | [diff] [blame] | 830 | .type = EM28XX_VMUX_COMPOSITE1, |
| 831 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 832 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 833 | .gpio = hauppauge_wintv_hvr_900_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 834 | }, { |
Aidan Thornton | 122d158 | 2007-11-20 15:25:08 -0300 | [diff] [blame] | 835 | .type = EM28XX_VMUX_SVIDEO, |
| 836 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 837 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 838 | .gpio = hauppauge_wintv_hvr_900_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 839 | } }, |
Aidan Thornton | 122d158 | 2007-11-20 15:25:08 -0300 | [diff] [blame] | 840 | }, |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 841 | [EM2880_BOARD_HAUPPAUGE_WINTV_HVR_900_R2] = { |
| 842 | .name = "Hauppauge WinTV HVR 900 (R2)", |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 843 | .tda9887_conf = TDA9887_PRESENT, |
| 844 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 845 | .tuner_gpio = default_tuner_gpio, |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 846 | .mts_firmware = 1, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 847 | .ir_codes = RC_MAP_HAUPPAUGE_NEW, |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 848 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 849 | .input = { { |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 850 | .type = EM28XX_VMUX_TELEVISION, |
| 851 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 852 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 853 | .gpio = hauppauge_wintv_hvr_900_analog, |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 854 | }, { |
| 855 | .type = EM28XX_VMUX_COMPOSITE1, |
| 856 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | a5942b5 | 2008-11-27 07:44:00 -0300 | [diff] [blame] | 857 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 858 | .gpio = hauppauge_wintv_hvr_900_analog, |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 859 | }, { |
| 860 | .type = EM28XX_VMUX_SVIDEO, |
| 861 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 862 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 863 | .gpio = hauppauge_wintv_hvr_900_analog, |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 864 | } }, |
| 865 | }, |
Douglas Schilling Landgraf | f89bc32 | 2008-12-01 21:01:04 -0300 | [diff] [blame] | 866 | [EM2883_BOARD_HAUPPAUGE_WINTV_HVR_850] = { |
| 867 | .name = "Hauppauge WinTV HVR 850", |
| 868 | .tuner_type = TUNER_XC2028, |
| 869 | .tuner_gpio = default_tuner_gpio, |
| 870 | .mts_firmware = 1, |
| 871 | .has_dvb = 1, |
| 872 | .dvb_gpio = hauppauge_wintv_hvr_900_digital, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 873 | .ir_codes = RC_MAP_HAUPPAUGE_NEW, |
Douglas Schilling Landgraf | f89bc32 | 2008-12-01 21:01:04 -0300 | [diff] [blame] | 874 | .decoder = EM28XX_TVP5150, |
| 875 | .input = { { |
| 876 | .type = EM28XX_VMUX_TELEVISION, |
| 877 | .vmux = TVP5150_COMPOSITE0, |
| 878 | .amux = EM28XX_AMUX_VIDEO, |
| 879 | .gpio = hauppauge_wintv_hvr_900_analog, |
| 880 | }, { |
| 881 | .type = EM28XX_VMUX_COMPOSITE1, |
| 882 | .vmux = TVP5150_COMPOSITE1, |
| 883 | .amux = EM28XX_AMUX_LINE_IN, |
| 884 | .gpio = hauppauge_wintv_hvr_900_analog, |
| 885 | }, { |
| 886 | .type = EM28XX_VMUX_SVIDEO, |
| 887 | .vmux = TVP5150_SVIDEO, |
| 888 | .amux = EM28XX_AMUX_LINE_IN, |
| 889 | .gpio = hauppauge_wintv_hvr_900_analog, |
| 890 | } }, |
| 891 | }, |
Mauro Carvalho Chehab | 10ac660 | 2008-07-27 14:58:58 -0300 | [diff] [blame] | 892 | [EM2883_BOARD_HAUPPAUGE_WINTV_HVR_950] = { |
Mauro Carvalho Chehab | 3abee53 | 2008-01-05 17:01:41 -0300 | [diff] [blame] | 893 | .name = "Hauppauge WinTV HVR 950", |
Mauro Carvalho Chehab | 3abee53 | 2008-01-05 17:01:41 -0300 | [diff] [blame] | 894 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 895 | .tuner_gpio = default_tuner_gpio, |
Mauro Carvalho Chehab | 3abee53 | 2008-01-05 17:01:41 -0300 | [diff] [blame] | 896 | .mts_firmware = 1, |
Mauro Carvalho Chehab | 227ad4a | 2008-04-17 21:37:40 -0300 | [diff] [blame] | 897 | .has_dvb = 1, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 898 | .dvb_gpio = hauppauge_wintv_hvr_900_digital, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 899 | .ir_codes = RC_MAP_RC5_HAUPPAUGE_NEW, |
Mauro Carvalho Chehab | 3abee53 | 2008-01-05 17:01:41 -0300 | [diff] [blame] | 900 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 901 | .input = { { |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 902 | .type = EM28XX_VMUX_TELEVISION, |
| 903 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 904 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 905 | .gpio = hauppauge_wintv_hvr_900_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 906 | }, { |
Mauro Carvalho Chehab | 7d070e2 | 2007-11-01 21:52:58 -0300 | [diff] [blame] | 907 | .type = EM28XX_VMUX_COMPOSITE1, |
| 908 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 909 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 910 | .gpio = hauppauge_wintv_hvr_900_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 911 | }, { |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 912 | .type = EM28XX_VMUX_SVIDEO, |
| 913 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 914 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 915 | .gpio = hauppauge_wintv_hvr_900_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 916 | } }, |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 917 | }, |
Devin Heitmueller | 4fd305b | 2008-06-04 13:43:46 -0300 | [diff] [blame] | 918 | [EM2880_BOARD_PINNACLE_PCTV_HD_PRO] = { |
| 919 | .name = "Pinnacle PCTV HD Pro Stick", |
Devin Heitmueller | 4fd305b | 2008-06-04 13:43:46 -0300 | [diff] [blame] | 920 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 921 | .tuner_gpio = default_tuner_gpio, |
Devin Heitmueller | 4fd305b | 2008-06-04 13:43:46 -0300 | [diff] [blame] | 922 | .mts_firmware = 1, |
Devin Heitmueller | 4fd305b | 2008-06-04 13:43:46 -0300 | [diff] [blame] | 923 | .has_dvb = 1, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 924 | .dvb_gpio = hauppauge_wintv_hvr_900_digital, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 925 | .ir_codes = RC_MAP_PINNACLE_PCTV_HD, |
Devin Heitmueller | 4fd305b | 2008-06-04 13:43:46 -0300 | [diff] [blame] | 926 | .decoder = EM28XX_TVP5150, |
| 927 | .input = { { |
| 928 | .type = EM28XX_VMUX_TELEVISION, |
| 929 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 930 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 931 | .gpio = hauppauge_wintv_hvr_900_analog, |
Devin Heitmueller | 4fd305b | 2008-06-04 13:43:46 -0300 | [diff] [blame] | 932 | }, { |
| 933 | .type = EM28XX_VMUX_COMPOSITE1, |
| 934 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 935 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 936 | .gpio = hauppauge_wintv_hvr_900_analog, |
Devin Heitmueller | 4fd305b | 2008-06-04 13:43:46 -0300 | [diff] [blame] | 937 | }, { |
| 938 | .type = EM28XX_VMUX_SVIDEO, |
| 939 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 940 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 941 | .gpio = hauppauge_wintv_hvr_900_analog, |
Devin Heitmueller | 4fd305b | 2008-06-04 13:43:46 -0300 | [diff] [blame] | 942 | } }, |
| 943 | }, |
Devin Heitmueller | e14b365 | 2008-07-26 11:04:33 -0300 | [diff] [blame] | 944 | [EM2880_BOARD_AMD_ATI_TV_WONDER_HD_600] = { |
| 945 | .name = "AMD ATI TV Wonder HD 600", |
Devin Heitmueller | e14b365 | 2008-07-26 11:04:33 -0300 | [diff] [blame] | 946 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 947 | .tuner_gpio = default_tuner_gpio, |
Devin Heitmueller | e14b365 | 2008-07-26 11:04:33 -0300 | [diff] [blame] | 948 | .mts_firmware = 1, |
Devin Heitmueller | e14b365 | 2008-07-26 11:04:33 -0300 | [diff] [blame] | 949 | .has_dvb = 1, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 950 | .dvb_gpio = hauppauge_wintv_hvr_900_digital, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 951 | .ir_codes = RC_MAP_ATI_TV_WONDER_HD_600, |
Devin Heitmueller | e14b365 | 2008-07-26 11:04:33 -0300 | [diff] [blame] | 952 | .decoder = EM28XX_TVP5150, |
| 953 | .input = { { |
| 954 | .type = EM28XX_VMUX_TELEVISION, |
| 955 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 956 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 957 | .gpio = hauppauge_wintv_hvr_900_analog, |
Devin Heitmueller | e14b365 | 2008-07-26 11:04:33 -0300 | [diff] [blame] | 958 | }, { |
| 959 | .type = EM28XX_VMUX_COMPOSITE1, |
| 960 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 961 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 962 | .gpio = hauppauge_wintv_hvr_900_analog, |
Devin Heitmueller | e14b365 | 2008-07-26 11:04:33 -0300 | [diff] [blame] | 963 | }, { |
| 964 | .type = EM28XX_VMUX_SVIDEO, |
| 965 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 966 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 967 | .gpio = hauppauge_wintv_hvr_900_analog, |
Devin Heitmueller | e14b365 | 2008-07-26 11:04:33 -0300 | [diff] [blame] | 968 | } }, |
| 969 | }, |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 970 | [EM2880_BOARD_TERRATEC_HYBRID_XS] = { |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 971 | .name = "Terratec Hybrid XS", |
| 972 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 973 | .tuner_gpio = default_tuner_gpio, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 974 | .decoder = EM28XX_TVP5150, |
reinhard schwab | 655b840 | 2008-07-26 10:47:00 -0300 | [diff] [blame] | 975 | .has_dvb = 1, |
Devin Heitmueller | f797608 | 2009-06-22 22:32:32 -0300 | [diff] [blame] | 976 | .dvb_gpio = default_digital, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 977 | .ir_codes = RC_MAP_TERRATEC_CINERGY_XS, |
Devin Heitmueller | 8cd9aae | 2009-08-03 23:56:51 -0300 | [diff] [blame] | 978 | .xclk = EM28XX_XCLK_FREQUENCY_12MHZ, /* NEC IR */ |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 979 | .input = { { |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 980 | .type = EM28XX_VMUX_TELEVISION, |
| 981 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 982 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 983 | .gpio = default_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 984 | }, { |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 985 | .type = EM28XX_VMUX_COMPOSITE1, |
| 986 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 987 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 988 | .gpio = default_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 989 | }, { |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 990 | .type = EM28XX_VMUX_SVIDEO, |
| 991 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 992 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 993 | .gpio = default_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 994 | } }, |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 995 | }, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 996 | /* maybe there's a reason behind it why Terratec sells the Hybrid XS |
| 997 | as Prodigy XS with a different PID, let's keep it separated for now |
| 998 | maybe we'll need it lateron */ |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 999 | [EM2880_BOARD_TERRATEC_PRODIGY_XS] = { |
| 1000 | .name = "Terratec Prodigy XS", |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 1001 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1002 | .tuner_gpio = default_tuner_gpio, |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 1003 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1004 | .input = { { |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 1005 | .type = EM28XX_VMUX_TELEVISION, |
| 1006 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1007 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1008 | .gpio = hauppauge_wintv_hvr_900_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1009 | }, { |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 1010 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1011 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1012 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1013 | .gpio = hauppauge_wintv_hvr_900_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1014 | }, { |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 1015 | .type = EM28XX_VMUX_SVIDEO, |
| 1016 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1017 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1018 | .gpio = hauppauge_wintv_hvr_900_analog, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1019 | } }, |
Mauro Carvalho Chehab | 1246657 | 2007-10-24 11:08:20 -0300 | [diff] [blame] | 1020 | }, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 1021 | [EM2820_BOARD_MSI_VOX_USB_2] = { |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 1022 | .name = "MSI VOX USB 2.0", |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 1023 | .tuner_type = TUNER_LG_PAL_NEW_TAPC, |
| 1024 | .tda9887_conf = TDA9887_PRESENT | |
| 1025 | TDA9887_PORT1_ACTIVE | |
| 1026 | TDA9887_PORT2_ACTIVE, |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 1027 | .max_range_640_480 = 1, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 1028 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 1029 | .input = { { |
| 1030 | .type = EM28XX_VMUX_TELEVISION, |
| 1031 | .vmux = SAA7115_COMPOSITE4, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1032 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1033 | }, { |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 1034 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1035 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1036 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1037 | }, { |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 1038 | .type = EM28XX_VMUX_SVIDEO, |
| 1039 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1040 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1041 | } }, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 1042 | }, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1043 | [EM2800_BOARD_TERRATEC_CINERGY_200] = { |
| 1044 | .name = "Terratec Cinergy 200 USB", |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1045 | .is_em2800 = 1, |
Mauro Carvalho Chehab | ac07bb7 | 2009-09-08 14:04:41 -0300 | [diff] [blame] | 1046 | .has_ir_i2c = 1, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1047 | .tuner_type = TUNER_LG_PAL_NEW_TAPC, |
| 1048 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 1049 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1050 | .input = { { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1051 | .type = EM28XX_VMUX_TELEVISION, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1052 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1053 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1054 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1055 | .type = EM28XX_VMUX_COMPOSITE1, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1056 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1057 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1058 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1059 | .type = EM28XX_VMUX_SVIDEO, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1060 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1061 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1062 | } }, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1063 | }, |
Aron Szabo | 59d07f1 | 2008-07-27 13:47:52 -0300 | [diff] [blame] | 1064 | [EM2800_BOARD_GRABBEEX_USB2800] = { |
Nicola Soranzo | a1a6ee7 | 2009-02-10 23:28:24 -0300 | [diff] [blame] | 1065 | .name = "eMPIA Technology, Inc. GrabBeeX+ Video Encoder", |
| 1066 | .is_em2800 = 1, |
| 1067 | .decoder = EM28XX_SAA711X, |
| 1068 | .tuner_type = TUNER_ABSENT, /* capture only board */ |
| 1069 | .input = { { |
Aron Szabo | 59d07f1 | 2008-07-27 13:47:52 -0300 | [diff] [blame] | 1070 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1071 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1072 | .amux = EM28XX_AMUX_LINE_IN, |
Aron Szabo | 59d07f1 | 2008-07-27 13:47:52 -0300 | [diff] [blame] | 1073 | }, { |
| 1074 | .type = EM28XX_VMUX_SVIDEO, |
| 1075 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1076 | .amux = EM28XX_AMUX_LINE_IN, |
Aron Szabo | 59d07f1 | 2008-07-27 13:47:52 -0300 | [diff] [blame] | 1077 | } }, |
| 1078 | }, |
Mauro Carvalho Chehab | 694a101 | 2009-11-26 21:26:13 -0300 | [diff] [blame] | 1079 | [EM2800_BOARD_VC211A] = { |
| 1080 | .name = "Actionmaster/LinXcel/Digitus VC211A", |
| 1081 | .is_em2800 = 1, |
| 1082 | .tuner_type = TUNER_ABSENT, /* Capture-only board */ |
| 1083 | .decoder = EM28XX_SAA711X, |
| 1084 | .input = { { |
| 1085 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1086 | .vmux = SAA7115_COMPOSITE0, |
| 1087 | .amux = EM28XX_AMUX_LINE_IN, |
| 1088 | .gpio = vc211a_enable, |
| 1089 | }, { |
| 1090 | .type = EM28XX_VMUX_SVIDEO, |
| 1091 | .vmux = SAA7115_SVIDEO3, |
| 1092 | .amux = EM28XX_AMUX_LINE_IN, |
| 1093 | .gpio = vc211a_enable, |
| 1094 | } }, |
| 1095 | }, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1096 | [EM2800_BOARD_LEADTEK_WINFAST_USBII] = { |
| 1097 | .name = "Leadtek Winfast USB II", |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1098 | .is_em2800 = 1, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1099 | .tuner_type = TUNER_LG_PAL_NEW_TAPC, |
| 1100 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 1101 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1102 | .input = { { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1103 | .type = EM28XX_VMUX_TELEVISION, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1104 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1105 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1106 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1107 | .type = EM28XX_VMUX_COMPOSITE1, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1108 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1109 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1110 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1111 | .type = EM28XX_VMUX_SVIDEO, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1112 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1113 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1114 | } }, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1115 | }, |
| 1116 | [EM2800_BOARD_KWORLD_USB2800] = { |
| 1117 | .name = "Kworld USB2800", |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1118 | .is_em2800 = 1, |
Michael Krufky | ab8b870 | 2008-04-22 14:46:05 -0300 | [diff] [blame] | 1119 | .tuner_type = TUNER_PHILIPS_FCV1236D, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1120 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 1121 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1122 | .input = { { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1123 | .type = EM28XX_VMUX_TELEVISION, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1124 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1125 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1126 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1127 | .type = EM28XX_VMUX_COMPOSITE1, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1128 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1129 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1130 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1131 | .type = EM28XX_VMUX_SVIDEO, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1132 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1133 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1134 | } }, |
Mauro Carvalho Chehab | 596d92d | 2005-11-08 21:37:24 -0800 | [diff] [blame] | 1135 | }, |
Mauro Carvalho Chehab | 45632c4 | 2005-11-08 21:38:15 -0800 | [diff] [blame] | 1136 | [EM2820_BOARD_PINNACLE_DVC_90] = { |
Douglas Schilling Landgraf | ea47689 | 2009-09-06 18:41:59 -0300 | [diff] [blame] | 1137 | .name = "Pinnacle Dazzle DVC 90/100/101/107 / Kaiser Baas Video to DVD maker " |
| 1138 | "/ Kworld DVD Maker 2", |
Mauro Carvalho Chehab | 1c67e76 | 2008-11-27 07:46:59 -0300 | [diff] [blame] | 1139 | .tuner_type = TUNER_ABSENT, /* capture only board */ |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 1140 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1141 | .input = { { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1142 | .type = EM28XX_VMUX_COMPOSITE1, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1143 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1144 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1145 | }, { |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1146 | .type = EM28XX_VMUX_SVIDEO, |
Hans Verkuil | c7c0b34 | 2006-04-02 13:35:00 -0300 | [diff] [blame] | 1147 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1148 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1149 | } }, |
Mauro Carvalho Chehab | 45632c4 | 2005-11-08 21:38:15 -0800 | [diff] [blame] | 1150 | }, |
Sascha Sommer | 4362559 | 2007-11-03 15:05:07 -0300 | [diff] [blame] | 1151 | [EM2800_BOARD_VGEAR_POCKETTV] = { |
| 1152 | .name = "V-Gear PocketTV", |
| 1153 | .is_em2800 = 1, |
Sascha Sommer | 4362559 | 2007-11-03 15:05:07 -0300 | [diff] [blame] | 1154 | .tuner_type = TUNER_LG_PAL_NEW_TAPC, |
| 1155 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 1156 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1157 | .input = { { |
Sascha Sommer | 4362559 | 2007-11-03 15:05:07 -0300 | [diff] [blame] | 1158 | .type = EM28XX_VMUX_TELEVISION, |
| 1159 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1160 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1161 | }, { |
Sascha Sommer | 4362559 | 2007-11-03 15:05:07 -0300 | [diff] [blame] | 1162 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1163 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1164 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1165 | }, { |
Sascha Sommer | 4362559 | 2007-11-03 15:05:07 -0300 | [diff] [blame] | 1166 | .type = EM28XX_VMUX_SVIDEO, |
| 1167 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1168 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1169 | } }, |
Sascha Sommer | 4362559 | 2007-11-03 15:05:07 -0300 | [diff] [blame] | 1170 | }, |
Douglas Schilling Landgraf | 1e1addd | 2008-12-27 21:38:14 -0300 | [diff] [blame] | 1171 | [EM2820_BOARD_PROLINK_PLAYTV_BOX4_USB2] = { |
| 1172 | .name = "Pixelview PlayTV Box 4 USB 2.0", |
| 1173 | .tda9887_conf = TDA9887_PRESENT, |
| 1174 | .tuner_type = TUNER_YMEC_TVF_5533MF, |
| 1175 | .decoder = EM28XX_SAA711X, |
| 1176 | .input = { { |
| 1177 | .type = EM28XX_VMUX_TELEVISION, |
| 1178 | .vmux = SAA7115_COMPOSITE2, |
| 1179 | .amux = EM28XX_AMUX_VIDEO, |
| 1180 | .aout = EM28XX_AOUT_MONO | /* I2S */ |
| 1181 | EM28XX_AOUT_MASTER, /* Line out pin */ |
| 1182 | }, { |
| 1183 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1184 | .vmux = SAA7115_COMPOSITE0, |
| 1185 | .amux = EM28XX_AMUX_LINE_IN, |
| 1186 | }, { |
| 1187 | .type = EM28XX_VMUX_SVIDEO, |
| 1188 | .vmux = SAA7115_SVIDEO3, |
| 1189 | .amux = EM28XX_AMUX_LINE_IN, |
| 1190 | } }, |
| 1191 | }, |
Mauro Carvalho Chehab | ea4fd56 | 2007-11-03 21:21:57 -0300 | [diff] [blame] | 1192 | [EM2820_BOARD_PROLINK_PLAYTV_USB2] = { |
Douglas Schilling Landgraf | 1f372a9 | 2009-02-25 16:54:31 -0300 | [diff] [blame] | 1193 | .name = "SIIG AVTuner-PVR / Pixelview Prolink PlayTV USB 2.0", |
Douglas Schilling Landgraf | 5609cfd | 2008-12-27 21:39:35 -0300 | [diff] [blame] | 1194 | .has_snapshot_button = 1, |
Mauro Carvalho Chehab | ea4fd56 | 2007-11-03 21:21:57 -0300 | [diff] [blame] | 1195 | .tda9887_conf = TDA9887_PRESENT, |
Mauro Carvalho Chehab | ed08631 | 2008-01-24 06:59:20 -0300 | [diff] [blame] | 1196 | .tuner_type = TUNER_YMEC_TVF_5533MF, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 1197 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1198 | .input = { { |
Mauro Carvalho Chehab | ea4fd56 | 2007-11-03 21:21:57 -0300 | [diff] [blame] | 1199 | .type = EM28XX_VMUX_TELEVISION, |
| 1200 | .vmux = SAA7115_COMPOSITE2, |
Mauro Carvalho Chehab | 30e4ac7 | 2008-11-20 13:43:05 -0300 | [diff] [blame] | 1201 | .amux = EM28XX_AMUX_VIDEO, |
| 1202 | .aout = EM28XX_AOUT_MONO | /* I2S */ |
| 1203 | EM28XX_AOUT_MASTER, /* Line out pin */ |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1204 | }, { |
Mauro Carvalho Chehab | ea4fd56 | 2007-11-03 21:21:57 -0300 | [diff] [blame] | 1205 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1206 | .vmux = SAA7115_COMPOSITE0, |
Mauro Carvalho Chehab | 7463dda | 2008-02-05 22:29:26 -0300 | [diff] [blame] | 1207 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1208 | }, { |
Mauro Carvalho Chehab | ea4fd56 | 2007-11-03 21:21:57 -0300 | [diff] [blame] | 1209 | .type = EM28XX_VMUX_SVIDEO, |
| 1210 | .vmux = SAA7115_SVIDEO3, |
Mauro Carvalho Chehab | 7463dda | 2008-02-05 22:29:26 -0300 | [diff] [blame] | 1211 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1212 | } }, |
Mauro Carvalho Chehab | ea4fd56 | 2007-11-03 21:21:57 -0300 | [diff] [blame] | 1213 | }, |
Devin Heitmueller | 3ed58ba | 2009-05-27 23:27:26 -0300 | [diff] [blame] | 1214 | [EM2860_BOARD_SAA711X_REFERENCE_DESIGN] = { |
| 1215 | .name = "EM2860/SAA711X Reference Design", |
Devin Heitmueller | a9fc52b | 2008-06-28 08:57:06 -0300 | [diff] [blame] | 1216 | .has_snapshot_button = 1, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1217 | .tuner_type = TUNER_ABSENT, |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 1218 | .decoder = EM28XX_SAA711X, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1219 | .input = { { |
Devin Heitmueller | a9fc52b | 2008-06-28 08:57:06 -0300 | [diff] [blame] | 1220 | .type = EM28XX_VMUX_SVIDEO, |
| 1221 | .vmux = SAA7115_SVIDEO3, |
Devin Heitmueller | 3ed58ba | 2009-05-27 23:27:26 -0300 | [diff] [blame] | 1222 | }, { |
| 1223 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1224 | .vmux = SAA7115_COMPOSITE0, |
Devin Heitmueller | a9fc52b | 2008-06-28 08:57:06 -0300 | [diff] [blame] | 1225 | } }, |
| 1226 | }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1227 | [EM2880_BOARD_MSI_DIGIVOX_AD] = { |
| 1228 | .name = "MSI DigiVox A/D", |
| 1229 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1230 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1231 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1232 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1233 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1234 | .type = EM28XX_VMUX_TELEVISION, |
| 1235 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1236 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1237 | .gpio = em2880_msi_digivox_ad_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1238 | }, { |
| 1239 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1240 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1241 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1242 | .gpio = em2880_msi_digivox_ad_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1243 | }, { |
| 1244 | .type = EM28XX_VMUX_SVIDEO, |
| 1245 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1246 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1247 | .gpio = em2880_msi_digivox_ad_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1248 | } }, |
| 1249 | }, |
| 1250 | [EM2880_BOARD_MSI_DIGIVOX_AD_II] = { |
| 1251 | .name = "MSI DigiVox A/D II", |
| 1252 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1253 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1254 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1255 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1256 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1257 | .type = EM28XX_VMUX_TELEVISION, |
| 1258 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1259 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1260 | .gpio = em2880_msi_digivox_ad_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1261 | }, { |
| 1262 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1263 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1264 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1265 | .gpio = em2880_msi_digivox_ad_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1266 | }, { |
| 1267 | .type = EM28XX_VMUX_SVIDEO, |
| 1268 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1269 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1270 | .gpio = em2880_msi_digivox_ad_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1271 | } }, |
| 1272 | }, |
| 1273 | [EM2880_BOARD_KWORLD_DVB_305U] = { |
| 1274 | .name = "KWorld DVB-T 305U", |
| 1275 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1276 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1277 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1278 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1279 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1280 | .type = EM28XX_VMUX_TELEVISION, |
| 1281 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1282 | .amux = EM28XX_AMUX_VIDEO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1283 | }, { |
| 1284 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1285 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1286 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1287 | }, { |
| 1288 | .type = EM28XX_VMUX_SVIDEO, |
| 1289 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1290 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1291 | } }, |
| 1292 | }, |
| 1293 | [EM2880_BOARD_KWORLD_DVB_310U] = { |
| 1294 | .name = "KWorld DVB-T 310U", |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1295 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1296 | .tuner_gpio = default_tuner_gpio, |
Darron Broad | da3808e | 2008-09-30 02:46:41 -0300 | [diff] [blame] | 1297 | .has_dvb = 1, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1298 | .dvb_gpio = default_digital, |
Darron Broad | da3808e | 2008-09-30 02:46:41 -0300 | [diff] [blame] | 1299 | .mts_firmware = 1, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1300 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1301 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1302 | .type = EM28XX_VMUX_TELEVISION, |
| 1303 | .vmux = TVP5150_COMPOSITE0, |
Darron Broad | da3808e | 2008-09-30 02:46:41 -0300 | [diff] [blame] | 1304 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1305 | .gpio = default_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1306 | }, { |
| 1307 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1308 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | a42aa19 | 2008-11-19 11:08:53 -0300 | [diff] [blame] | 1309 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1310 | .gpio = default_analog, |
Darron Broad | da3808e | 2008-09-30 02:46:41 -0300 | [diff] [blame] | 1311 | }, { /* S-video has not been tested yet */ |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1312 | .type = EM28XX_VMUX_SVIDEO, |
| 1313 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | a42aa19 | 2008-11-19 11:08:53 -0300 | [diff] [blame] | 1314 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1315 | .gpio = default_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1316 | } }, |
| 1317 | }, |
Franklin Meng | d7de5d8 | 2009-06-06 17:05:02 -0300 | [diff] [blame] | 1318 | [EM2882_BOARD_KWORLD_ATSC_315U] = { |
| 1319 | .name = "KWorld ATSC 315U HDTV TV Box", |
| 1320 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
| 1321 | .tuner_type = TUNER_THOMSON_DTT761X, |
| 1322 | .tuner_gpio = em2882_kworld_315u_tuner_gpio, |
| 1323 | .tda9887_conf = TDA9887_PRESENT, |
| 1324 | .decoder = EM28XX_SAA711X, |
| 1325 | .has_dvb = 1, |
| 1326 | .dvb_gpio = em2882_kworld_315u_digital, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 1327 | .ir_codes = RC_MAP_KWORLD_315U, |
Franklin Meng | d7de5d8 | 2009-06-06 17:05:02 -0300 | [diff] [blame] | 1328 | .xclk = EM28XX_XCLK_FREQUENCY_12MHZ, |
| 1329 | .i2c_speed = EM28XX_I2C_CLK_WAIT_ENABLE, |
| 1330 | /* Analog mode - still not ready */ |
| 1331 | /*.input = { { |
| 1332 | .type = EM28XX_VMUX_TELEVISION, |
| 1333 | .vmux = SAA7115_COMPOSITE2, |
| 1334 | .amux = EM28XX_AMUX_VIDEO, |
| 1335 | .gpio = em2882_kworld_315u_analog, |
| 1336 | .aout = EM28XX_AOUT_PCM_IN | EM28XX_AOUT_PCM_STEREO, |
| 1337 | }, { |
| 1338 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1339 | .vmux = SAA7115_COMPOSITE0, |
| 1340 | .amux = EM28XX_AMUX_LINE_IN, |
| 1341 | .gpio = em2882_kworld_315u_analog1, |
| 1342 | .aout = EM28XX_AOUT_PCM_IN | EM28XX_AOUT_PCM_STEREO, |
| 1343 | }, { |
| 1344 | .type = EM28XX_VMUX_SVIDEO, |
| 1345 | .vmux = SAA7115_SVIDEO3, |
| 1346 | .amux = EM28XX_AMUX_LINE_IN, |
| 1347 | .gpio = em2882_kworld_315u_analog1, |
| 1348 | .aout = EM28XX_AOUT_PCM_IN | EM28XX_AOUT_PCM_STEREO, |
| 1349 | } }, */ |
| 1350 | }, |
Douglas Schilling Landgraf | e5db5d4 | 2009-04-09 18:24:34 -0300 | [diff] [blame] | 1351 | [EM2880_BOARD_EMPIRE_DUAL_TV] = { |
| 1352 | .name = "Empire dual TV", |
| 1353 | .tuner_type = TUNER_XC2028, |
| 1354 | .tuner_gpio = default_tuner_gpio, |
| 1355 | .has_dvb = 1, |
| 1356 | .dvb_gpio = default_digital, |
| 1357 | .mts_firmware = 1, |
| 1358 | .decoder = EM28XX_TVP5150, |
| 1359 | .input = { { |
| 1360 | .type = EM28XX_VMUX_TELEVISION, |
| 1361 | .vmux = TVP5150_COMPOSITE0, |
| 1362 | .amux = EM28XX_AMUX_VIDEO, |
| 1363 | .gpio = default_analog, |
| 1364 | }, { |
| 1365 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1366 | .vmux = TVP5150_COMPOSITE1, |
| 1367 | .amux = EM28XX_AMUX_LINE_IN, |
| 1368 | .gpio = default_analog, |
| 1369 | }, { |
| 1370 | .type = EM28XX_VMUX_SVIDEO, |
| 1371 | .vmux = TVP5150_SVIDEO, |
| 1372 | .amux = EM28XX_AMUX_LINE_IN, |
| 1373 | .gpio = default_analog, |
| 1374 | } }, |
| 1375 | }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1376 | [EM2881_BOARD_DNT_DA2_HYBRID] = { |
| 1377 | .name = "DNT DA2 Hybrid", |
| 1378 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1379 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1380 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1381 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1382 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1383 | .type = EM28XX_VMUX_TELEVISION, |
| 1384 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1385 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1386 | .gpio = default_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1387 | }, { |
| 1388 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1389 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1390 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1391 | .gpio = default_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1392 | }, { |
| 1393 | .type = EM28XX_VMUX_SVIDEO, |
| 1394 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1395 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1396 | .gpio = default_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1397 | } }, |
| 1398 | }, |
| 1399 | [EM2881_BOARD_PINNACLE_HYBRID_PRO] = { |
| 1400 | .name = "Pinnacle Hybrid Pro", |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1401 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1402 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1403 | .decoder = EM28XX_TVP5150, |
Devin Heitmueller | d5b3ba9 | 2009-07-08 21:51:35 -0300 | [diff] [blame] | 1404 | .has_dvb = 1, |
| 1405 | .dvb_gpio = pinnacle_hybrid_pro_digital, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1406 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1407 | .type = EM28XX_VMUX_TELEVISION, |
| 1408 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1409 | .amux = EM28XX_AMUX_VIDEO, |
Devin Heitmueller | d5b3ba9 | 2009-07-08 21:51:35 -0300 | [diff] [blame] | 1410 | .gpio = pinnacle_hybrid_pro_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1411 | }, { |
| 1412 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1413 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1414 | .amux = EM28XX_AMUX_LINE_IN, |
Devin Heitmueller | d5b3ba9 | 2009-07-08 21:51:35 -0300 | [diff] [blame] | 1415 | .gpio = pinnacle_hybrid_pro_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1416 | }, { |
| 1417 | .type = EM28XX_VMUX_SVIDEO, |
| 1418 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1419 | .amux = EM28XX_AMUX_LINE_IN, |
Devin Heitmueller | d5b3ba9 | 2009-07-08 21:51:35 -0300 | [diff] [blame] | 1420 | .gpio = pinnacle_hybrid_pro_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1421 | } }, |
| 1422 | }, |
| 1423 | [EM2882_BOARD_PINNACLE_HYBRID_PRO] = { |
| 1424 | .name = "Pinnacle Hybrid Pro (2)", |
| 1425 | .valid = EM28XX_BOARD_NOT_VALIDATED, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1426 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1427 | .tuner_gpio = default_tuner_gpio, |
Eugeniy Meshcheryakov | a674a3b | 2008-08-01 08:23:41 -0300 | [diff] [blame] | 1428 | .mts_firmware = 1, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1429 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1430 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1431 | .type = EM28XX_VMUX_TELEVISION, |
| 1432 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1433 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1434 | .gpio = hauppauge_wintv_hvr_900_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1435 | }, { |
| 1436 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1437 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1438 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1439 | .gpio = hauppauge_wintv_hvr_900_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1440 | }, { |
| 1441 | .type = EM28XX_VMUX_SVIDEO, |
| 1442 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1443 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1444 | .gpio = hauppauge_wintv_hvr_900_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1445 | } }, |
| 1446 | }, |
| 1447 | [EM2882_BOARD_KWORLD_VS_DVBT] = { |
| 1448 | .name = "Kworld VS-DVB-T 323UR", |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1449 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1450 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1451 | .decoder = EM28XX_TVP5150, |
Antonio Larrosa | 811fab6 | 2010-03-04 22:19:48 -0300 | [diff] [blame] | 1452 | .mts_firmware = 1, |
| 1453 | .has_dvb = 1, |
| 1454 | .dvb_gpio = kworld_330u_digital, |
| 1455 | .xclk = EM28XX_XCLK_FREQUENCY_12MHZ, /* NEC IR */ |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 1456 | .ir_codes = RC_MAP_KWORLD_315U, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1457 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1458 | .type = EM28XX_VMUX_TELEVISION, |
| 1459 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1460 | .amux = EM28XX_AMUX_VIDEO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1461 | }, { |
| 1462 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1463 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1464 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1465 | }, { |
| 1466 | .type = EM28XX_VMUX_SVIDEO, |
| 1467 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1468 | .amux = EM28XX_AMUX_LINE_IN, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1469 | } }, |
| 1470 | }, |
| 1471 | [EM2882_BOARD_TERRATEC_HYBRID_XS] = { |
| 1472 | .name = "Terratec Hybrid XS (em2882)", |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1473 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1474 | .tuner_gpio = default_tuner_gpio, |
Uroš Vampl | ec994d0 | 2009-09-30 22:53:37 -0300 | [diff] [blame] | 1475 | .mts_firmware = 1, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1476 | .decoder = EM28XX_TVP5150, |
Uroš Vampl | ec994d0 | 2009-09-30 22:53:37 -0300 | [diff] [blame] | 1477 | .has_dvb = 1, |
| 1478 | .dvb_gpio = hauppauge_wintv_hvr_900_digital, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 1479 | .ir_codes = RC_MAP_TERRATEC_CINERGY_XS, |
Uroš Vampl | ec994d0 | 2009-09-30 22:53:37 -0300 | [diff] [blame] | 1480 | .xclk = EM28XX_XCLK_FREQUENCY_12MHZ, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1481 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1482 | .type = EM28XX_VMUX_TELEVISION, |
| 1483 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1484 | .amux = EM28XX_AMUX_VIDEO, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1485 | .gpio = hauppauge_wintv_hvr_900_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1486 | }, { |
| 1487 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1488 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1489 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1490 | .gpio = hauppauge_wintv_hvr_900_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1491 | }, { |
| 1492 | .type = EM28XX_VMUX_SVIDEO, |
| 1493 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1494 | .amux = EM28XX_AMUX_LINE_IN, |
Mauro Carvalho Chehab | 122b77e | 2008-11-27 07:42:26 -0300 | [diff] [blame] | 1495 | .gpio = hauppauge_wintv_hvr_900_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1496 | } }, |
| 1497 | }, |
Andrea.Amorosi76@gmail.com | 7ca7ef6 | 2010-02-09 17:53:38 -0300 | [diff] [blame] | 1498 | [EM2882_BOARD_DIKOM_DK300] = { |
| 1499 | .name = "Dikom DK300", |
| 1500 | .tuner_type = TUNER_XC2028, |
| 1501 | .tuner_gpio = default_tuner_gpio, |
| 1502 | .decoder = EM28XX_TVP5150, |
| 1503 | .mts_firmware = 1, |
| 1504 | .has_dvb = 1, |
| 1505 | .dvb_gpio = dikom_dk300_digital, |
| 1506 | .input = { { |
| 1507 | .type = EM28XX_VMUX_TELEVISION, |
| 1508 | .vmux = TVP5150_COMPOSITE0, |
| 1509 | .amux = EM28XX_AMUX_VIDEO, |
| 1510 | .gpio = default_analog, |
| 1511 | } }, |
| 1512 | }, |
Robert Krakora | 6e7b9ea | 2009-01-18 21:59:34 -0300 | [diff] [blame] | 1513 | [EM2883_BOARD_KWORLD_HYBRID_330U] = { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1514 | .name = "Kworld PlusTV HD Hybrid 330", |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1515 | .tuner_type = TUNER_XC2028, |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1516 | .tuner_gpio = default_tuner_gpio, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1517 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | be2c6db | 2008-12-09 15:43:10 -0300 | [diff] [blame] | 1518 | .mts_firmware = 1, |
| 1519 | .has_dvb = 1, |
Robert Krakora | 6e7b9ea | 2009-01-18 21:59:34 -0300 | [diff] [blame] | 1520 | .dvb_gpio = kworld_330u_digital, |
| 1521 | .xclk = EM28XX_XCLK_FREQUENCY_12MHZ, |
Nicola Soranzo | a1a6ee7 | 2009-02-10 23:28:24 -0300 | [diff] [blame] | 1522 | .i2c_speed = EM28XX_I2C_CLK_WAIT_ENABLE | |
| 1523 | EM28XX_I2C_EEPROM_ON_BOARD | |
| 1524 | EM28XX_I2C_EEPROM_KEY_VALID, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1525 | .input = { { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1526 | .type = EM28XX_VMUX_TELEVISION, |
| 1527 | .vmux = TVP5150_COMPOSITE0, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1528 | .amux = EM28XX_AMUX_VIDEO, |
Robert Krakora | 6e7b9ea | 2009-01-18 21:59:34 -0300 | [diff] [blame] | 1529 | .gpio = kworld_330u_analog, |
| 1530 | .aout = EM28XX_AOUT_PCM_IN | EM28XX_AOUT_PCM_STEREO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1531 | }, { |
| 1532 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1533 | .vmux = TVP5150_COMPOSITE1, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1534 | .amux = EM28XX_AMUX_LINE_IN, |
Robert Krakora | 6e7b9ea | 2009-01-18 21:59:34 -0300 | [diff] [blame] | 1535 | .gpio = kworld_330u_analog, |
| 1536 | .aout = EM28XX_AOUT_PCM_IN | EM28XX_AOUT_PCM_STEREO, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1537 | }, { |
| 1538 | .type = EM28XX_VMUX_SVIDEO, |
| 1539 | .vmux = TVP5150_SVIDEO, |
Mauro Carvalho Chehab | 8a5caa6 | 2008-11-19 11:10:50 -0300 | [diff] [blame] | 1540 | .amux = EM28XX_AMUX_LINE_IN, |
Robert Krakora | 6e7b9ea | 2009-01-18 21:59:34 -0300 | [diff] [blame] | 1541 | .gpio = kworld_330u_analog, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1542 | } }, |
| 1543 | }, |
Mauro Carvalho Chehab | ee281b8 | 2008-07-27 16:58:04 -0300 | [diff] [blame] | 1544 | [EM2820_BOARD_COMPRO_VIDEOMATE_FORYOU] = { |
Vitaly Wool | d360334 | 2008-07-27 14:10:11 -0300 | [diff] [blame] | 1545 | .name = "Compro VideoMate ForYou/Stereo", |
Vitaly Wool | d360334 | 2008-07-27 14:10:11 -0300 | [diff] [blame] | 1546 | .tuner_type = TUNER_LG_PAL_NEW_TAPC, |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 1547 | .tvaudio_addr = 0xb0, |
Vitaly Wool | d360334 | 2008-07-27 14:10:11 -0300 | [diff] [blame] | 1548 | .tda9887_conf = TDA9887_PRESENT, |
| 1549 | .decoder = EM28XX_TVP5150, |
Mauro Carvalho Chehab | df7fa09 | 2009-02-25 09:06:13 -0300 | [diff] [blame] | 1550 | .adecoder = EM28XX_TVAUDIO, |
Vitaly Wool | 2bd1d9e | 2009-03-04 08:27:52 -0300 | [diff] [blame] | 1551 | .mute_gpio = compro_mute_gpio, |
Mauro Carvalho Chehab | d4d889e | 2008-11-25 09:10:25 -0300 | [diff] [blame] | 1552 | .input = { { |
Vitaly Wool | d360334 | 2008-07-27 14:10:11 -0300 | [diff] [blame] | 1553 | .type = EM28XX_VMUX_TELEVISION, |
| 1554 | .vmux = TVP5150_COMPOSITE0, |
Vitaly Wool | 2bd1d9e | 2009-03-04 08:27:52 -0300 | [diff] [blame] | 1555 | .amux = EM28XX_AMUX_VIDEO, |
| 1556 | .gpio = compro_unmute_tv_gpio, |
Vitaly Wool | d360334 | 2008-07-27 14:10:11 -0300 | [diff] [blame] | 1557 | }, { |
| 1558 | .type = EM28XX_VMUX_SVIDEO, |
| 1559 | .vmux = TVP5150_SVIDEO, |
| 1560 | .amux = EM28XX_AMUX_LINE_IN, |
Vitaly Wool | 2bd1d9e | 2009-03-04 08:27:52 -0300 | [diff] [blame] | 1561 | .gpio = compro_unmute_svid_gpio, |
Vitaly Wool | d360334 | 2008-07-27 14:10:11 -0300 | [diff] [blame] | 1562 | } }, |
| 1563 | }, |
Mauro Carvalho Chehab | 0bf4f6c | 2009-02-11 14:13:20 -0300 | [diff] [blame] | 1564 | [EM2860_BOARD_KAIOMY_TVNPC_U2] = { |
| 1565 | .name = "Kaiomy TVnPC U2", |
| 1566 | .vchannels = 3, |
| 1567 | .tuner_type = TUNER_XC2028, |
| 1568 | .tuner_addr = 0x61, |
| 1569 | .mts_firmware = 1, |
| 1570 | .decoder = EM28XX_TVP5150, |
| 1571 | .tuner_gpio = default_tuner_gpio, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 1572 | .ir_codes = RC_MAP_KAIOMY, |
Mauro Carvalho Chehab | 0bf4f6c | 2009-02-11 14:13:20 -0300 | [diff] [blame] | 1573 | .input = { { |
| 1574 | .type = EM28XX_VMUX_TELEVISION, |
| 1575 | .vmux = TVP5150_COMPOSITE0, |
| 1576 | .amux = EM28XX_AMUX_VIDEO, |
| 1577 | |
| 1578 | }, { |
| 1579 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1580 | .vmux = TVP5150_COMPOSITE1, |
| 1581 | .amux = EM28XX_AMUX_LINE_IN, |
| 1582 | }, { |
| 1583 | .type = EM28XX_VMUX_SVIDEO, |
| 1584 | .vmux = TVP5150_SVIDEO, |
| 1585 | .amux = EM28XX_AMUX_LINE_IN, |
| 1586 | } }, |
| 1587 | .radio = { |
| 1588 | .type = EM28XX_RADIO, |
| 1589 | .amux = EM28XX_AMUX_LINE_IN, |
| 1590 | } |
Mauro Carvalho Chehab | 56ee380 | 2009-02-11 14:18:36 -0300 | [diff] [blame] | 1591 | }, |
| 1592 | [EM2860_BOARD_EASYCAP] = { |
| 1593 | .name = "Easy Cap Capture DC-60", |
| 1594 | .vchannels = 2, |
| 1595 | .tuner_type = TUNER_ABSENT, |
| 1596 | .decoder = EM28XX_SAA711X, |
| 1597 | .input = { { |
| 1598 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1599 | .vmux = SAA7115_COMPOSITE0, |
| 1600 | .amux = EM28XX_AMUX_LINE_IN, |
| 1601 | }, { |
| 1602 | .type = EM28XX_VMUX_SVIDEO, |
| 1603 | .vmux = SAA7115_SVIDEO3, |
| 1604 | .amux = EM28XX_AMUX_LINE_IN, |
| 1605 | } }, |
| 1606 | }, |
Indika Katugampala | f74a61e3 | 2009-02-11 11:13:05 -0300 | [diff] [blame] | 1607 | [EM2820_BOARD_IODATA_GVMVP_SZ] = { |
| 1608 | .name = "IO-DATA GV-MVP/SZ", |
| 1609 | .tuner_type = TUNER_PHILIPS_FM1236_MK3, |
| 1610 | .tuner_gpio = default_tuner_gpio, |
| 1611 | .tda9887_conf = TDA9887_PRESENT, |
| 1612 | .decoder = EM28XX_TVP5150, |
| 1613 | .input = { { |
| 1614 | .type = EM28XX_VMUX_TELEVISION, |
| 1615 | .vmux = TVP5150_COMPOSITE0, |
| 1616 | .amux = EM28XX_AMUX_VIDEO, |
| 1617 | }, { /* Composite has not been tested yet */ |
| 1618 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1619 | .vmux = TVP5150_COMPOSITE1, |
| 1620 | .amux = EM28XX_AMUX_VIDEO, |
| 1621 | }, { /* S-video has not been tested yet */ |
| 1622 | .type = EM28XX_VMUX_SVIDEO, |
| 1623 | .vmux = TVP5150_SVIDEO, |
| 1624 | .amux = EM28XX_AMUX_VIDEO, |
| 1625 | } }, |
| 1626 | }, |
Mauro Carvalho Chehab | 4557af9 | 2009-05-23 09:58:52 -0300 | [diff] [blame] | 1627 | [EM2860_BOARD_TERRATEC_GRABBY] = { |
| 1628 | .name = "Terratec Grabby", |
| 1629 | .vchannels = 2, |
| 1630 | .tuner_type = TUNER_ABSENT, |
| 1631 | .decoder = EM28XX_SAA711X, |
| 1632 | .xclk = EM28XX_XCLK_FREQUENCY_12MHZ, |
| 1633 | .input = { { |
| 1634 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1635 | .vmux = SAA7115_COMPOSITE0, |
| 1636 | .amux = EM28XX_AMUX_VIDEO2, |
| 1637 | }, { |
| 1638 | .type = EM28XX_VMUX_SVIDEO, |
| 1639 | .vmux = SAA7115_SVIDEO3, |
| 1640 | .amux = EM28XX_AMUX_VIDEO2, |
| 1641 | } }, |
| 1642 | }, |
Mauro Carvalho Chehab | 766ed64 | 2009-05-24 00:46:01 -0300 | [diff] [blame] | 1643 | [EM2860_BOARD_TERRATEC_AV350] = { |
| 1644 | .name = "Terratec AV350", |
| 1645 | .vchannels = 2, |
| 1646 | .tuner_type = TUNER_ABSENT, |
| 1647 | .decoder = EM28XX_TVP5150, |
| 1648 | .xclk = EM28XX_XCLK_FREQUENCY_12MHZ, |
| 1649 | .mute_gpio = terratec_av350_mute_gpio, |
| 1650 | .input = { { |
| 1651 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1652 | .vmux = TVP5150_COMPOSITE1, |
| 1653 | .amux = EM28XX_AUDIO_SRC_LINE, |
Jean Delvare | 1df8e98 | 2009-05-13 16:48:07 -0300 | [diff] [blame] | 1654 | .gpio = terratec_av350_unmute_gpio, |
Mauro Carvalho Chehab | 766ed64 | 2009-05-24 00:46:01 -0300 | [diff] [blame] | 1655 | |
| 1656 | }, { |
| 1657 | .type = EM28XX_VMUX_SVIDEO, |
| 1658 | .vmux = TVP5150_SVIDEO, |
| 1659 | .amux = EM28XX_AUDIO_SRC_LINE, |
Jean Delvare | 1df8e98 | 2009-05-13 16:48:07 -0300 | [diff] [blame] | 1660 | .gpio = terratec_av350_unmute_gpio, |
Mauro Carvalho Chehab | 766ed64 | 2009-05-24 00:46:01 -0300 | [diff] [blame] | 1661 | } }, |
| 1662 | }, |
Devin Heitmueller | 1985922 | 2009-06-19 00:33:54 -0300 | [diff] [blame] | 1663 | [EM2882_BOARD_EVGA_INDTUBE] = { |
| 1664 | .name = "Evga inDtube", |
| 1665 | .tuner_type = TUNER_XC2028, |
| 1666 | .tuner_gpio = default_tuner_gpio, |
| 1667 | .decoder = EM28XX_TVP5150, |
Devin Heitmueller | a4c4730 | 2009-06-20 21:34:42 -0300 | [diff] [blame] | 1668 | .xclk = EM28XX_XCLK_FREQUENCY_12MHZ, /* NEC IR */ |
Devin Heitmueller | 1985922 | 2009-06-19 00:33:54 -0300 | [diff] [blame] | 1669 | .mts_firmware = 1, |
| 1670 | .has_dvb = 1, |
| 1671 | .dvb_gpio = evga_indtube_digital, |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 1672 | .ir_codes = RC_MAP_EVGA_INDTUBE, |
Devin Heitmueller | 1985922 | 2009-06-19 00:33:54 -0300 | [diff] [blame] | 1673 | .input = { { |
| 1674 | .type = EM28XX_VMUX_TELEVISION, |
| 1675 | .vmux = TVP5150_COMPOSITE0, |
| 1676 | .amux = EM28XX_AMUX_VIDEO, |
| 1677 | .gpio = evga_indtube_analog, |
| 1678 | }, { |
| 1679 | .type = EM28XX_VMUX_COMPOSITE1, |
| 1680 | .vmux = TVP5150_COMPOSITE1, |
| 1681 | .amux = EM28XX_AMUX_LINE_IN, |
| 1682 | .gpio = evga_indtube_analog, |
| 1683 | }, { |
| 1684 | .type = EM28XX_VMUX_SVIDEO, |
| 1685 | .vmux = TVP5150_SVIDEO, |
| 1686 | .amux = EM28XX_AMUX_LINE_IN, |
| 1687 | .gpio = evga_indtube_analog, |
| 1688 | } }, |
| 1689 | }, |
Antti Palosaari | 285eb1a | 2009-09-15 14:42:13 -0300 | [diff] [blame] | 1690 | /* eb1a:2868 Empia EM2870 + Philips CU1216L NIM (Philips TDA10023 + |
| 1691 | Infineon TUA6034) */ |
| 1692 | [EM2870_BOARD_REDDO_DVB_C_USB_BOX] = { |
| 1693 | .name = "Reddo DVB-C USB TV Box", |
| 1694 | .tuner_type = TUNER_ABSENT, |
Antti Palosaari | 28f4ddd1 | 2009-10-04 12:59:35 -0300 | [diff] [blame] | 1695 | .tuner_gpio = reddo_dvb_c_usb_box, |
Antti Palosaari | 285eb1a | 2009-09-15 14:42:13 -0300 | [diff] [blame] | 1696 | .has_dvb = 1, |
Antti Palosaari | 285eb1a | 2009-09-15 14:42:13 -0300 | [diff] [blame] | 1697 | }, |
Jarod Wilson | 7e48b30 | 2010-03-07 17:55:43 -0300 | [diff] [blame] | 1698 | /* 1b80:a340 - Empia EM2870, NXP TDA18271HD and LG DT3304, sold |
| 1699 | * initially as the KWorld PlusTV 340U, then as the UB435-Q. |
| 1700 | * Early variants have a TDA18271HD/C1, later ones a TDA18271HD/C2 */ |
| 1701 | [EM2870_BOARD_KWORLD_A340] = { |
| 1702 | .name = "KWorld PlusTV 340U or UB435-Q (ATSC)", |
| 1703 | .tuner_type = TUNER_ABSENT, /* Digital-only TDA18271HD */ |
| 1704 | .has_dvb = 1, |
| 1705 | .dvb_gpio = kworld_a340_digital, |
| 1706 | .tuner_gpio = default_tuner_gpio, |
| 1707 | }, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 1708 | }; |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 1709 | const unsigned int em28xx_bcount = ARRAY_SIZE(em28xx_boards); |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 1710 | |
| 1711 | /* table of devices that work with this driver */ |
Nicola Soranzo | a1a6ee7 | 2009-02-10 23:28:24 -0300 | [diff] [blame] | 1712 | struct usb_device_id em28xx_id_table[] = { |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1713 | { USB_DEVICE(0xeb1a, 0x2750), |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1714 | .driver_info = EM2750_BOARD_UNKNOWN }, |
| 1715 | { USB_DEVICE(0xeb1a, 0x2751), |
| 1716 | .driver_info = EM2750_BOARD_UNKNOWN }, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1717 | { USB_DEVICE(0xeb1a, 0x2800), |
| 1718 | .driver_info = EM2800_BOARD_UNKNOWN }, |
Mauro Carvalho Chehab | 9b4e845 | 2009-08-07 12:08:02 -0300 | [diff] [blame] | 1719 | { USB_DEVICE(0xeb1a, 0x2710), |
| 1720 | .driver_info = EM2820_BOARD_UNKNOWN }, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1721 | { USB_DEVICE(0xeb1a, 0x2820), |
| 1722 | .driver_info = EM2820_BOARD_UNKNOWN }, |
| 1723 | { USB_DEVICE(0xeb1a, 0x2821), |
Devin Heitmueller | c665f4d | 2008-12-16 23:35:23 -0300 | [diff] [blame] | 1724 | .driver_info = EM2820_BOARD_UNKNOWN }, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1725 | { USB_DEVICE(0xeb1a, 0x2860), |
| 1726 | .driver_info = EM2820_BOARD_UNKNOWN }, |
| 1727 | { USB_DEVICE(0xeb1a, 0x2861), |
| 1728 | .driver_info = EM2820_BOARD_UNKNOWN }, |
Devin Heitmueller | f91cb65 | 2009-09-30 22:44:19 -0300 | [diff] [blame] | 1729 | { USB_DEVICE(0xeb1a, 0x2862), |
| 1730 | .driver_info = EM2820_BOARD_UNKNOWN }, |
Devin Heitmueller | 443fed9 | 2010-03-19 23:53:12 -0300 | [diff] [blame] | 1731 | { USB_DEVICE(0xeb1a, 0x2863), |
| 1732 | .driver_info = EM2820_BOARD_UNKNOWN }, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1733 | { USB_DEVICE(0xeb1a, 0x2870), |
| 1734 | .driver_info = EM2820_BOARD_UNKNOWN }, |
| 1735 | { USB_DEVICE(0xeb1a, 0x2881), |
| 1736 | .driver_info = EM2820_BOARD_UNKNOWN }, |
| 1737 | { USB_DEVICE(0xeb1a, 0x2883), |
| 1738 | .driver_info = EM2820_BOARD_UNKNOWN }, |
Antti Palosaari | 285eb1a | 2009-09-15 14:42:13 -0300 | [diff] [blame] | 1739 | { USB_DEVICE(0xeb1a, 0x2868), |
| 1740 | .driver_info = EM2820_BOARD_UNKNOWN }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1741 | { USB_DEVICE(0xeb1a, 0xe300), |
| 1742 | .driver_info = EM2861_BOARD_KWORLD_PVRTV_300U }, |
Mauro Carvalho Chehab | 0bf4f6c | 2009-02-11 14:13:20 -0300 | [diff] [blame] | 1743 | { USB_DEVICE(0xeb1a, 0xe303), |
| 1744 | .driver_info = EM2860_BOARD_KAIOMY_TVNPC_U2 }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1745 | { USB_DEVICE(0xeb1a, 0xe305), |
| 1746 | .driver_info = EM2880_BOARD_KWORLD_DVB_305U }, |
| 1747 | { USB_DEVICE(0xeb1a, 0xe310), |
| 1748 | .driver_info = EM2880_BOARD_MSI_DIGIVOX_AD }, |
Franklin Meng | d7de5d8 | 2009-06-06 17:05:02 -0300 | [diff] [blame] | 1749 | { USB_DEVICE(0xeb1a, 0xa313), |
| 1750 | .driver_info = EM2882_BOARD_KWORLD_ATSC_315U }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1751 | { USB_DEVICE(0xeb1a, 0xa316), |
Robert Krakora | 6e7b9ea | 2009-01-18 21:59:34 -0300 | [diff] [blame] | 1752 | .driver_info = EM2883_BOARD_KWORLD_HYBRID_330U }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1753 | { USB_DEVICE(0xeb1a, 0xe320), |
| 1754 | .driver_info = EM2880_BOARD_MSI_DIGIVOX_AD_II }, |
| 1755 | { USB_DEVICE(0xeb1a, 0xe323), |
| 1756 | .driver_info = EM2882_BOARD_KWORLD_VS_DVBT }, |
| 1757 | { USB_DEVICE(0xeb1a, 0xe350), |
| 1758 | .driver_info = EM2870_BOARD_KWORLD_350U }, |
| 1759 | { USB_DEVICE(0xeb1a, 0xe355), |
| 1760 | .driver_info = EM2870_BOARD_KWORLD_355U }, |
| 1761 | { USB_DEVICE(0xeb1a, 0x2801), |
| 1762 | .driver_info = EM2800_BOARD_GRABBEEX_USB2800 }, |
| 1763 | { USB_DEVICE(0xeb1a, 0xe357), |
| 1764 | .driver_info = EM2870_BOARD_KWORLD_355U }, |
Douglas Schilling Landgraf | ac40d9e | 2009-02-25 16:55:48 -0300 | [diff] [blame] | 1765 | { USB_DEVICE(0x1b80, 0xe302), |
| 1766 | .driver_info = EM2820_BOARD_PINNACLE_DVC_90 }, /* Kaiser Baas Video to DVD maker */ |
Douglas Schilling Landgraf | ea47689 | 2009-09-06 18:41:59 -0300 | [diff] [blame] | 1767 | { USB_DEVICE(0x1b80, 0xe304), |
| 1768 | .driver_info = EM2820_BOARD_PINNACLE_DVC_90 }, /* Kworld DVD Maker 2 */ |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1769 | { USB_DEVICE(0x0ccd, 0x0036), |
| 1770 | .driver_info = EM2820_BOARD_TERRATEC_CINERGY_250 }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1771 | { USB_DEVICE(0x0ccd, 0x004c), |
| 1772 | .driver_info = EM2880_BOARD_TERRATEC_HYBRID_XS_FR }, |
| 1773 | { USB_DEVICE(0x0ccd, 0x004f), |
| 1774 | .driver_info = EM2860_BOARD_TERRATEC_HYBRID_XS }, |
| 1775 | { USB_DEVICE(0x0ccd, 0x005e), |
| 1776 | .driver_info = EM2882_BOARD_TERRATEC_HYBRID_XS }, |
| 1777 | { USB_DEVICE(0x0ccd, 0x0042), |
| 1778 | .driver_info = EM2880_BOARD_TERRATEC_HYBRID_XS }, |
| 1779 | { USB_DEVICE(0x0ccd, 0x0043), |
| 1780 | .driver_info = EM2870_BOARD_TERRATEC_XS }, |
| 1781 | { USB_DEVICE(0x0ccd, 0x0047), |
| 1782 | .driver_info = EM2880_BOARD_TERRATEC_PRODIGY_XS }, |
Mauro Carvalho Chehab | 766ed64 | 2009-05-24 00:46:01 -0300 | [diff] [blame] | 1783 | { USB_DEVICE(0x0ccd, 0x0084), |
| 1784 | .driver_info = EM2860_BOARD_TERRATEC_AV350 }, |
Mauro Carvalho Chehab | 4557af9 | 2009-05-23 09:58:52 -0300 | [diff] [blame] | 1785 | { USB_DEVICE(0x0ccd, 0x0096), |
| 1786 | .driver_info = EM2860_BOARD_TERRATEC_GRABBY }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1787 | { USB_DEVICE(0x185b, 0x2870), |
| 1788 | .driver_info = EM2870_BOARD_COMPRO_VIDEOMATE }, |
Vitaly Wool | d360334 | 2008-07-27 14:10:11 -0300 | [diff] [blame] | 1789 | { USB_DEVICE(0x185b, 0x2041), |
Mauro Carvalho Chehab | ee281b8 | 2008-07-27 16:58:04 -0300 | [diff] [blame] | 1790 | .driver_info = EM2820_BOARD_COMPRO_VIDEOMATE_FORYOU }, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1791 | { USB_DEVICE(0x2040, 0x4200), |
| 1792 | .driver_info = EM2820_BOARD_HAUPPAUGE_WINTV_USB_2 }, |
Mauro Carvalho Chehab | 15b9bec | 2008-01-13 12:02:20 -0300 | [diff] [blame] | 1793 | { USB_DEVICE(0x2040, 0x4201), |
| 1794 | .driver_info = EM2820_BOARD_HAUPPAUGE_WINTV_USB_2 }, |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1795 | { USB_DEVICE(0x2040, 0x6500), |
| 1796 | .driver_info = EM2880_BOARD_HAUPPAUGE_WINTV_HVR_900 }, |
Luc Saillard | 427d20c | 2008-01-30 17:23:00 -0300 | [diff] [blame] | 1797 | { USB_DEVICE(0x2040, 0x6502), |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 1798 | .driver_info = EM2880_BOARD_HAUPPAUGE_WINTV_HVR_900_R2 }, |
Michael Krufky | 74ee051 | 2008-05-01 18:02:30 -0300 | [diff] [blame] | 1799 | { USB_DEVICE(0x2040, 0x6513), /* HCW HVR-980 */ |
Mauro Carvalho Chehab | 10ac660 | 2008-07-27 14:58:58 -0300 | [diff] [blame] | 1800 | .driver_info = EM2883_BOARD_HAUPPAUGE_WINTV_HVR_950 }, |
Michael Krufky | 74ee051 | 2008-05-01 18:02:30 -0300 | [diff] [blame] | 1801 | { USB_DEVICE(0x2040, 0x6517), /* HP HVR-950 */ |
Mauro Carvalho Chehab | 10ac660 | 2008-07-27 14:58:58 -0300 | [diff] [blame] | 1802 | .driver_info = EM2883_BOARD_HAUPPAUGE_WINTV_HVR_950 }, |
Michael Krufky | 74ee051 | 2008-05-01 18:02:30 -0300 | [diff] [blame] | 1803 | { USB_DEVICE(0x2040, 0x651b), /* RP HVR-950 */ |
Mauro Carvalho Chehab | 10ac660 | 2008-07-27 14:58:58 -0300 | [diff] [blame] | 1804 | .driver_info = EM2883_BOARD_HAUPPAUGE_WINTV_HVR_950 }, |
Douglas Schilling Landgraf | f89bc32 | 2008-12-01 21:01:04 -0300 | [diff] [blame] | 1805 | { USB_DEVICE(0x2040, 0x651f), |
| 1806 | .driver_info = EM2883_BOARD_HAUPPAUGE_WINTV_HVR_850 }, |
Devin Heitmueller | e14b365 | 2008-07-26 11:04:33 -0300 | [diff] [blame] | 1807 | { USB_DEVICE(0x0438, 0xb002), |
| 1808 | .driver_info = EM2880_BOARD_AMD_ATI_TV_WONDER_HD_600 }, |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 1809 | { USB_DEVICE(0x2001, 0xf112), |
| 1810 | .driver_info = EM2820_BOARD_DLINK_USB_TV }, |
| 1811 | { USB_DEVICE(0x2304, 0x0207), |
| 1812 | .driver_info = EM2820_BOARD_PINNACLE_DVC_90 }, |
| 1813 | { USB_DEVICE(0x2304, 0x0208), |
| 1814 | .driver_info = EM2820_BOARD_PINNACLE_USB_2 }, |
| 1815 | { USB_DEVICE(0x2304, 0x021a), |
| 1816 | .driver_info = EM2820_BOARD_PINNACLE_DVC_90 }, |
| 1817 | { USB_DEVICE(0x2304, 0x0226), |
| 1818 | .driver_info = EM2882_BOARD_PINNACLE_HYBRID_PRO }, |
| 1819 | { USB_DEVICE(0x2304, 0x0227), |
| 1820 | .driver_info = EM2880_BOARD_PINNACLE_PCTV_HD_PRO }, |
| 1821 | { USB_DEVICE(0x0413, 0x6023), |
| 1822 | .driver_info = EM2800_BOARD_LEADTEK_WINFAST_USBII }, |
| 1823 | { USB_DEVICE(0x093b, 0xa005), |
| 1824 | .driver_info = EM2861_BOARD_PLEXTOR_PX_TV100U }, |
Indika Katugampala | f74a61e3 | 2009-02-11 11:13:05 -0300 | [diff] [blame] | 1825 | { USB_DEVICE(0x04bb, 0x0515), |
| 1826 | .driver_info = EM2820_BOARD_IODATA_GVMVP_SZ }, |
Zhenyu Wang | 7c8b567 | 2009-07-05 10:51:21 -0300 | [diff] [blame] | 1827 | { USB_DEVICE(0xeb1a, 0x50a6), |
| 1828 | .driver_info = EM2860_BOARD_GADMEI_UTV330 }, |
Jarod Wilson | 7e48b30 | 2010-03-07 17:55:43 -0300 | [diff] [blame] | 1829 | { USB_DEVICE(0x1b80, 0xa340), |
| 1830 | .driver_info = EM2870_BOARD_KWORLD_A340 }, |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 1831 | { }, |
| 1832 | }; |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1833 | MODULE_DEVICE_TABLE(usb, em28xx_id_table); |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 1834 | |
Mauro Carvalho Chehab | 102a0b0 | 2008-04-17 21:40:45 -0300 | [diff] [blame] | 1835 | /* |
Mauro Carvalho Chehab | 102a0b0 | 2008-04-17 21:40:45 -0300 | [diff] [blame] | 1836 | * EEPROM hash table for devices with generic USB IDs |
| 1837 | */ |
Nicola Soranzo | a1a6ee7 | 2009-02-10 23:28:24 -0300 | [diff] [blame] | 1838 | static struct em28xx_hash_table em28xx_eeprom_hash[] = { |
Mauro Carvalho Chehab | ea4fd56 | 2007-11-03 21:21:57 -0300 | [diff] [blame] | 1839 | /* P/N: SA 60002070465 Tuner: TVF7533-MF */ |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1840 | {0x6ce05a8f, EM2820_BOARD_PROLINK_PLAYTV_USB2, TUNER_YMEC_TVF_5533MF}, |
Douglas Schilling Landgraf | 1e1addd | 2008-12-27 21:38:14 -0300 | [diff] [blame] | 1841 | {0x72cc5a8b, EM2820_BOARD_PROLINK_PLAYTV_BOX4_USB2, TUNER_YMEC_TVF_5533MF}, |
Darron Broad | da3808e | 2008-09-30 02:46:41 -0300 | [diff] [blame] | 1842 | {0x966a0441, EM2880_BOARD_KWORLD_DVB_310U, TUNER_XC2028}, |
Douglas Schilling Landgraf | a35c87c | 2009-08-06 12:52:11 -0300 | [diff] [blame] | 1843 | {0x166a0441, EM2880_BOARD_EMPIRE_DUAL_TV, TUNER_XC2028}, |
Devin Heitmueller | 1985922 | 2009-06-19 00:33:54 -0300 | [diff] [blame] | 1844 | {0xcee44a99, EM2882_BOARD_EVGA_INDTUBE, TUNER_XC2028}, |
Devin Heitmueller | d5b3ba9 | 2009-07-08 21:51:35 -0300 | [diff] [blame] | 1845 | {0xb8846b20, EM2881_BOARD_PINNACLE_HYBRID_PRO, TUNER_XC2028}, |
Antti Palosaari | 285eb1a | 2009-09-15 14:42:13 -0300 | [diff] [blame] | 1846 | {0x63f653bd, EM2870_BOARD_REDDO_DVB_C_USB_BOX, TUNER_ABSENT}, |
Andrea.Amorosi76@gmail.com | 7ca7ef6 | 2010-02-09 17:53:38 -0300 | [diff] [blame] | 1847 | {0x4e913442, EM2882_BOARD_DIKOM_DK300, TUNER_XC2028}, |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 1848 | }; |
| 1849 | |
Mauro Carvalho Chehab | d2ba055 | 2007-11-04 08:32:42 -0300 | [diff] [blame] | 1850 | /* I2C devicelist hash table for devices with generic USB IDs */ |
Sascha Sommer | fad7b95 | 2007-11-04 08:06:48 -0300 | [diff] [blame] | 1851 | static struct em28xx_hash_table em28xx_i2c_hash[] = { |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 1852 | {0xb06a32c3, EM2800_BOARD_TERRATEC_CINERGY_200, TUNER_LG_PAL_NEW_TAPC}, |
| 1853 | {0xf51200e3, EM2800_BOARD_VGEAR_POCKETTV, TUNER_LG_PAL_NEW_TAPC}, |
Devin Heitmueller | 3ed58ba | 2009-05-27 23:27:26 -0300 | [diff] [blame] | 1854 | {0x1ba50080, EM2860_BOARD_SAA711X_REFERENCE_DESIGN, TUNER_ABSENT}, |
Devin Heitmueller | 443fed9 | 2010-03-19 23:53:12 -0300 | [diff] [blame] | 1855 | {0x77800080, EM2860_BOARD_TVP5150_REFERENCE_DESIGN, TUNER_ABSENT}, |
Douglas Schilling Landgraf | f7fe3e6 | 2009-01-19 09:31:55 -0300 | [diff] [blame] | 1856 | {0xc51200e3, EM2820_BOARD_GADMEI_TVR200, TUNER_LG_PAL_NEW_TAPC}, |
Mauro Carvalho Chehab | 6d888a6 | 2009-08-30 13:05:56 -0300 | [diff] [blame] | 1857 | {0x4ba50080, EM2861_BOARD_GADMEI_UTV330PLUS, TUNER_TNF_5335MF}, |
Sascha Sommer | fad7b95 | 2007-11-04 08:06:48 -0300 | [diff] [blame] | 1858 | }; |
| 1859 | |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 1860 | /* I2C possible address to saa7115, tvp5150, msp3400, tvaudio */ |
| 1861 | static unsigned short saa711x_addrs[] = { |
| 1862 | 0x4a >> 1, 0x48 >> 1, /* SAA7111, SAA7111A and SAA7113 */ |
| 1863 | 0x42 >> 1, 0x40 >> 1, /* SAA7114, SAA7115 and SAA7118 */ |
| 1864 | I2C_CLIENT_END }; |
| 1865 | |
| 1866 | static unsigned short tvp5150_addrs[] = { |
| 1867 | 0xb8 >> 1, |
| 1868 | 0xba >> 1, |
| 1869 | I2C_CLIENT_END |
| 1870 | }; |
| 1871 | |
Mauro Carvalho Chehab | 02e7804 | 2009-06-29 11:35:05 -0300 | [diff] [blame] | 1872 | static unsigned short mt9v011_addrs[] = { |
| 1873 | 0xba >> 1, |
| 1874 | I2C_CLIENT_END |
| 1875 | }; |
| 1876 | |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 1877 | static unsigned short msp3400_addrs[] = { |
| 1878 | 0x80 >> 1, |
| 1879 | 0x88 >> 1, |
| 1880 | I2C_CLIENT_END |
| 1881 | }; |
| 1882 | |
Michael Krufky | d7cba04 | 2008-09-12 13:31:45 -0300 | [diff] [blame] | 1883 | int em28xx_tuner_callback(void *ptr, int component, int command, int arg) |
Mauro Carvalho Chehab | ee6e3a8 | 2008-04-17 21:37:31 -0300 | [diff] [blame] | 1884 | { |
Mauro Carvalho Chehab | 102a0b0 | 2008-04-17 21:40:45 -0300 | [diff] [blame] | 1885 | int rc = 0; |
Mauro Carvalho Chehab | ee6e3a8 | 2008-04-17 21:37:31 -0300 | [diff] [blame] | 1886 | struct em28xx *dev = ptr; |
Mauro Carvalho Chehab | ee6e3a8 | 2008-04-17 21:37:31 -0300 | [diff] [blame] | 1887 | |
| 1888 | if (dev->tuner_type != TUNER_XC2028) |
| 1889 | return 0; |
| 1890 | |
| 1891 | if (command != XC2028_TUNER_RESET) |
| 1892 | return 0; |
| 1893 | |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 1894 | rc = em28xx_gpio_set(dev, dev->board.tuner_gpio); |
Mauro Carvalho Chehab | ee6e3a8 | 2008-04-17 21:37:31 -0300 | [diff] [blame] | 1895 | |
Mauro Carvalho Chehab | ee6e3a8 | 2008-04-17 21:37:31 -0300 | [diff] [blame] | 1896 | return rc; |
| 1897 | } |
| 1898 | EXPORT_SYMBOL_GPL(em28xx_tuner_callback); |
| 1899 | |
Nicola Soranzo | a1a6ee7 | 2009-02-10 23:28:24 -0300 | [diff] [blame] | 1900 | static inline void em28xx_set_model(struct em28xx *dev) |
Mauro Carvalho Chehab | ee6e3a8 | 2008-04-17 21:37:31 -0300 | [diff] [blame] | 1901 | { |
Mauro Carvalho Chehab | 505b6d0 | 2008-11-25 09:39:50 -0300 | [diff] [blame] | 1902 | memcpy(&dev->board, &em28xx_boards[dev->model], sizeof(dev->board)); |
Devin Heitmueller | ed14e1c | 2008-12-29 22:27:30 -0300 | [diff] [blame] | 1903 | |
| 1904 | /* Those are the default values for the majority of boards |
| 1905 | Use those values if not specified otherwise at boards entry |
| 1906 | */ |
| 1907 | if (!dev->board.xclk) |
| 1908 | dev->board.xclk = EM28XX_XCLK_IR_RC5_MODE | |
| 1909 | EM28XX_XCLK_FREQUENCY_12MHZ; |
| 1910 | |
| 1911 | if (!dev->board.i2c_speed) |
| 1912 | dev->board.i2c_speed = EM28XX_I2C_CLK_WAIT_ENABLE | |
| 1913 | EM28XX_I2C_FREQ_100_KHZ; |
Mauro Carvalho Chehab | ee6e3a8 | 2008-04-17 21:37:31 -0300 | [diff] [blame] | 1914 | } |
| 1915 | |
Mauro Carvalho Chehab | f2e26ae | 2009-08-12 20:21:44 -0300 | [diff] [blame] | 1916 | |
| 1917 | /* FIXME: Should be replaced by a proper mt9m111 driver */ |
| 1918 | static int em28xx_initialize_mt9m111(struct em28xx *dev) |
| 1919 | { |
| 1920 | int i; |
| 1921 | unsigned char regs[][3] = { |
| 1922 | { 0x0d, 0x00, 0x01, }, /* reset and use defaults */ |
| 1923 | { 0x0d, 0x00, 0x00, }, |
| 1924 | { 0x0a, 0x00, 0x21, }, |
| 1925 | { 0x21, 0x04, 0x00, }, /* full readout speed, no row/col skipping */ |
| 1926 | }; |
| 1927 | |
| 1928 | for (i = 0; i < ARRAY_SIZE(regs); i++) |
| 1929 | i2c_master_send(&dev->i2c_client, ®s[i][0], 3); |
| 1930 | |
| 1931 | return 0; |
| 1932 | } |
| 1933 | |
| 1934 | |
Mauro Carvalho Chehab | b80fd2d | 2009-07-14 21:08:22 -0300 | [diff] [blame] | 1935 | /* FIXME: Should be replaced by a proper mt9m001 driver */ |
| 1936 | static int em28xx_initialize_mt9m001(struct em28xx *dev) |
| 1937 | { |
| 1938 | int i; |
| 1939 | unsigned char regs[][3] = { |
| 1940 | { 0x0d, 0x00, 0x01, }, |
| 1941 | { 0x0d, 0x00, 0x00, }, |
| 1942 | { 0x04, 0x05, 0x00, }, /* hres = 1280 */ |
| 1943 | { 0x03, 0x04, 0x00, }, /* vres = 1024 */ |
| 1944 | { 0x20, 0x11, 0x00, }, |
| 1945 | { 0x06, 0x00, 0x10, }, |
| 1946 | { 0x2b, 0x00, 0x24, }, |
| 1947 | { 0x2e, 0x00, 0x24, }, |
| 1948 | { 0x35, 0x00, 0x24, }, |
| 1949 | { 0x2d, 0x00, 0x20, }, |
| 1950 | { 0x2c, 0x00, 0x20, }, |
| 1951 | { 0x09, 0x0a, 0xd4, }, |
| 1952 | { 0x35, 0x00, 0x57, }, |
| 1953 | }; |
| 1954 | |
| 1955 | for (i = 0; i < ARRAY_SIZE(regs); i++) |
| 1956 | i2c_master_send(&dev->i2c_client, ®s[i][0], 3); |
| 1957 | |
| 1958 | return 0; |
| 1959 | } |
| 1960 | |
Mauro Carvalho Chehab | 791a08f | 2009-07-03 15:36:18 -0300 | [diff] [blame] | 1961 | /* HINT method: webcam I2C chips |
| 1962 | * |
Mauro Carvalho Chehab | f2e26ae | 2009-08-12 20:21:44 -0300 | [diff] [blame] | 1963 | * This method works for webcams with Micron sensors |
Mauro Carvalho Chehab | 791a08f | 2009-07-03 15:36:18 -0300 | [diff] [blame] | 1964 | */ |
| 1965 | static int em28xx_hint_sensor(struct em28xx *dev) |
| 1966 | { |
| 1967 | int rc; |
| 1968 | char *sensor_name; |
| 1969 | unsigned char cmd; |
| 1970 | __be16 version_be; |
| 1971 | u16 version; |
| 1972 | |
Mauro Carvalho Chehab | 3d3215c | 2009-08-10 10:29:27 -0300 | [diff] [blame] | 1973 | /* Micron sensor detection */ |
Mauro Carvalho Chehab | 791a08f | 2009-07-03 15:36:18 -0300 | [diff] [blame] | 1974 | dev->i2c_client.addr = 0xba >> 1; |
| 1975 | cmd = 0; |
| 1976 | i2c_master_send(&dev->i2c_client, &cmd, 1); |
| 1977 | rc = i2c_master_recv(&dev->i2c_client, (char *)&version_be, 2); |
| 1978 | if (rc != 2) |
| 1979 | return -EINVAL; |
| 1980 | |
| 1981 | version = be16_to_cpu(version_be); |
Mauro Carvalho Chehab | 791a08f | 2009-07-03 15:36:18 -0300 | [diff] [blame] | 1982 | switch (version) { |
Mauro Carvalho Chehab | 296544e | 2009-07-27 08:24:29 -0300 | [diff] [blame] | 1983 | case 0x8232: /* mt9v011 640x480 1.3 Mpix sensor */ |
| 1984 | case 0x8243: /* mt9v011 rev B 640x480 1.3 Mpix sensor */ |
Mauro Carvalho Chehab | 791a08f | 2009-07-03 15:36:18 -0300 | [diff] [blame] | 1985 | dev->model = EM2820_BOARD_SILVERCREST_WEBCAM; |
Mauro Carvalho Chehab | 3d3215c | 2009-08-10 10:29:27 -0300 | [diff] [blame] | 1986 | em28xx_set_model(dev); |
| 1987 | |
Mauro Carvalho Chehab | 791a08f | 2009-07-03 15:36:18 -0300 | [diff] [blame] | 1988 | sensor_name = "mt9v011"; |
Mauro Carvalho Chehab | 527f09a | 2009-07-12 11:04:15 -0300 | [diff] [blame] | 1989 | dev->em28xx_sensor = EM28XX_MT9V011; |
Mauro Carvalho Chehab | 5569996 | 2009-07-13 20:15:02 -0300 | [diff] [blame] | 1990 | dev->sensor_xres = 640; |
| 1991 | dev->sensor_yres = 480; |
Mauro Carvalho Chehab | 3d3215c | 2009-08-10 10:29:27 -0300 | [diff] [blame] | 1992 | /* |
| 1993 | * FIXME: mt9v011 uses I2S speed as xtal clk - at least with |
| 1994 | * the Silvercrest cam I have here for testing - for higher |
| 1995 | * resolutions, a high clock cause horizontal artifacts, so we |
| 1996 | * need to use a lower xclk frequency. |
| 1997 | * Yet, it would be possible to adjust xclk depending on the |
| 1998 | * desired resolution, since this affects directly the |
| 1999 | * frame rate. |
| 2000 | */ |
| 2001 | dev->board.xclk = EM28XX_XCLK_FREQUENCY_4_3MHZ; |
| 2002 | dev->sensor_xtal = 4300000; |
Mauro Carvalho Chehab | 579d315 | 2009-07-14 12:33:25 -0300 | [diff] [blame] | 2003 | |
| 2004 | /* probably means GRGB 16 bit bayer */ |
| 2005 | dev->vinmode = 0x0d; |
| 2006 | dev->vinctl = 0x00; |
| 2007 | |
Mauro Carvalho Chehab | 791a08f | 2009-07-03 15:36:18 -0300 | [diff] [blame] | 2008 | break; |
Mauro Carvalho Chehab | f2e26ae | 2009-08-12 20:21:44 -0300 | [diff] [blame] | 2009 | |
| 2010 | case 0x143a: /* MT9M111 as found in the ECS G200 */ |
| 2011 | dev->model = EM2750_BOARD_UNKNOWN; |
| 2012 | em28xx_set_model(dev); |
| 2013 | |
| 2014 | sensor_name = "mt9m111"; |
| 2015 | dev->board.xclk = EM28XX_XCLK_FREQUENCY_48MHZ; |
| 2016 | dev->em28xx_sensor = EM28XX_MT9M111; |
| 2017 | em28xx_initialize_mt9m111(dev); |
| 2018 | dev->sensor_xres = 640; |
| 2019 | dev->sensor_yres = 512; |
| 2020 | |
| 2021 | dev->vinmode = 0x0a; |
| 2022 | dev->vinctl = 0x00; |
| 2023 | |
| 2024 | break; |
| 2025 | |
Mauro Carvalho Chehab | b80fd2d | 2009-07-14 21:08:22 -0300 | [diff] [blame] | 2026 | case 0x8431: |
| 2027 | dev->model = EM2750_BOARD_UNKNOWN; |
Mauro Carvalho Chehab | 3d3215c | 2009-08-10 10:29:27 -0300 | [diff] [blame] | 2028 | em28xx_set_model(dev); |
| 2029 | |
Mauro Carvalho Chehab | b80fd2d | 2009-07-14 21:08:22 -0300 | [diff] [blame] | 2030 | sensor_name = "mt9m001"; |
| 2031 | dev->em28xx_sensor = EM28XX_MT9M001; |
| 2032 | em28xx_initialize_mt9m001(dev); |
| 2033 | dev->sensor_xres = 1280; |
| 2034 | dev->sensor_yres = 1024; |
| 2035 | |
| 2036 | /* probably means BGGR 16 bit bayer */ |
| 2037 | dev->vinmode = 0x0c; |
| 2038 | dev->vinctl = 0x00; |
| 2039 | |
| 2040 | break; |
Mauro Carvalho Chehab | 791a08f | 2009-07-03 15:36:18 -0300 | [diff] [blame] | 2041 | default: |
Mauro Carvalho Chehab | f2e26ae | 2009-08-12 20:21:44 -0300 | [diff] [blame] | 2042 | printk("Unknown Micron Sensor 0x%04x\n", version); |
Mauro Carvalho Chehab | 791a08f | 2009-07-03 15:36:18 -0300 | [diff] [blame] | 2043 | return -EINVAL; |
| 2044 | } |
| 2045 | |
Mauro Carvalho Chehab | 3d3215c | 2009-08-10 10:29:27 -0300 | [diff] [blame] | 2046 | /* Setup webcam defaults */ |
| 2047 | em28xx_pre_card_setup(dev); |
| 2048 | |
Mauro Carvalho Chehab | 8b22079 | 2009-07-12 10:56:21 -0300 | [diff] [blame] | 2049 | em28xx_errdev("Sensor is %s, using model %s entry.\n", |
Mauro Carvalho Chehab | 791a08f | 2009-07-03 15:36:18 -0300 | [diff] [blame] | 2050 | sensor_name, em28xx_boards[dev->model].name); |
| 2051 | |
| 2052 | return 0; |
| 2053 | } |
| 2054 | |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2055 | /* Since em28xx_pre_card_setup() requires a proper dev->model, |
| 2056 | * this won't work for boards with generic PCI IDs |
| 2057 | */ |
Markus Rechberger | a94e95b | 2006-01-23 17:11:10 -0200 | [diff] [blame] | 2058 | void em28xx_pre_card_setup(struct em28xx *dev) |
| 2059 | { |
Devin Heitmueller | ed14e1c | 2008-12-29 22:27:30 -0300 | [diff] [blame] | 2060 | /* Set the initial XCLK and I2C clock values based on the board |
| 2061 | definition */ |
Mauro Carvalho Chehab | 505b6d0 | 2008-11-25 09:39:50 -0300 | [diff] [blame] | 2062 | em28xx_write_reg(dev, EM28XX_R0F_XCLK, dev->board.xclk & 0x7f); |
| 2063 | em28xx_write_reg(dev, EM28XX_R06_I2C_CLK, dev->board.i2c_speed); |
Mauro Carvalho Chehab | a2070c6 | 2008-11-25 07:05:06 -0300 | [diff] [blame] | 2064 | msleep(50); |
| 2065 | |
Markus Rechberger | a94e95b | 2006-01-23 17:11:10 -0200 | [diff] [blame] | 2066 | /* request some modules */ |
Mauro Carvalho Chehab | c23f594 | 2007-11-23 14:22:14 -0300 | [diff] [blame] | 2067 | switch (dev->model) { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2068 | case EM2861_BOARD_PLEXTOR_PX_TV100U: |
Mauro Carvalho Chehab | 0a6e44d | 2009-07-29 01:39:12 -0300 | [diff] [blame] | 2069 | /* Sets the msp34xx I2S speed */ |
| 2070 | dev->i2s_speed = 2048000; |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2071 | break; |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2072 | case EM2861_BOARD_KWORLD_PVRTV_300U: |
| 2073 | case EM2880_BOARD_KWORLD_DVB_305U: |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2074 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0x6d); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2075 | msleep(10); |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2076 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0x7d); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2077 | msleep(10); |
| 2078 | break; |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2079 | case EM2870_BOARD_COMPRO_VIDEOMATE: |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2080 | /* TODO: someone can do some cleanup here... |
| 2081 | not everything's needed */ |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2082 | em28xx_write_reg(dev, EM2880_R04_GPO, 0x00); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2083 | msleep(10); |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2084 | em28xx_write_reg(dev, EM2880_R04_GPO, 0x01); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2085 | msleep(10); |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2086 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfd); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2087 | mdelay(70); |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2088 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfc); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2089 | mdelay(70); |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2090 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xdc); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2091 | mdelay(70); |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2092 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfc); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2093 | mdelay(70); |
| 2094 | break; |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2095 | case EM2870_BOARD_TERRATEC_XS_MT2060: |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2096 | /* this device needs some gpio writes to get the DVB-T |
| 2097 | demod work */ |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2098 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfe); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2099 | mdelay(70); |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2100 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xde); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2101 | mdelay(70); |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2102 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfe); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2103 | mdelay(70); |
| 2104 | break; |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2105 | case EM2870_BOARD_PINNACLE_PCTV_DVB: |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2106 | /* this device needs some gpio writes to get the |
| 2107 | DVB-T demod work */ |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2108 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfe); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2109 | mdelay(70); |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2110 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xde); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2111 | mdelay(70); |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2112 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfe); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2113 | mdelay(70); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2114 | break; |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2115 | case EM2820_BOARD_GADMEI_UTV310: |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2116 | case EM2820_BOARD_MSI_VOX_USB_2: |
Mauro Carvalho Chehab | a2070c6 | 2008-11-25 07:05:06 -0300 | [diff] [blame] | 2117 | /* enables audio for that devices */ |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2118 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfd); |
Mauro Carvalho Chehab | 102a0b0 | 2008-04-17 21:40:45 -0300 | [diff] [blame] | 2119 | break; |
Mauro Carvalho Chehab | 0bf4f6c | 2009-02-11 14:13:20 -0300 | [diff] [blame] | 2120 | |
Franklin Meng | d7de5d8 | 2009-06-06 17:05:02 -0300 | [diff] [blame] | 2121 | case EM2882_BOARD_KWORLD_ATSC_315U: |
| 2122 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xff); |
| 2123 | msleep(10); |
| 2124 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfe); |
| 2125 | msleep(10); |
| 2126 | em28xx_write_reg(dev, EM2880_R04_GPO, 0x00); |
| 2127 | msleep(10); |
| 2128 | em28xx_write_reg(dev, EM2880_R04_GPO, 0x08); |
| 2129 | msleep(10); |
| 2130 | break; |
| 2131 | |
Mauro Carvalho Chehab | 0bf4f6c | 2009-02-11 14:13:20 -0300 | [diff] [blame] | 2132 | case EM2860_BOARD_KAIOMY_TVNPC_U2: |
| 2133 | em28xx_write_regs(dev, EM28XX_R0F_XCLK, "\x07", 1); |
| 2134 | em28xx_write_regs(dev, EM28XX_R06_I2C_CLK, "\x40", 1); |
| 2135 | em28xx_write_regs(dev, 0x0d, "\x42", 1); |
| 2136 | em28xx_write_regs(dev, 0x08, "\xfd", 1); |
| 2137 | msleep(10); |
| 2138 | em28xx_write_regs(dev, 0x08, "\xff", 1); |
| 2139 | msleep(10); |
| 2140 | em28xx_write_regs(dev, 0x08, "\x7f", 1); |
| 2141 | msleep(10); |
| 2142 | em28xx_write_regs(dev, 0x08, "\x6b", 1); |
| 2143 | |
| 2144 | break; |
Mauro Carvalho Chehab | 56ee380 | 2009-02-11 14:18:36 -0300 | [diff] [blame] | 2145 | case EM2860_BOARD_EASYCAP: |
| 2146 | em28xx_write_regs(dev, 0x08, "\xf8", 1); |
| 2147 | break; |
| 2148 | |
Indika Katugampala | f74a61e3 | 2009-02-11 11:13:05 -0300 | [diff] [blame] | 2149 | case EM2820_BOARD_IODATA_GVMVP_SZ: |
| 2150 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xff); |
| 2151 | msleep(70); |
| 2152 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xf7); |
| 2153 | msleep(10); |
| 2154 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfe); |
| 2155 | msleep(70); |
| 2156 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfd); |
| 2157 | msleep(70); |
| 2158 | break; |
Mauro Carvalho Chehab | 102a0b0 | 2008-04-17 21:40:45 -0300 | [diff] [blame] | 2159 | } |
Mauro Carvalho Chehab | c67ec53 | 2008-04-17 21:48:00 -0300 | [diff] [blame] | 2160 | |
Mauro Carvalho Chehab | 017ab4b | 2008-11-27 09:21:55 -0300 | [diff] [blame] | 2161 | em28xx_gpio_set(dev, dev->board.tuner_gpio); |
Mauro Carvalho Chehab | c67ec53 | 2008-04-17 21:48:00 -0300 | [diff] [blame] | 2162 | em28xx_set_mode(dev, EM28XX_ANALOG_MODE); |
| 2163 | |
| 2164 | /* Unlock device */ |
Mauro Carvalho Chehab | 2fe3e2e | 2008-11-27 09:10:40 -0300 | [diff] [blame] | 2165 | em28xx_set_mode(dev, EM28XX_SUSPEND); |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2166 | } |
| 2167 | |
Mauro Carvalho Chehab | e54318e | 2008-04-18 18:34:31 -0300 | [diff] [blame] | 2168 | static void em28xx_setup_xc3028(struct em28xx *dev, struct xc2028_ctrl *ctl) |
Mauro Carvalho Chehab | 3ca9c09 | 2008-04-17 21:37:53 -0300 | [diff] [blame] | 2169 | { |
| 2170 | memset(ctl, 0, sizeof(*ctl)); |
| 2171 | |
| 2172 | ctl->fname = XC2028_DEFAULT_FIRMWARE; |
| 2173 | ctl->max_len = 64; |
| 2174 | ctl->mts = em28xx_boards[dev->model].mts_firmware; |
| 2175 | |
| 2176 | switch (dev->model) { |
Douglas Schilling Landgraf | e5db5d4 | 2009-04-09 18:24:34 -0300 | [diff] [blame] | 2177 | case EM2880_BOARD_EMPIRE_DUAL_TV: |
Mauro Carvalho Chehab | e77ebda | 2008-04-18 18:37:25 -0300 | [diff] [blame] | 2178 | case EM2880_BOARD_HAUPPAUGE_WINTV_HVR_900: |
Uroš Vampl | ec994d0 | 2009-09-30 22:53:37 -0300 | [diff] [blame] | 2179 | case EM2882_BOARD_TERRATEC_HYBRID_XS: |
Mauro Carvalho Chehab | e77ebda | 2008-04-18 18:37:25 -0300 | [diff] [blame] | 2180 | ctl->demod = XC3028_FE_ZARLINK456; |
| 2181 | break; |
reinhard schwab | 655b840 | 2008-07-26 10:47:00 -0300 | [diff] [blame] | 2182 | case EM2880_BOARD_TERRATEC_HYBRID_XS: |
Michel Garnier | cec4e6c | 2010-10-16 14:42:01 -0300 | [diff] [blame^] | 2183 | case EM2880_BOARD_TERRATEC_HYBRID_XS_FR: |
Devin Heitmueller | e16e5a3 | 2009-07-15 00:37:22 -0300 | [diff] [blame] | 2184 | case EM2881_BOARD_PINNACLE_HYBRID_PRO: |
reinhard schwab | 655b840 | 2008-07-26 10:47:00 -0300 | [diff] [blame] | 2185 | ctl->demod = XC3028_FE_ZARLINK456; |
| 2186 | break; |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 2187 | case EM2880_BOARD_HAUPPAUGE_WINTV_HVR_900_R2: |
| 2188 | /* djh - Not sure which demod we need here */ |
| 2189 | ctl->demod = XC3028_FE_DEFAULT; |
| 2190 | break; |
Devin Heitmueller | 5ea7fe4 | 2008-09-16 02:02:12 -0300 | [diff] [blame] | 2191 | case EM2880_BOARD_AMD_ATI_TV_WONDER_HD_600: |
| 2192 | ctl->demod = XC3028_FE_DEFAULT; |
| 2193 | ctl->fname = XC3028L_DEFAULT_FIRMWARE; |
| 2194 | break; |
Douglas Schilling Landgraf | f89bc32 | 2008-12-01 21:01:04 -0300 | [diff] [blame] | 2195 | case EM2883_BOARD_HAUPPAUGE_WINTV_HVR_850: |
Mauro Carvalho Chehab | 10ac660 | 2008-07-27 14:58:58 -0300 | [diff] [blame] | 2196 | case EM2883_BOARD_HAUPPAUGE_WINTV_HVR_950: |
Devin Heitmueller | 4fd305b | 2008-06-04 13:43:46 -0300 | [diff] [blame] | 2197 | case EM2880_BOARD_PINNACLE_PCTV_HD_PRO: |
Mauro Carvalho Chehab | e77ebda | 2008-04-18 18:37:25 -0300 | [diff] [blame] | 2198 | /* FIXME: Better to specify the needed IF */ |
Devin Heitmueller | bdfbf95 | 2008-04-17 21:38:27 -0300 | [diff] [blame] | 2199 | ctl->demod = XC3028_FE_DEFAULT; |
| 2200 | break; |
Robert Krakora | 6e7b9ea | 2009-01-18 21:59:34 -0300 | [diff] [blame] | 2201 | case EM2883_BOARD_KWORLD_HYBRID_330U: |
Andrea.Amorosi76@gmail.com | 7ca7ef6 | 2010-02-09 17:53:38 -0300 | [diff] [blame] | 2202 | case EM2882_BOARD_DIKOM_DK300: |
Antonio Larrosa | 811fab6 | 2010-03-04 22:19:48 -0300 | [diff] [blame] | 2203 | case EM2882_BOARD_KWORLD_VS_DVBT: |
Robert Krakora | 6e7b9ea | 2009-01-18 21:59:34 -0300 | [diff] [blame] | 2204 | ctl->demod = XC3028_FE_CHINA; |
| 2205 | ctl->fname = XC2028_DEFAULT_FIRMWARE; |
| 2206 | break; |
Devin Heitmueller | 1985922 | 2009-06-19 00:33:54 -0300 | [diff] [blame] | 2207 | case EM2882_BOARD_EVGA_INDTUBE: |
| 2208 | ctl->demod = XC3028_FE_CHINA; |
| 2209 | ctl->fname = XC3028L_DEFAULT_FIRMWARE; |
| 2210 | break; |
Mauro Carvalho Chehab | 3ca9c09 | 2008-04-17 21:37:53 -0300 | [diff] [blame] | 2211 | default: |
| 2212 | ctl->demod = XC3028_FE_OREN538; |
| 2213 | } |
| 2214 | } |
Mauro Carvalho Chehab | 3ca9c09 | 2008-04-17 21:37:53 -0300 | [diff] [blame] | 2215 | |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2216 | static void em28xx_tuner_setup(struct em28xx *dev) |
Mauro Carvalho Chehab | 882876b | 2007-10-29 11:33:18 -0300 | [diff] [blame] | 2217 | { |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2218 | struct tuner_setup tun_setup; |
| 2219 | struct v4l2_frequency f; |
Mauro Carvalho Chehab | 882876b | 2007-10-29 11:33:18 -0300 | [diff] [blame] | 2220 | |
Mauro Carvalho Chehab | ed08631 | 2008-01-24 06:59:20 -0300 | [diff] [blame] | 2221 | if (dev->tuner_type == TUNER_ABSENT) |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2222 | return; |
Mauro Carvalho Chehab | 882876b | 2007-10-29 11:33:18 -0300 | [diff] [blame] | 2223 | |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2224 | memset(&tun_setup, 0, sizeof(tun_setup)); |
| 2225 | |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2226 | tun_setup.mode_mask = T_ANALOG_TV | T_RADIO; |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2227 | tun_setup.tuner_callback = em28xx_tuner_callback; |
Mauro Carvalho Chehab | 882876b | 2007-10-29 11:33:18 -0300 | [diff] [blame] | 2228 | |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2229 | if (dev->board.radio.type) { |
| 2230 | tun_setup.type = dev->board.radio.type; |
| 2231 | tun_setup.addr = dev->board.radio_addr; |
| 2232 | |
| 2233 | v4l2_device_call_all(&dev->v4l2_dev, 0, tuner, s_type_addr, &tun_setup); |
| 2234 | } |
| 2235 | |
| 2236 | if ((dev->tuner_type != TUNER_ABSENT) && (dev->tuner_type)) { |
| 2237 | tun_setup.type = dev->tuner_type; |
| 2238 | tun_setup.addr = dev->tuner_addr; |
| 2239 | |
| 2240 | v4l2_device_call_all(&dev->v4l2_dev, 0, tuner, s_type_addr, &tun_setup); |
| 2241 | } |
| 2242 | |
| 2243 | if (dev->tda9887_conf) { |
| 2244 | struct v4l2_priv_tun_config tda9887_cfg; |
| 2245 | |
| 2246 | tda9887_cfg.tuner = TUNER_TDA9887; |
| 2247 | tda9887_cfg.priv = &dev->tda9887_conf; |
| 2248 | |
| 2249 | v4l2_device_call_all(&dev->v4l2_dev, 0, tuner, s_config, &tda9887_cfg); |
| 2250 | } |
Mauro Carvalho Chehab | 882876b | 2007-10-29 11:33:18 -0300 | [diff] [blame] | 2251 | |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2252 | if (dev->tuner_type == TUNER_XC2028) { |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2253 | struct v4l2_priv_tun_config xc2028_cfg; |
Mauro Carvalho Chehab | 3ca9c09 | 2008-04-17 21:37:53 -0300 | [diff] [blame] | 2254 | struct xc2028_ctrl ctl; |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2255 | |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2256 | memset(&xc2028_cfg, 0, sizeof(xc2028_cfg)); |
| 2257 | memset(&ctl, 0, sizeof(ctl)); |
| 2258 | |
Mauro Carvalho Chehab | 3ca9c09 | 2008-04-17 21:37:53 -0300 | [diff] [blame] | 2259 | em28xx_setup_xc3028(dev, &ctl); |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2260 | |
| 2261 | xc2028_cfg.tuner = TUNER_XC2028; |
| 2262 | xc2028_cfg.priv = &ctl; |
| 2263 | |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2264 | v4l2_device_call_all(&dev->v4l2_dev, 0, tuner, s_config, &xc2028_cfg); |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2265 | } |
| 2266 | |
| 2267 | /* configure tuner */ |
| 2268 | f.tuner = 0; |
| 2269 | f.type = V4L2_TUNER_ANALOG_TV; |
| 2270 | f.frequency = 9076; /* just a magic number */ |
| 2271 | dev->ctl_freq = f.frequency; |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2272 | v4l2_device_call_all(&dev->v4l2_dev, 0, tuner, s_frequency, &f); |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2273 | } |
| 2274 | |
| 2275 | static int em28xx_hint_board(struct em28xx *dev) |
| 2276 | { |
| 2277 | int i; |
| 2278 | |
Mauro Carvalho Chehab | d2ba055 | 2007-11-04 08:32:42 -0300 | [diff] [blame] | 2279 | /* HINT method: EEPROM |
| 2280 | * |
| 2281 | * This method works only for boards with eeprom. |
| 2282 | * Uses a hash of all eeprom bytes. The hash should be |
| 2283 | * unique for a vendor/tuner pair. |
| 2284 | * There are a high chance that tuners for different |
| 2285 | * video standards produce different hashes. |
| 2286 | */ |
| 2287 | for (i = 0; i < ARRAY_SIZE(em28xx_eeprom_hash); i++) { |
| 2288 | if (dev->hash == em28xx_eeprom_hash[i].hash) { |
| 2289 | dev->model = em28xx_eeprom_hash[i].model; |
| 2290 | dev->tuner_type = em28xx_eeprom_hash[i].tuner; |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2291 | |
| 2292 | em28xx_errdev("Your board has no unique USB ID.\n"); |
| 2293 | em28xx_errdev("A hint were successfully done, " |
| 2294 | "based on eeprom hash.\n"); |
| 2295 | em28xx_errdev("This method is not 100%% failproof.\n"); |
| 2296 | em28xx_errdev("If the board were missdetected, " |
| 2297 | "please email this log to:\n"); |
| 2298 | em28xx_errdev("\tV4L Mailing List " |
Alexey Klimov | 51caf91 | 2009-01-25 12:53:09 -0300 | [diff] [blame] | 2299 | " <linux-media@vger.kernel.org>\n"); |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2300 | em28xx_errdev("Board detected as %s\n", |
| 2301 | em28xx_boards[dev->model].name); |
| 2302 | |
| 2303 | return 0; |
| 2304 | } |
| 2305 | } |
Sascha Sommer | fad7b95 | 2007-11-04 08:06:48 -0300 | [diff] [blame] | 2306 | |
Mauro Carvalho Chehab | d2ba055 | 2007-11-04 08:32:42 -0300 | [diff] [blame] | 2307 | /* HINT method: I2C attached devices |
| 2308 | * |
| 2309 | * This method works for all boards. |
| 2310 | * Uses a hash of i2c scanned devices. |
| 2311 | * Devices with the same i2c attached chips will |
| 2312 | * be considered equal. |
| 2313 | * This method is less precise than the eeprom one. |
| 2314 | */ |
| 2315 | |
Sascha Sommer | fad7b95 | 2007-11-04 08:06:48 -0300 | [diff] [blame] | 2316 | /* user did not request i2c scanning => do it now */ |
| 2317 | if (!dev->i2c_hash) |
| 2318 | em28xx_do_i2c_scan(dev); |
| 2319 | |
| 2320 | for (i = 0; i < ARRAY_SIZE(em28xx_i2c_hash); i++) { |
| 2321 | if (dev->i2c_hash == em28xx_i2c_hash[i].hash) { |
| 2322 | dev->model = em28xx_i2c_hash[i].model; |
| 2323 | dev->tuner_type = em28xx_i2c_hash[i].tuner; |
| 2324 | em28xx_errdev("Your board has no unique USB ID.\n"); |
| 2325 | em28xx_errdev("A hint were successfully done, " |
| 2326 | "based on i2c devicelist hash.\n"); |
| 2327 | em28xx_errdev("This method is not 100%% failproof.\n"); |
| 2328 | em28xx_errdev("If the board were missdetected, " |
| 2329 | "please email this log to:\n"); |
| 2330 | em28xx_errdev("\tV4L Mailing List " |
Alexey Klimov | 51caf91 | 2009-01-25 12:53:09 -0300 | [diff] [blame] | 2331 | " <linux-media@vger.kernel.org>\n"); |
Sascha Sommer | fad7b95 | 2007-11-04 08:06:48 -0300 | [diff] [blame] | 2332 | em28xx_errdev("Board detected as %s\n", |
| 2333 | em28xx_boards[dev->model].name); |
| 2334 | |
| 2335 | return 0; |
| 2336 | } |
| 2337 | } |
| 2338 | |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2339 | em28xx_errdev("Your board has no unique USB ID and thus need a " |
| 2340 | "hint to be detected.\n"); |
| 2341 | em28xx_errdev("You may try to use card=<n> insmod option to " |
| 2342 | "workaround that.\n"); |
| 2343 | em28xx_errdev("Please send an email with this log to:\n"); |
Alexey Klimov | 51caf91 | 2009-01-25 12:53:09 -0300 | [diff] [blame] | 2344 | em28xx_errdev("\tV4L Mailing List <linux-media@vger.kernel.org>\n"); |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2345 | em28xx_errdev("Board eeprom hash is 0x%08lx\n", dev->hash); |
Sascha Sommer | fad7b95 | 2007-11-04 08:06:48 -0300 | [diff] [blame] | 2346 | em28xx_errdev("Board i2c devicelist hash is 0x%08lx\n", dev->i2c_hash); |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2347 | |
| 2348 | em28xx_errdev("Here is a list of valid choices for the card=<n>" |
| 2349 | " insmod option:\n"); |
| 2350 | for (i = 0; i < em28xx_bcount; i++) { |
| 2351 | em28xx_errdev(" card=%d -> %s\n", |
| 2352 | i, em28xx_boards[i].name); |
| 2353 | } |
| 2354 | return -1; |
Mauro Carvalho Chehab | 882876b | 2007-10-29 11:33:18 -0300 | [diff] [blame] | 2355 | } |
| 2356 | |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 2357 | /* ----------------------------------------------------------------------- */ |
Jean Delvare | c668f32 | 2009-05-13 16:48:50 -0300 | [diff] [blame] | 2358 | void em28xx_register_i2c_ir(struct em28xx *dev) |
| 2359 | { |
Magnus Alm | ca39d84 | 2009-11-13 05:48:24 -0300 | [diff] [blame] | 2360 | /* Leadtek winfast tv USBII deluxe can find a non working IR-device */ |
| 2361 | /* at address 0x18, so if that address is needed for another board in */ |
| 2362 | /* the future, please put it after 0x1f. */ |
Jean Delvare | 43e16ea | 2009-10-02 05:47:08 -0300 | [diff] [blame] | 2363 | struct i2c_board_info info; |
Jean Delvare | c668f32 | 2009-05-13 16:48:50 -0300 | [diff] [blame] | 2364 | const unsigned short addr_list[] = { |
Magnus Alm | ca39d84 | 2009-11-13 05:48:24 -0300 | [diff] [blame] | 2365 | 0x1f, 0x30, 0x47, I2C_CLIENT_END |
Jean Delvare | c668f32 | 2009-05-13 16:48:50 -0300 | [diff] [blame] | 2366 | }; |
| 2367 | |
| 2368 | if (disable_ir) |
| 2369 | return; |
| 2370 | |
Jean Delvare | 43e16ea | 2009-10-02 05:47:08 -0300 | [diff] [blame] | 2371 | memset(&info, 0, sizeof(struct i2c_board_info)); |
Mauro Carvalho Chehab | d2ebd0f8 | 2009-09-07 02:16:47 -0300 | [diff] [blame] | 2372 | memset(&dev->init_data, 0, sizeof(dev->init_data)); |
Jean Delvare | 43e16ea | 2009-10-02 05:47:08 -0300 | [diff] [blame] | 2373 | strlcpy(info.type, "ir_video", I2C_NAME_SIZE); |
Jean Delvare | c668f32 | 2009-05-13 16:48:50 -0300 | [diff] [blame] | 2374 | |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 2375 | /* detect & configure */ |
| 2376 | switch (dev->model) { |
Mauro Carvalho Chehab | 7e8e16c | 2009-09-08 14:07:05 -0300 | [diff] [blame] | 2377 | case EM2800_BOARD_TERRATEC_CINERGY_200: |
| 2378 | case EM2820_BOARD_TERRATEC_CINERGY_250: |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 2379 | dev->init_data.ir_codes = RC_MAP_EM_TERRATEC; |
Mauro Carvalho Chehab | d2ebd0f8 | 2009-09-07 02:16:47 -0300 | [diff] [blame] | 2380 | dev->init_data.get_key = em28xx_get_key_terratec; |
| 2381 | dev->init_data.name = "i2c IR (EM28XX Terratec)"; |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 2382 | break; |
Mauro Carvalho Chehab | 7e8e16c | 2009-09-08 14:07:05 -0300 | [diff] [blame] | 2383 | case EM2820_BOARD_PINNACLE_USB_2: |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 2384 | dev->init_data.ir_codes = RC_MAP_PINNACLE_GREY; |
Mauro Carvalho Chehab | d2ebd0f8 | 2009-09-07 02:16:47 -0300 | [diff] [blame] | 2385 | dev->init_data.get_key = em28xx_get_key_pinnacle_usb_grey; |
| 2386 | dev->init_data.name = "i2c IR (EM28XX Pinnacle PCTV)"; |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 2387 | break; |
Mauro Carvalho Chehab | 7e8e16c | 2009-09-08 14:07:05 -0300 | [diff] [blame] | 2388 | case EM2820_BOARD_HAUPPAUGE_WINTV_USB_2: |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 2389 | dev->init_data.ir_codes = RC_MAP_RC5_HAUPPAUGE_NEW; |
Mauro Carvalho Chehab | d2ebd0f8 | 2009-09-07 02:16:47 -0300 | [diff] [blame] | 2390 | dev->init_data.get_key = em28xx_get_key_em_haup; |
| 2391 | dev->init_data.name = "i2c IR (EM2840 Hauppauge)"; |
Douglas Schilling Landgraf | 0a71102 | 2010-02-05 14:33:38 -0200 | [diff] [blame] | 2392 | case EM2820_BOARD_LEADTEK_WINFAST_USBII_DELUXE: |
Mauro Carvalho Chehab | 02858ee | 2010-04-02 20:01:00 -0300 | [diff] [blame] | 2393 | dev->init_data.ir_codes = RC_MAP_WINFAST_USBII_DELUXE;; |
Douglas Schilling Landgraf | 0a71102 | 2010-02-05 14:33:38 -0200 | [diff] [blame] | 2394 | dev->init_data.get_key = em28xx_get_key_winfast_usbii_deluxe; |
| 2395 | dev->init_data.name = "i2c IR (EM2820 Winfast TV USBII Deluxe)"; |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 2396 | break; |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 2397 | } |
Jean Delvare | 4d7a2d6 | 2009-05-13 16:49:32 -0300 | [diff] [blame] | 2398 | |
Mauro Carvalho Chehab | d2ebd0f8 | 2009-09-07 02:16:47 -0300 | [diff] [blame] | 2399 | if (dev->init_data.name) |
Jean Delvare | 43e16ea | 2009-10-02 05:47:08 -0300 | [diff] [blame] | 2400 | info.platform_data = &dev->init_data; |
Jean Delvare | 9a94241 | 2010-08-11 18:20:56 +0200 | [diff] [blame] | 2401 | i2c_new_probed_device(&dev->i2c_adap, &info, addr_list, NULL); |
Mauro Carvalho Chehab | c8793b0 | 2008-01-13 15:42:17 -0300 | [diff] [blame] | 2402 | } |
| 2403 | |
Mauro Carvalho Chehab | 3acf280 | 2005-11-08 21:38:27 -0800 | [diff] [blame] | 2404 | void em28xx_card_setup(struct em28xx *dev) |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 2405 | { |
Mauro Carvalho Chehab | 3d3215c | 2009-08-10 10:29:27 -0300 | [diff] [blame] | 2406 | /* |
| 2407 | * If the device can be a webcam, seek for a sensor. |
| 2408 | * If sensor is not found, then it isn't a webcam. |
| 2409 | */ |
| 2410 | if (dev->board.is_webcam) { |
| 2411 | if (em28xx_hint_sensor(dev) < 0) |
| 2412 | dev->board.is_webcam = 0; |
| 2413 | else |
| 2414 | dev->progressive = 1; |
| 2415 | } else |
| 2416 | em28xx_set_model(dev); |
| 2417 | |
| 2418 | em28xx_info("Identified as %s (card=%d)\n", |
| 2419 | dev->board.name, dev->model); |
Mauro Carvalho Chehab | f8b6030 | 2007-11-05 08:42:55 -0300 | [diff] [blame] | 2420 | |
| 2421 | dev->tuner_type = em28xx_boards[dev->model].tuner_type; |
Mauro Carvalho Chehab | 31e0530 | 2008-11-20 18:47:37 -0300 | [diff] [blame] | 2422 | if (em28xx_boards[dev->model].tuner_addr) |
| 2423 | dev->tuner_addr = em28xx_boards[dev->model].tuner_addr; |
Mauro Carvalho Chehab | f8b6030 | 2007-11-05 08:42:55 -0300 | [diff] [blame] | 2424 | |
Franklin Meng | ae3340c | 2009-06-06 16:34:01 -0300 | [diff] [blame] | 2425 | if (em28xx_boards[dev->model].tda9887_conf) |
| 2426 | dev->tda9887_conf = em28xx_boards[dev->model].tda9887_conf; |
| 2427 | |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 2428 | /* request some modules */ |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2429 | switch (dev->model) { |
| 2430 | case EM2820_BOARD_HAUPPAUGE_WINTV_USB_2: |
Mauro Carvalho Chehab | 98ae127 | 2007-11-05 09:30:39 -0300 | [diff] [blame] | 2431 | case EM2880_BOARD_HAUPPAUGE_WINTV_HVR_900: |
Devin Heitmueller | 17d9d55 | 2008-06-08 10:22:03 -0300 | [diff] [blame] | 2432 | case EM2880_BOARD_HAUPPAUGE_WINTV_HVR_900_R2: |
Douglas Schilling Landgraf | f89bc32 | 2008-12-01 21:01:04 -0300 | [diff] [blame] | 2433 | case EM2883_BOARD_HAUPPAUGE_WINTV_HVR_850: |
Mauro Carvalho Chehab | 10ac660 | 2008-07-27 14:58:58 -0300 | [diff] [blame] | 2434 | case EM2883_BOARD_HAUPPAUGE_WINTV_HVR_950: |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2435 | { |
| 2436 | struct tveeprom tv; |
Mauro Carvalho Chehab | ac07bb7 | 2009-09-08 14:04:41 -0300 | [diff] [blame] | 2437 | #if defined(CONFIG_MODULES) && defined(MODULE) |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2438 | request_module("tveeprom"); |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 2439 | #endif |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2440 | /* Call first TVeeprom */ |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 2441 | |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2442 | dev->i2c_client.addr = 0xa0 >> 1; |
| 2443 | tveeprom_hauppauge_analog(&dev->i2c_client, &tv, dev->eedata); |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 2444 | |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2445 | dev->tuner_type = tv.tuner_type; |
Mauro Carvalho Chehab | ed08631 | 2008-01-24 06:59:20 -0300 | [diff] [blame] | 2446 | |
Hans Verkuil | 38f9d30 | 2008-07-23 05:09:15 -0300 | [diff] [blame] | 2447 | if (tv.audio_processor == V4L2_IDENT_MSPX4XX) { |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2448 | dev->i2s_speed = 2048000; |
Mauro Carvalho Chehab | 505b6d0 | 2008-11-25 09:39:50 -0300 | [diff] [blame] | 2449 | dev->board.has_msp34xx = 1; |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2450 | } |
| 2451 | break; |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 2452 | } |
Franklin Meng | d7de5d8 | 2009-06-06 17:05:02 -0300 | [diff] [blame] | 2453 | case EM2882_BOARD_KWORLD_ATSC_315U: |
| 2454 | em28xx_write_reg(dev, 0x0d, 0x42); |
| 2455 | msleep(10); |
| 2456 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xfd); |
| 2457 | msleep(10); |
| 2458 | break; |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2459 | case EM2820_BOARD_KWORLD_PVRTV2800RF: |
| 2460 | /* GPIO enables sound on KWORLD PVR TV 2800RF */ |
Devin Heitmueller | 6d676d8 | 2008-11-25 06:04:02 -0300 | [diff] [blame] | 2461 | em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xf9); |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2462 | break; |
| 2463 | case EM2820_BOARD_UNKNOWN: |
| 2464 | case EM2800_BOARD_UNKNOWN: |
Darron Broad | da3808e | 2008-09-30 02:46:41 -0300 | [diff] [blame] | 2465 | /* |
| 2466 | * The K-WORLD DVB-T 310U is detected as an MSI Digivox AD. |
| 2467 | * |
| 2468 | * This occurs because they share identical USB vendor and |
| 2469 | * product IDs. |
| 2470 | * |
| 2471 | * What we do here is look up the EEPROM hash of the K-WORLD |
| 2472 | * and if it is found then we decide that we do not have |
| 2473 | * a DIGIVOX and reset the device to the K-WORLD instead. |
| 2474 | * |
| 2475 | * This solution is only valid if they do not share eeprom |
| 2476 | * hash identities which has not been determined as yet. |
| 2477 | */ |
| 2478 | case EM2880_BOARD_MSI_DIGIVOX_AD: |
Mauro Carvalho Chehab | f8b6030 | 2007-11-05 08:42:55 -0300 | [diff] [blame] | 2479 | if (!em28xx_hint_board(dev)) |
| 2480 | em28xx_set_model(dev); |
Devin Heitmueller | cdf7bfa | 2009-06-19 00:20:28 -0300 | [diff] [blame] | 2481 | |
| 2482 | /* In cases where we had to use a board hint, the call to |
| 2483 | em28xx_set_mode() in em28xx_pre_card_setup() was a no-op, |
| 2484 | so make the call now so the analog GPIOs are set properly |
| 2485 | before probing the i2c bus. */ |
Devin Heitmueller | 5343e44 | 2009-07-15 00:35:47 -0300 | [diff] [blame] | 2486 | em28xx_gpio_set(dev, dev->board.tuner_gpio); |
Devin Heitmueller | cdf7bfa | 2009-06-19 00:20:28 -0300 | [diff] [blame] | 2487 | em28xx_set_mode(dev, EM28XX_ANALOG_MODE); |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2488 | break; |
Andrea.Amorosi76@gmail.com | 7ca7ef6 | 2010-02-09 17:53:38 -0300 | [diff] [blame] | 2489 | |
| 2490 | /* |
| 2491 | * The Dikom DK300 is detected as an Kworld VS-DVB-T 323UR. |
| 2492 | * |
| 2493 | * This occurs because they share identical USB vendor and |
| 2494 | * product IDs. |
| 2495 | * |
| 2496 | * What we do here is look up the EEPROM hash of the Dikom |
| 2497 | * and if it is found then we decide that we do not have |
| 2498 | * a Kworld and reset the device to the Dikom instead. |
| 2499 | * |
| 2500 | * This solution is only valid if they do not share eeprom |
| 2501 | * hash identities which has not been determined as yet. |
| 2502 | */ |
| 2503 | case EM2882_BOARD_KWORLD_VS_DVBT: |
| 2504 | if (!em28xx_hint_board(dev)) |
| 2505 | em28xx_set_model(dev); |
| 2506 | |
| 2507 | /* In cases where we had to use a board hint, the call to |
| 2508 | em28xx_set_mode() in em28xx_pre_card_setup() was a no-op, |
| 2509 | so make the call now so the analog GPIOs are set properly |
| 2510 | before probing the i2c bus. */ |
| 2511 | em28xx_gpio_set(dev, dev->board.tuner_gpio); |
| 2512 | em28xx_set_mode(dev, EM28XX_ANALOG_MODE); |
| 2513 | break; |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2514 | } |
| 2515 | |
Mauro Carvalho Chehab | ac07bb7 | 2009-09-08 14:04:41 -0300 | [diff] [blame] | 2516 | #if defined(CONFIG_MODULES) && defined(MODULE) |
| 2517 | if (dev->board.has_ir_i2c && !disable_ir) |
| 2518 | request_module("ir-kbd-i2c"); |
| 2519 | #endif |
Mauro Carvalho Chehab | 505b6d0 | 2008-11-25 09:39:50 -0300 | [diff] [blame] | 2520 | if (dev->board.has_snapshot_button) |
Devin Heitmueller | a9fc52b | 2008-06-28 08:57:06 -0300 | [diff] [blame] | 2521 | em28xx_register_snapshot_button(dev); |
| 2522 | |
Mauro Carvalho Chehab | 505b6d0 | 2008-11-25 09:39:50 -0300 | [diff] [blame] | 2523 | if (dev->board.valid == EM28XX_BOARD_NOT_VALIDATED) { |
Douglas Schilling Landgraf | 95b86a9 | 2008-07-27 14:03:32 -0300 | [diff] [blame] | 2524 | em28xx_errdev("\n\n"); |
| 2525 | em28xx_errdev("The support for this board weren't " |
| 2526 | "valid yet.\n"); |
| 2527 | em28xx_errdev("Please send a report of having this working\n"); |
| 2528 | em28xx_errdev("not to V4L mailing list (and/or to other " |
| 2529 | "addresses)\n\n"); |
| 2530 | } |
| 2531 | |
Mauro Carvalho Chehab | f8b6030 | 2007-11-05 08:42:55 -0300 | [diff] [blame] | 2532 | /* Allow override tuner type by a module parameter */ |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2533 | if (tuner >= 0) |
| 2534 | dev->tuner_type = tuner; |
| 2535 | |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2536 | /* request some modules */ |
Mauro Carvalho Chehab | 505b6d0 | 2008-11-25 09:39:50 -0300 | [diff] [blame] | 2537 | if (dev->board.has_msp34xx) |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2538 | v4l2_i2c_new_subdev(&dev->v4l2_dev, &dev->i2c_adap, |
| 2539 | "msp3400", "msp3400", 0, msp3400_addrs); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2540 | |
Mauro Carvalho Chehab | ec5de99 | 2008-11-25 09:43:29 -0300 | [diff] [blame] | 2541 | if (dev->board.decoder == EM28XX_SAA711X) |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2542 | v4l2_i2c_new_subdev(&dev->v4l2_dev, &dev->i2c_adap, |
| 2543 | "saa7115", "saa7115_auto", 0, saa711x_addrs); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2544 | |
Mauro Carvalho Chehab | 505b6d0 | 2008-11-25 09:39:50 -0300 | [diff] [blame] | 2545 | if (dev->board.decoder == EM28XX_TVP5150) |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2546 | v4l2_i2c_new_subdev(&dev->v4l2_dev, &dev->i2c_adap, |
| 2547 | "tvp5150", "tvp5150", 0, tvp5150_addrs); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2548 | |
Mauro Carvalho Chehab | d36bb4e | 2009-07-14 03:18:39 -0300 | [diff] [blame] | 2549 | if (dev->em28xx_sensor == EM28XX_MT9V011) { |
| 2550 | struct v4l2_subdev *sd; |
| 2551 | |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2552 | sd = v4l2_i2c_new_subdev(&dev->v4l2_dev, |
| 2553 | &dev->i2c_adap, "mt9v011", "mt9v011", 0, mt9v011_addrs); |
Mauro Carvalho Chehab | d36bb4e | 2009-07-14 03:18:39 -0300 | [diff] [blame] | 2554 | v4l2_subdev_call(sd, core, s_config, 0, &dev->sensor_xtal); |
| 2555 | } |
Mauro Carvalho Chehab | 02e7804 | 2009-06-29 11:35:05 -0300 | [diff] [blame] | 2556 | |
Mauro Carvalho Chehab | b80fd2d | 2009-07-14 21:08:22 -0300 | [diff] [blame] | 2557 | |
Mauro Carvalho Chehab | df7fa09 | 2009-02-25 09:06:13 -0300 | [diff] [blame] | 2558 | if (dev->board.adecoder == EM28XX_TVAUDIO) |
Hans Verkuil | e6574f2 | 2009-04-01 03:57:53 -0300 | [diff] [blame] | 2559 | v4l2_i2c_new_subdev(&dev->v4l2_dev, &dev->i2c_adap, |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2560 | "tvaudio", "tvaudio", dev->board.tvaudio_addr, NULL); |
Mauro Carvalho Chehab | 03910cc | 2007-11-03 21:20:59 -0300 | [diff] [blame] | 2561 | |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2562 | if (dev->board.tuner_type != TUNER_ABSENT) { |
| 2563 | int has_demod = (dev->tda9887_conf & TDA9887_PRESENT); |
Mauro Carvalho Chehab | a924a49 | 2008-11-12 08:41:29 -0300 | [diff] [blame] | 2564 | |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2565 | if (dev->board.radio.type) |
Hans Verkuil | e6574f2 | 2009-04-01 03:57:53 -0300 | [diff] [blame] | 2566 | v4l2_i2c_new_subdev(&dev->v4l2_dev, &dev->i2c_adap, |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2567 | "tuner", "tuner", dev->board.radio_addr, NULL); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2568 | |
| 2569 | if (has_demod) |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2570 | v4l2_i2c_new_subdev(&dev->v4l2_dev, |
Hans Verkuil | e6574f2 | 2009-04-01 03:57:53 -0300 | [diff] [blame] | 2571 | &dev->i2c_adap, "tuner", "tuner", |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2572 | 0, v4l2_i2c_tuner_addrs(ADDRS_DEMOD)); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2573 | if (dev->tuner_addr == 0) { |
| 2574 | enum v4l2_i2c_tuner_type type = |
| 2575 | has_demod ? ADDRS_TV_WITH_DEMOD : ADDRS_TV; |
| 2576 | struct v4l2_subdev *sd; |
| 2577 | |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2578 | sd = v4l2_i2c_new_subdev(&dev->v4l2_dev, |
Hans Verkuil | e6574f2 | 2009-04-01 03:57:53 -0300 | [diff] [blame] | 2579 | &dev->i2c_adap, "tuner", "tuner", |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2580 | 0, v4l2_i2c_tuner_addrs(type)); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2581 | |
| 2582 | if (sd) |
| 2583 | dev->tuner_addr = v4l2_i2c_subdev_addr(sd); |
| 2584 | } else { |
Hans Verkuil | e6574f2 | 2009-04-01 03:57:53 -0300 | [diff] [blame] | 2585 | v4l2_i2c_new_subdev(&dev->v4l2_dev, &dev->i2c_adap, |
Hans Verkuil | 53dacb1 | 2009-08-10 02:49:08 -0300 | [diff] [blame] | 2586 | "tuner", "tuner", dev->tuner_addr, NULL); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2587 | } |
| 2588 | } |
| 2589 | |
| 2590 | em28xx_tuner_setup(dev); |
Shine Liu | f4c5e80 | 2009-08-20 23:49:26 -0300 | [diff] [blame] | 2591 | |
| 2592 | if(!disable_ir) |
| 2593 | em28xx_ir_init(dev); |
akpm@osdl.org | a6c2ba2 | 2005-11-08 21:37:07 -0800 | [diff] [blame] | 2594 | } |
Mauro Carvalho Chehab | c864405 | 2008-11-25 13:10:14 -0300 | [diff] [blame] | 2595 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2596 | |
| 2597 | #if defined(CONFIG_MODULES) && defined(MODULE) |
| 2598 | static void request_module_async(struct work_struct *work) |
| 2599 | { |
| 2600 | struct em28xx *dev = container_of(work, |
| 2601 | struct em28xx, request_module_wk); |
| 2602 | |
| 2603 | if (dev->has_audio_class) |
| 2604 | request_module("snd-usb-audio"); |
| 2605 | else if (dev->has_alsa_audio) |
| 2606 | request_module("em28xx-alsa"); |
| 2607 | |
| 2608 | if (dev->board.has_dvb) |
| 2609 | request_module("em28xx-dvb"); |
| 2610 | } |
| 2611 | |
| 2612 | static void request_modules(struct em28xx *dev) |
| 2613 | { |
| 2614 | INIT_WORK(&dev->request_module_wk, request_module_async); |
| 2615 | schedule_work(&dev->request_module_wk); |
| 2616 | } |
| 2617 | #else |
| 2618 | #define request_modules(dev) |
| 2619 | #endif /* CONFIG_MODULES */ |
| 2620 | |
| 2621 | /* |
| 2622 | * em28xx_realease_resources() |
| 2623 | * unregisters the v4l2,i2c and usb devices |
| 2624 | * called when the device gets disconected or at module unload |
| 2625 | */ |
| 2626 | void em28xx_release_resources(struct em28xx *dev) |
| 2627 | { |
| 2628 | if (dev->sbutton_input_dev) |
| 2629 | em28xx_deregister_snapshot_button(dev); |
| 2630 | |
| 2631 | if (dev->ir) |
| 2632 | em28xx_ir_fini(dev); |
| 2633 | |
| 2634 | /*FIXME: I2C IR should be disconnected */ |
| 2635 | |
| 2636 | em28xx_release_analog_resources(dev); |
| 2637 | |
| 2638 | em28xx_remove_from_devlist(dev); |
| 2639 | |
| 2640 | em28xx_i2c_unregister(dev); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2641 | |
| 2642 | v4l2_device_unregister(&dev->v4l2_dev); |
| 2643 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2644 | usb_put_dev(dev->udev); |
| 2645 | |
| 2646 | /* Mark device as unused */ |
| 2647 | em28xx_devused &= ~(1 << dev->devno); |
| 2648 | }; |
| 2649 | |
| 2650 | /* |
| 2651 | * em28xx_init_dev() |
| 2652 | * allocates and inits the device structs, registers i2c bus and v4l device |
| 2653 | */ |
Mauro Carvalho Chehab | 26cdc76 | 2009-01-05 01:00:40 -0300 | [diff] [blame] | 2654 | static int em28xx_init_dev(struct em28xx **devhandle, struct usb_device *udev, |
Mauro Carvalho Chehab | 36fa674 | 2009-04-05 08:02:15 -0300 | [diff] [blame] | 2655 | struct usb_interface *interface, |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2656 | int minor) |
| 2657 | { |
| 2658 | struct em28xx *dev = *devhandle; |
Mauro Carvalho Chehab | fcd20e3 | 2009-08-10 02:57:57 -0300 | [diff] [blame] | 2659 | int retval; |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2660 | int errCode; |
| 2661 | |
| 2662 | dev->udev = udev; |
| 2663 | mutex_init(&dev->ctrl_urb_lock); |
| 2664 | spin_lock_init(&dev->slock); |
| 2665 | init_waitqueue_head(&dev->open); |
| 2666 | init_waitqueue_head(&dev->wait_frame); |
| 2667 | init_waitqueue_head(&dev->wait_stream); |
| 2668 | |
| 2669 | dev->em28xx_write_regs = em28xx_write_regs; |
| 2670 | dev->em28xx_read_reg = em28xx_read_reg; |
| 2671 | dev->em28xx_read_reg_req_len = em28xx_read_reg_req_len; |
| 2672 | dev->em28xx_write_regs_req = em28xx_write_regs_req; |
| 2673 | dev->em28xx_read_reg_req = em28xx_read_reg_req; |
| 2674 | dev->board.is_em2800 = em28xx_boards[dev->model].is_em2800; |
| 2675 | |
Mauro Carvalho Chehab | fcd20e3 | 2009-08-10 02:57:57 -0300 | [diff] [blame] | 2676 | em28xx_set_model(dev); |
| 2677 | |
| 2678 | /* Set the default GPO/GPIO for legacy devices */ |
| 2679 | dev->reg_gpo_num = EM2880_R04_GPO; |
| 2680 | dev->reg_gpio_num = EM28XX_R08_GPIO; |
| 2681 | |
| 2682 | dev->wait_after_write = 5; |
| 2683 | |
| 2684 | /* Based on the Chip ID, set the device configuration */ |
| 2685 | retval = em28xx_read_reg(dev, EM28XX_R0A_CHIPID); |
| 2686 | if (retval > 0) { |
| 2687 | dev->chip_id = retval; |
| 2688 | |
| 2689 | switch (dev->chip_id) { |
Mauro Carvalho Chehab | f57b17c3 | 2009-11-12 11:21:05 -0300 | [diff] [blame] | 2690 | case CHIP_ID_EM2800: |
| 2691 | em28xx_info("chip ID is em2800\n"); |
| 2692 | break; |
Mauro Carvalho Chehab | fcd20e3 | 2009-08-10 02:57:57 -0300 | [diff] [blame] | 2693 | case CHIP_ID_EM2710: |
| 2694 | em28xx_info("chip ID is em2710\n"); |
| 2695 | break; |
| 2696 | case CHIP_ID_EM2750: |
| 2697 | em28xx_info("chip ID is em2750\n"); |
| 2698 | break; |
| 2699 | case CHIP_ID_EM2820: |
| 2700 | em28xx_info("chip ID is em2820 (or em2710)\n"); |
| 2701 | break; |
| 2702 | case CHIP_ID_EM2840: |
| 2703 | em28xx_info("chip ID is em2840\n"); |
| 2704 | break; |
| 2705 | case CHIP_ID_EM2860: |
| 2706 | em28xx_info("chip ID is em2860\n"); |
| 2707 | break; |
| 2708 | case CHIP_ID_EM2870: |
| 2709 | em28xx_info("chip ID is em2870\n"); |
| 2710 | dev->wait_after_write = 0; |
| 2711 | break; |
| 2712 | case CHIP_ID_EM2874: |
| 2713 | em28xx_info("chip ID is em2874\n"); |
| 2714 | dev->reg_gpio_num = EM2874_R80_GPIO; |
| 2715 | dev->wait_after_write = 0; |
| 2716 | break; |
| 2717 | case CHIP_ID_EM2883: |
| 2718 | em28xx_info("chip ID is em2882/em2883\n"); |
| 2719 | dev->wait_after_write = 0; |
| 2720 | break; |
| 2721 | default: |
| 2722 | em28xx_info("em28xx chip ID = %d\n", dev->chip_id); |
| 2723 | } |
| 2724 | } |
| 2725 | |
| 2726 | /* Prepopulate cached GPO register content */ |
| 2727 | retval = em28xx_read_reg(dev, dev->reg_gpo_num); |
| 2728 | if (retval >= 0) |
| 2729 | dev->reg_gpo = retval; |
| 2730 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2731 | em28xx_pre_card_setup(dev); |
| 2732 | |
| 2733 | if (!dev->board.is_em2800) { |
| 2734 | /* Sets I2C speed to 100 KHz */ |
| 2735 | retval = em28xx_write_reg(dev, EM28XX_R06_I2C_CLK, 0x40); |
| 2736 | if (retval < 0) { |
| 2737 | em28xx_errdev("%s: em28xx_write_regs_req failed!" |
| 2738 | " retval [%d]\n", |
| 2739 | __func__, retval); |
| 2740 | return retval; |
| 2741 | } |
| 2742 | } |
| 2743 | |
Mauro Carvalho Chehab | 36fa674 | 2009-04-05 08:02:15 -0300 | [diff] [blame] | 2744 | retval = v4l2_device_register(&interface->dev, &dev->v4l2_dev); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2745 | if (retval < 0) { |
| 2746 | em28xx_errdev("Call to v4l2_device_register() failed!\n"); |
| 2747 | return retval; |
| 2748 | } |
| 2749 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2750 | /* register i2c bus */ |
| 2751 | errCode = em28xx_i2c_register(dev); |
| 2752 | if (errCode < 0) { |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2753 | v4l2_device_unregister(&dev->v4l2_dev); |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2754 | em28xx_errdev("%s: em28xx_i2c_register - errCode [%d]!\n", |
| 2755 | __func__, errCode); |
| 2756 | return errCode; |
| 2757 | } |
| 2758 | |
Mauro Carvalho Chehab | b04fb66 | 2009-07-13 01:28:21 -0300 | [diff] [blame] | 2759 | /* |
Mauro Carvalho Chehab | 579d315 | 2009-07-14 12:33:25 -0300 | [diff] [blame] | 2760 | * Default format, used for tvp5150 or saa711x output formats |
| 2761 | */ |
| 2762 | dev->vinmode = 0x10; |
Devin Heitmueller | 206313d | 2009-08-31 23:23:03 -0300 | [diff] [blame] | 2763 | dev->vinctl = EM28XX_VINCTRL_INTERLACED | |
| 2764 | EM28XX_VINCTRL_CCIR656_ENABLE; |
Mauro Carvalho Chehab | 579d315 | 2009-07-14 12:33:25 -0300 | [diff] [blame] | 2765 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2766 | /* Do board specific init and eeprom reading */ |
| 2767 | em28xx_card_setup(dev); |
| 2768 | |
| 2769 | /* Configure audio */ |
| 2770 | errCode = em28xx_audio_setup(dev); |
| 2771 | if (errCode < 0) { |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2772 | v4l2_device_unregister(&dev->v4l2_dev); |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2773 | em28xx_errdev("%s: Error while setting audio - errCode [%d]!\n", |
| 2774 | __func__, errCode); |
| 2775 | } |
| 2776 | |
| 2777 | /* wake i2c devices */ |
| 2778 | em28xx_wake_i2c(dev); |
| 2779 | |
| 2780 | /* init video dma queues */ |
| 2781 | INIT_LIST_HEAD(&dev->vidq.active); |
| 2782 | INIT_LIST_HEAD(&dev->vidq.queued); |
Devin Heitmueller | 28abf083 | 2009-09-01 01:54:54 -0300 | [diff] [blame] | 2783 | INIT_LIST_HEAD(&dev->vbiq.active); |
| 2784 | INIT_LIST_HEAD(&dev->vbiq.queued); |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2785 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2786 | if (dev->board.has_msp34xx) { |
| 2787 | /* Send a reset to other chips via gpio */ |
| 2788 | errCode = em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xf7); |
| 2789 | if (errCode < 0) { |
| 2790 | em28xx_errdev("%s: em28xx_write_regs_req - " |
| 2791 | "msp34xx(1) failed! errCode [%d]\n", |
| 2792 | __func__, errCode); |
| 2793 | return errCode; |
| 2794 | } |
| 2795 | msleep(3); |
| 2796 | |
| 2797 | errCode = em28xx_write_reg(dev, EM28XX_R08_GPIO, 0xff); |
| 2798 | if (errCode < 0) { |
| 2799 | em28xx_errdev("%s: em28xx_write_regs_req - " |
| 2800 | "msp34xx(2) failed! errCode [%d]\n", |
| 2801 | __func__, errCode); |
| 2802 | return errCode; |
| 2803 | } |
| 2804 | msleep(3); |
| 2805 | } |
| 2806 | |
| 2807 | em28xx_add_into_devlist(dev); |
| 2808 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2809 | retval = em28xx_register_analog_devices(dev); |
| 2810 | if (retval < 0) { |
| 2811 | em28xx_release_resources(dev); |
| 2812 | goto fail_reg_devices; |
| 2813 | } |
| 2814 | |
| 2815 | em28xx_init_extension(dev); |
| 2816 | |
| 2817 | /* Save some power by putting tuner to sleep */ |
Laurent Pinchart | 622b828 | 2009-10-05 10:48:17 -0300 | [diff] [blame] | 2818 | v4l2_device_call_all(&dev->v4l2_dev, 0, core, s_power, 0); |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2819 | |
| 2820 | return 0; |
| 2821 | |
| 2822 | fail_reg_devices: |
| 2823 | return retval; |
| 2824 | } |
| 2825 | |
| 2826 | /* |
| 2827 | * em28xx_usb_probe() |
| 2828 | * checks for supported devices |
| 2829 | */ |
| 2830 | static int em28xx_usb_probe(struct usb_interface *interface, |
| 2831 | const struct usb_device_id *id) |
| 2832 | { |
| 2833 | const struct usb_endpoint_descriptor *endpoint; |
| 2834 | struct usb_device *udev; |
| 2835 | struct usb_interface *uif; |
| 2836 | struct em28xx *dev = NULL; |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2837 | int retval; |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2838 | int i, nr, ifnum, isoc_pipe; |
| 2839 | char *speed; |
| 2840 | char descr[255] = ""; |
| 2841 | |
| 2842 | udev = usb_get_dev(interface_to_usbdev(interface)); |
| 2843 | ifnum = interface->altsetting[0].desc.bInterfaceNumber; |
| 2844 | |
| 2845 | /* Check to see next free device and mark as used */ |
| 2846 | nr = find_first_zero_bit(&em28xx_devused, EM28XX_MAXBOARDS); |
| 2847 | em28xx_devused |= 1<<nr; |
| 2848 | |
| 2849 | /* Don't register audio interfaces */ |
| 2850 | if (interface->altsetting[0].desc.bInterfaceClass == USB_CLASS_AUDIO) { |
| 2851 | em28xx_err(DRIVER_NAME " audio device (%04x:%04x): " |
| 2852 | "interface %i, class %i\n", |
| 2853 | le16_to_cpu(udev->descriptor.idVendor), |
| 2854 | le16_to_cpu(udev->descriptor.idProduct), |
| 2855 | ifnum, |
| 2856 | interface->altsetting[0].desc.bInterfaceClass); |
| 2857 | |
| 2858 | em28xx_devused &= ~(1<<nr); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2859 | retval = -ENODEV; |
| 2860 | goto err; |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2861 | } |
| 2862 | |
| 2863 | endpoint = &interface->cur_altsetting->endpoint[0].desc; |
| 2864 | |
| 2865 | /* check if the device has the iso in endpoint at the correct place */ |
Julia Lawall | 1341798 | 2008-12-29 21:49:22 -0300 | [diff] [blame] | 2866 | if (usb_endpoint_xfer_isoc(endpoint) |
| 2867 | && |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2868 | (interface->altsetting[1].endpoint[0].desc.wMaxPacketSize == 940)) { |
| 2869 | /* It's a newer em2874/em2875 device */ |
| 2870 | isoc_pipe = 0; |
| 2871 | } else { |
| 2872 | int check_interface = 1; |
| 2873 | isoc_pipe = 1; |
| 2874 | endpoint = &interface->cur_altsetting->endpoint[1].desc; |
Julia Lawall | 2230c3c | 2009-01-03 16:53:10 -0300 | [diff] [blame] | 2875 | if (!usb_endpoint_xfer_isoc(endpoint)) |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2876 | check_interface = 0; |
| 2877 | |
Julia Lawall | 1341798 | 2008-12-29 21:49:22 -0300 | [diff] [blame] | 2878 | if (usb_endpoint_dir_out(endpoint)) |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2879 | check_interface = 0; |
| 2880 | |
| 2881 | if (!check_interface) { |
| 2882 | em28xx_err(DRIVER_NAME " video device (%04x:%04x): " |
| 2883 | "interface %i, class %i found.\n", |
| 2884 | le16_to_cpu(udev->descriptor.idVendor), |
| 2885 | le16_to_cpu(udev->descriptor.idProduct), |
| 2886 | ifnum, |
| 2887 | interface->altsetting[0].desc.bInterfaceClass); |
| 2888 | |
| 2889 | em28xx_err(DRIVER_NAME " This is an anciliary " |
| 2890 | "interface not used by the driver\n"); |
| 2891 | |
| 2892 | em28xx_devused &= ~(1<<nr); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2893 | retval = -ENODEV; |
| 2894 | goto err; |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2895 | } |
| 2896 | } |
| 2897 | |
| 2898 | switch (udev->speed) { |
| 2899 | case USB_SPEED_LOW: |
| 2900 | speed = "1.5"; |
| 2901 | break; |
| 2902 | case USB_SPEED_UNKNOWN: |
| 2903 | case USB_SPEED_FULL: |
| 2904 | speed = "12"; |
| 2905 | break; |
| 2906 | case USB_SPEED_HIGH: |
| 2907 | speed = "480"; |
| 2908 | break; |
| 2909 | default: |
| 2910 | speed = "unknown"; |
| 2911 | } |
| 2912 | |
| 2913 | if (udev->manufacturer) |
| 2914 | strlcpy(descr, udev->manufacturer, sizeof(descr)); |
| 2915 | |
| 2916 | if (udev->product) { |
| 2917 | if (*descr) |
| 2918 | strlcat(descr, " ", sizeof(descr)); |
| 2919 | strlcat(descr, udev->product, sizeof(descr)); |
| 2920 | } |
| 2921 | if (*descr) |
| 2922 | strlcat(descr, " ", sizeof(descr)); |
| 2923 | |
| 2924 | printk(DRIVER_NAME ": New device %s@ %s Mbps " |
| 2925 | "(%04x:%04x, interface %d, class %d)\n", |
| 2926 | descr, |
| 2927 | speed, |
| 2928 | le16_to_cpu(udev->descriptor.idVendor), |
| 2929 | le16_to_cpu(udev->descriptor.idProduct), |
| 2930 | ifnum, |
| 2931 | interface->altsetting->desc.bInterfaceNumber); |
| 2932 | |
Devin Heitmueller | 64a00b4 | 2009-05-27 23:23:37 -0300 | [diff] [blame] | 2933 | /* |
| 2934 | * Make sure we have 480 Mbps of bandwidth, otherwise things like |
| 2935 | * video stream wouldn't likely work, since 12 Mbps is generally |
| 2936 | * not enough even for most Digital TV streams. |
| 2937 | */ |
Devin Heitmueller | e2a1b79 | 2009-05-27 23:44:10 -0300 | [diff] [blame] | 2938 | if (udev->speed != USB_SPEED_HIGH && disable_usb_speed_check == 0) { |
Devin Heitmueller | 64a00b4 | 2009-05-27 23:23:37 -0300 | [diff] [blame] | 2939 | printk(DRIVER_NAME ": Device initialization failed.\n"); |
| 2940 | printk(DRIVER_NAME ": Device must be connected to a high-speed" |
| 2941 | " USB 2.0 port.\n"); |
| 2942 | em28xx_devused &= ~(1<<nr); |
| 2943 | retval = -ENODEV; |
| 2944 | goto err; |
| 2945 | } |
| 2946 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2947 | if (nr >= EM28XX_MAXBOARDS) { |
| 2948 | printk(DRIVER_NAME ": Supports only %i em28xx boards.\n", |
| 2949 | EM28XX_MAXBOARDS); |
| 2950 | em28xx_devused &= ~(1<<nr); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2951 | retval = -ENOMEM; |
| 2952 | goto err; |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2953 | } |
| 2954 | |
| 2955 | /* allocate memory for our device state and initialize it */ |
| 2956 | dev = kzalloc(sizeof(*dev), GFP_KERNEL); |
| 2957 | if (dev == NULL) { |
| 2958 | em28xx_err(DRIVER_NAME ": out of memory!\n"); |
| 2959 | em28xx_devused &= ~(1<<nr); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2960 | retval = -ENOMEM; |
| 2961 | goto err; |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2962 | } |
| 2963 | |
| 2964 | snprintf(dev->name, 29, "em28xx #%d", nr); |
| 2965 | dev->devno = nr; |
| 2966 | dev->model = id->driver_info; |
| 2967 | dev->alt = -1; |
| 2968 | |
| 2969 | /* Checks if audio is provided by some interface */ |
| 2970 | for (i = 0; i < udev->config->desc.bNumInterfaces; i++) { |
| 2971 | uif = udev->config->interface[i]; |
| 2972 | if (uif->altsetting[0].desc.bInterfaceClass == USB_CLASS_AUDIO) { |
| 2973 | dev->has_audio_class = 1; |
| 2974 | break; |
| 2975 | } |
| 2976 | } |
| 2977 | |
| 2978 | /* compute alternate max packet sizes */ |
| 2979 | uif = udev->actconfig->interface[0]; |
| 2980 | |
| 2981 | dev->num_alt = uif->num_altsetting; |
| 2982 | dev->alt_max_pkt_size = kmalloc(32 * dev->num_alt, GFP_KERNEL); |
| 2983 | |
| 2984 | if (dev->alt_max_pkt_size == NULL) { |
| 2985 | em28xx_errdev("out of memory!\n"); |
| 2986 | em28xx_devused &= ~(1<<nr); |
| 2987 | kfree(dev); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 2988 | retval = -ENOMEM; |
| 2989 | goto err; |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 2990 | } |
| 2991 | |
| 2992 | for (i = 0; i < dev->num_alt ; i++) { |
| 2993 | u16 tmp = le16_to_cpu(uif->altsetting[i].endpoint[isoc_pipe].desc.wMaxPacketSize); |
| 2994 | dev->alt_max_pkt_size[i] = |
| 2995 | (tmp & 0x07ff) * (((tmp & 0x1800) >> 11) + 1); |
| 2996 | } |
| 2997 | |
| 2998 | if ((card[nr] >= 0) && (card[nr] < em28xx_bcount)) |
| 2999 | dev->model = card[nr]; |
| 3000 | |
| 3001 | /* allocate device struct */ |
| 3002 | mutex_init(&dev->lock); |
| 3003 | mutex_lock(&dev->lock); |
Mauro Carvalho Chehab | 36fa674 | 2009-04-05 08:02:15 -0300 | [diff] [blame] | 3004 | retval = em28xx_init_dev(&dev, udev, interface, nr); |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 3005 | if (retval) { |
| 3006 | em28xx_devused &= ~(1<<dev->devno); |
Jiri Slaby | 11b79ea | 2009-07-05 14:06:41 -0300 | [diff] [blame] | 3007 | mutex_unlock(&dev->lock); |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 3008 | kfree(dev); |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 3009 | goto err; |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 3010 | } |
| 3011 | |
| 3012 | /* save our data pointer in this interface device */ |
| 3013 | usb_set_intfdata(interface, dev); |
| 3014 | |
| 3015 | request_modules(dev); |
| 3016 | |
| 3017 | /* Should be the last thing to do, to avoid newer udev's to |
| 3018 | open the device before fully initializing it |
| 3019 | */ |
| 3020 | mutex_unlock(&dev->lock); |
| 3021 | |
| 3022 | return 0; |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 3023 | |
| 3024 | err: |
| 3025 | return retval; |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 3026 | } |
| 3027 | |
| 3028 | /* |
| 3029 | * em28xx_usb_disconnect() |
| 3030 | * called when the device gets diconencted |
| 3031 | * video device will be unregistered on v4l2_close in case it is still open |
| 3032 | */ |
| 3033 | static void em28xx_usb_disconnect(struct usb_interface *interface) |
| 3034 | { |
| 3035 | struct em28xx *dev; |
| 3036 | |
| 3037 | dev = usb_get_intfdata(interface); |
| 3038 | usb_set_intfdata(interface, NULL); |
| 3039 | |
| 3040 | if (!dev) |
| 3041 | return; |
| 3042 | |
| 3043 | em28xx_info("disconnecting %s\n", dev->vdev->name); |
| 3044 | |
| 3045 | /* wait until all current v4l2 io is finished then deallocate |
| 3046 | resources */ |
| 3047 | mutex_lock(&dev->lock); |
| 3048 | |
| 3049 | wake_up_interruptible_all(&dev->open); |
| 3050 | |
Douglas Schilling Landgraf | f2cf250 | 2009-03-31 17:10:58 -0300 | [diff] [blame] | 3051 | v4l2_device_disconnect(&dev->v4l2_dev); |
| 3052 | |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 3053 | if (dev->users) { |
| 3054 | em28xx_warn |
Laurent Pinchart | 38c7c03 | 2009-11-27 13:57:15 -0300 | [diff] [blame] | 3055 | ("device %s is open! Deregistration and memory " |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 3056 | "deallocation are deferred on close.\n", |
Laurent Pinchart | 38c7c03 | 2009-11-27 13:57:15 -0300 | [diff] [blame] | 3057 | video_device_node_name(dev->vdev)); |
Mauro Carvalho Chehab | 1a23f81 | 2008-12-28 22:18:14 -0300 | [diff] [blame] | 3058 | |
| 3059 | dev->state |= DEV_MISCONFIGURED; |
| 3060 | em28xx_uninit_isoc(dev); |
| 3061 | dev->state |= DEV_DISCONNECTED; |
| 3062 | wake_up_interruptible(&dev->wait_frame); |
| 3063 | wake_up_interruptible(&dev->wait_stream); |
| 3064 | } else { |
| 3065 | dev->state |= DEV_DISCONNECTED; |
| 3066 | em28xx_release_resources(dev); |
| 3067 | } |
| 3068 | |
| 3069 | em28xx_close_extension(dev); |
| 3070 | |
| 3071 | mutex_unlock(&dev->lock); |
| 3072 | |
| 3073 | if (!dev->users) { |
| 3074 | kfree(dev->alt_max_pkt_size); |
| 3075 | kfree(dev); |
| 3076 | } |
| 3077 | } |
| 3078 | |
| 3079 | static struct usb_driver em28xx_usb_driver = { |
| 3080 | .name = "em28xx", |
| 3081 | .probe = em28xx_usb_probe, |
| 3082 | .disconnect = em28xx_usb_disconnect, |
| 3083 | .id_table = em28xx_id_table, |
| 3084 | }; |
| 3085 | |
| 3086 | static int __init em28xx_module_init(void) |
| 3087 | { |
| 3088 | int result; |
| 3089 | |
| 3090 | /* register this driver with the USB subsystem */ |
| 3091 | result = usb_register(&em28xx_usb_driver); |
| 3092 | if (result) |
| 3093 | em28xx_err(DRIVER_NAME |
| 3094 | " usb_register failed. Error number %d.\n", result); |
| 3095 | |
| 3096 | printk(KERN_INFO DRIVER_NAME " driver loaded\n"); |
| 3097 | |
| 3098 | return result; |
| 3099 | } |
| 3100 | |
| 3101 | static void __exit em28xx_module_exit(void) |
| 3102 | { |
| 3103 | /* deregister this driver with the USB subsystem */ |
| 3104 | usb_deregister(&em28xx_usb_driver); |
| 3105 | } |
| 3106 | |
| 3107 | module_init(em28xx_module_init); |
| 3108 | module_exit(em28xx_module_exit); |