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