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