Commit ec709bb8 authored by Thierry MERLE's avatar Thierry MERLE Committed by Mauro Carvalho Chehab

V4L/DVB (5530): Usbvision: remove CustomDevice facility

usbvision has a module parameter that ables the user to add a new USB 
entry at driver load. This functionality is useless by experience 
(adding statically the entry is easy). 

Furthermore, the USB_DEVICE(0xfff0, 0xfff0) USB entry caused 
usbvision_probe to be called for all unclaimed devices. 
Signed-off-by: default avatarThierry MERLE <thierry.merle@free.fr>
Acked-by: default avatarDwaine Garden <DwaineGarden@rogers.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@infradead.org>
parent 25f30389
0 -> Custom Dummy USBVision Device [fff0:fff0] 0 -> Xanboo [0a6f:0400]
1 -> Xanboo [0a6f:0400] 1 -> Belkin USB VideoBus II Adapter [050d:0106]
2 -> Belkin USB VideoBus II Adapter [050d:0106] 2 -> Belkin Components USB VideoBus [050d:0207]
3 -> Belkin Components USB VideoBus [050d:0207] 3 -> Belkin USB VideoBus II [050d:0208]
4 -> Belkin USB VideoBus II [050d:0208] 4 -> echoFX InterView Lite [0571:0002]
5 -> echoFX InterView Lite [0571:0002] 5 -> USBGear USBG-V1 resp. HAMA USB [0573:0003]
6 -> USBGear USBG-V1 resp. HAMA USB [0573:0003] 6 -> D-Link V100 [0573:0400]
7 -> D-Link V100 [0573:0400] 7 -> X10 USB Camera [0573:2000]
8 -> X10 USB Camera [0573:2000] 8 -> Hauppauge WinTV USB Live (PAL B/G) [0573:2d00]
9 -> Hauppauge WinTV USB Live (PAL B/G) [0573:2d00] 9 -> Hauppauge WinTV USB Live Pro (NTSC M/N) [0573:2d01]
10 -> Hauppauge WinTV USB Live Pro (NTSC M/N) [0573:2d01] 10 -> Zoran Co. PMD (Nogatech) AV-grabber Manhattan [0573:2101]
11 -> Zoran Co. PMD (Nogatech) AV-grabber Manhattan [0573:2101] 11 -> Nogatech USB-TV (NTSC) FM [0573:4100]
12 -> Nogatech USB-TV (NTSC) FM [0573:4100] 12 -> PNY USB-TV (NTSC) FM [0573:4110]
13 -> PNY USB-TV (NTSC) FM [0573:4110] 13 -> PixelView PlayTv-USB PRO (PAL) FM [0573:4450]
14 -> PixelView PlayTv-USB PRO (PAL) FM [0573:4450] 14 -> ZTV ZT-721 2.4GHz USB A/V Receiver [0573:4550]
15 -> ZTV ZT-721 2.4GHz USB A/V Receiver [0573:4550] 15 -> Hauppauge WinTV USB (NTSC M/N) [0573:4d00]
16 -> Hauppauge WinTV USB (NTSC M/N) [0573:4d00] 16 -> Hauppauge WinTV USB (PAL B/G) [0573:4d01]
17 -> Hauppauge WinTV USB (PAL B/G) [0573:4d01] 17 -> Hauppauge WinTV USB (PAL I) [0573:4d02]
18 -> Hauppauge WinTV USB (PAL I) [0573:4d02] 18 -> Hauppauge WinTV USB (PAL/SECAM L) [0573:4d03]
19 -> Hauppauge WinTV USB (PAL/SECAM L) [0573:4d03] 19 -> Hauppauge WinTV USB (PAL D/K) [0573:4d04]
20 -> Hauppauge WinTV USB (PAL D/K) [0573:4d04] 20 -> Hauppauge WinTV USB (NTSC FM) [0573:4d10]
21 -> Hauppauge WinTV USB (NTSC FM) [0573:4d10] 21 -> Hauppauge WinTV USB (PAL B/G FM) [0573:4d11]
22 -> Hauppauge WinTV USB (PAL B/G FM) [0573:4d11] 22 -> Hauppauge WinTV USB (PAL I FM) [0573:4d12]
23 -> Hauppauge WinTV USB (PAL I FM) [0573:4d12] 23 -> Hauppauge WinTV USB (PAL D/K FM) [0573:4d14]
24 -> Hauppauge WinTV USB (PAL D/K FM) [0573:4d14] 24 -> Hauppauge WinTV USB Pro (NTSC M/N) [0573:4d2a]
25 -> Hauppauge WinTV USB Pro (NTSC M/N) [0573:4d2a] 25 -> Hauppauge WinTV USB Pro (NTSC M/N) V2 [0573:4d2b]
26 -> Hauppauge WinTV USB Pro (NTSC M/N) V2 [0573:4d2b] 26 -> Hauppauge WinTV USB Pro (PAL/SECAM B/G/I/D/K/L) [0573:4d2c]
27 -> Hauppauge WinTV USB Pro (PAL/SECAM B/G/I/D/K/L) [0573:4d2c] 27 -> Hauppauge WinTV USB Pro (NTSC M/N) V3 [0573:4d20]
28 -> Hauppauge WinTV USB Pro (NTSC M/N) V3 [0573:4d20] 28 -> Hauppauge WinTV USB Pro (PAL B/G) [0573:4d21]
29 -> Hauppauge WinTV USB Pro (PAL B/G) [0573:4d21] 29 -> Hauppauge WinTV USB Pro (PAL I) [0573:4d22]
30 -> Hauppauge WinTV USB Pro (PAL I) [0573:4d22] 30 -> Hauppauge WinTV USB Pro (PAL/SECAM L) [0573:4d23]
31 -> Hauppauge WinTV USB Pro (PAL/SECAM L) [0573:4d23] 31 -> Hauppauge WinTV USB Pro (PAL D/K) [0573:4d24]
32 -> Hauppauge WinTV USB Pro (PAL D/K) [0573:4d24] 32 -> Hauppauge WinTV USB Pro (PAL/SECAM BGDK/I/L) [0573:4d25]
33 -> Hauppauge WinTV USB Pro (PAL/SECAM BGDK/I/L) [0573:4d25] 33 -> Hauppauge WinTV USB Pro (PAL/SECAM BGDK/I/L) V2 [0573:4d26]
34 -> Hauppauge WinTV USB Pro (PAL/SECAM BGDK/I/L) V2 [0573:4d26] 34 -> Hauppauge WinTV USB Pro (PAL B/G) V2 [0573:4d27]
35 -> Hauppauge WinTV USB Pro (PAL B/G) V2 [0573:4d27] 35 -> Hauppauge WinTV USB Pro (PAL B/G,D/K) [0573:4d28]
36 -> Hauppauge WinTV USB Pro (PAL B/G,D/K) [0573:4d28] 36 -> Hauppauge WinTV USB Pro (PAL I,D/K) [0573:4d29]
37 -> Hauppauge WinTV USB Pro (PAL I,D/K) [0573:4d29] 37 -> Hauppauge WinTV USB Pro (NTSC M/N FM) [0573:4d30]
38 -> Hauppauge WinTV USB Pro (NTSC M/N FM) [0573:4d30] 38 -> Hauppauge WinTV USB Pro (PAL B/G FM) [0573:4d31]
39 -> Hauppauge WinTV USB Pro (PAL B/G FM) [0573:4d31] 39 -> Hauppauge WinTV USB Pro (PAL I FM) [0573:4d32]
40 -> Hauppauge WinTV USB Pro (PAL I FM) [0573:4d32] 40 -> Hauppauge WinTV USB Pro (PAL D/K FM) [0573:4d34]
41 -> Hauppauge WinTV USB Pro (PAL D/K FM) [0573:4d34] 41 -> Hauppauge WinTV USB Pro (Temic PAL/SECAM B/G/I/D/K/L FM) [0573:4d35]
42 -> Hauppauge WinTV USB Pro (Temic PAL/SECAM B/G/I/D/K/L FM) [0573:4d35] 42 -> Hauppauge WinTV USB Pro (Temic PAL B/G FM) [0573:4d36]
43 -> Hauppauge WinTV USB Pro (Temic PAL B/G FM) [0573:4d36] 43 -> Hauppauge WinTV USB Pro (PAL/SECAM B/G/I/D/K/L FM) [0573:4d37]
44 -> Hauppauge WinTV USB Pro (PAL/SECAM B/G/I/D/K/L FM) [0573:4d37] 44 -> Hauppauge WinTV USB Pro (NTSC M/N FM) V2 [0573:4d38]
45 -> Hauppauge WinTV USB Pro (NTSC M/N FM) V2 [0573:4d38] 45 -> Camtel Technology USB TV Genie Pro FM Model TVB330 [0768:0006]
46 -> Camtel Technology USB TV Genie Pro FM Model TVB330 [0768:0006] 46 -> Digital Video Creator I [07d0:0001]
47 -> Digital Video Creator I [07d0:0001] 47 -> Global Village GV-007 (NTSC) [07d0:0002]
48 -> Global Village GV-007 (NTSC) [07d0:0002] 48 -> Dazzle Fusion Model DVC-50 Rev 1 (NTSC) [07d0:0003]
49 -> Dazzle Fusion Model DVC-50 Rev 1 (NTSC) [07d0:0003] 49 -> Dazzle Fusion Model DVC-80 Rev 1 (PAL) [07d0:0004]
50 -> Dazzle Fusion Model DVC-80 Rev 1 (PAL) [07d0:0004] 50 -> Dazzle Fusion Model DVC-90 Rev 1 (SECAM) [07d0:0005]
51 -> Dazzle Fusion Model DVC-90 Rev 1 (SECAM) [07d0:0005] 51 -> Eskape Labs MyTV2Go [07f8:9104]
52 -> Eskape Labs MyTV2Go [07f8:9104] 52 -> Pinnacle Studio PCTV USB (PAL) [2304:010d]
53 -> Pinnacle Studio PCTV USB (PAL) [2304:010d] 53 -> Pinnacle Studio PCTV USB (SECAM) [2304:0109]
54 -> Pinnacle Studio PCTV USB (SECAM) [2304:0109] 54 -> Pinnacle Studio PCTV USB (PAL) FM [2304:0110]
55 -> Pinnacle Studio PCTV USB (PAL) FM [2304:0110] 55 -> Miro PCTV USB [2304:0111]
56 -> Miro PCTV USB [2304:0111] 56 -> Pinnacle Studio PCTV USB (NTSC) FM [2304:0112]
57 -> Pinnacle Studio PCTV USB (NTSC) FM [2304:0112] 57 -> Pinnacle Studio PCTV USB (PAL) FM V2 [2304:0210]
58 -> Pinnacle Studio PCTV USB (PAL) FM V2 [2304:0210] 58 -> Pinnacle Studio PCTV USB (NTSC) FM V2 [2304:0212]
59 -> Pinnacle Studio PCTV USB (NTSC) FM V2 [2304:0212] 59 -> Pinnacle Studio PCTV USB (PAL) FM V3 [2304:0214]
60 -> Pinnacle Studio PCTV USB (PAL) FM V3 [2304:0214] 60 -> Pinnacle Studio Linx Video input cable (NTSC) [2304:0300]
61 -> Pinnacle Studio Linx Video input cable (NTSC) [2304:0300] 61 -> Pinnacle Studio Linx Video input cable (PAL) [2304:0301]
62 -> Pinnacle Studio Linx Video input cable (PAL) [2304:0301] 62 -> Pinnacle PCTV Bungee USB (PAL) FM [2304:0419]
63 -> Pinnacle PCTV Bungee USB (PAL) FM [2304:0419] 63 -> Hauppauge WinTv-USB [2400:4200]
64 -> Hauppauge WinTv-USB [2400:4200]
...@@ -32,20 +32,6 @@ ...@@ -32,20 +32,6 @@
/* Supported Devices: A table for usbvision.c*/ /* Supported Devices: A table for usbvision.c*/
struct usbvision_device_data_st usbvision_device_data[] = { struct usbvision_device_data_st usbvision_device_data[] = {
[DUMMY_DEVICE] = {
.Interface = -1,
.Codec = CODEC_SAA7111,
.VideoChannels = 3,
.VideoNorm = V4L2_STD_NTSC,
.AudioChannels = 1,
.Radio = 1,
.vbi = 1,
.Tuner = 1,
.TunerType = TUNER_PHILIPS_NTSC_M,
.X_Offset = -1,
.Y_Offset = -1,
.ModelString = "Custom Dummy USBVision Device",
},
[XANBOO] = { [XANBOO] = {
.Interface = -1, .Interface = -1,
.Codec = CODEC_SAA7113, .Codec = CODEC_SAA7113,
...@@ -1032,7 +1018,6 @@ const int usbvision_device_data_size=ARRAY_SIZE(usbvision_device_data); ...@@ -1032,7 +1018,6 @@ const int usbvision_device_data_size=ARRAY_SIZE(usbvision_device_data);
/* Supported Devices */ /* Supported Devices */
struct usb_device_id usbvision_table [] = { struct usb_device_id usbvision_table [] = {
{ USB_DEVICE(0xfff0, 0xfff0), .driver_info=DUMMY_DEVICE },
{ USB_DEVICE(0x0a6f, 0x0400), .driver_info=XANBOO }, { USB_DEVICE(0x0a6f, 0x0400), .driver_info=XANBOO },
{ USB_DEVICE(0x050d, 0x0106), .driver_info=BELKIN_VIDEOBUS_II }, { USB_DEVICE(0x050d, 0x0106), .driver_info=BELKIN_VIDEOBUS_II },
{ USB_DEVICE(0x050d, 0x0207), .driver_info=BELKIN_VIDEOBUS }, { USB_DEVICE(0x050d, 0x0207), .driver_info=BELKIN_VIDEOBUS },
......
#define DUMMY_DEVICE 0 #define XANBOO 0
#define XANBOO 1 #define BELKIN_VIDEOBUS_II 1
#define BELKIN_VIDEOBUS_II 2 #define BELKIN_VIDEOBUS 2
#define BELKIN_VIDEOBUS 3 #define BELKIN_USB_VIDEOBUS_II 3
#define BELKIN_USB_VIDEOBUS_II 4 #define ECHOFX_INTERVIEW_LITE 4
#define ECHOFX_INTERVIEW_LITE 5 #define USBGEAR_USBG_V1 5
#define USBGEAR_USBG_V1 6 #define D_LINK_V100 6
#define D_LINK_V100 7 #define X10_USB_CAMERA 7
#define X10_USB_CAMERA 8 #define HPG_WINTV_LIVE_PAL_BG 8
#define HPG_WINTV_LIVE_PAL_BG 9 #define HPG_WINTV_LIVE_PRO_NTSC_MN 9
#define HPG_WINTV_LIVE_PRO_NTSC_MN 10 #define ZORAN_PMD_NOGATECH 10
#define ZORAN_PMD_NOGATECH 11 #define NOGATECH_USB_TV_NTSC_FM 11
#define NOGATECH_USB_TV_NTSC_FM 12 #define PNY_USB_TV_NTSC_FM 12
#define PNY_USB_TV_NTSC_FM 13 #define PV_PLAYTV_USB_PRO_PAL_FM 13
#define PV_PLAYTV_USB_PRO_PAL_FM 14 #define ZT_721 14
#define ZT_721 15 #define HPG_WINTV_NTSC_MN 15
#define HPG_WINTV_NTSC_MN 16 #define HPG_WINTV_PAL_BG 16
#define HPG_WINTV_PAL_BG 17 #define HPG_WINTV_PAL_I 17
#define HPG_WINTV_PAL_I 18 #define HPG_WINTV_PAL_SECAM_L 18
#define HPG_WINTV_PAL_SECAM_L 19 #define HPG_WINTV_PAL_D_K 19
#define HPG_WINTV_PAL_D_K 20 #define HPG_WINTV_NTSC_FM 20
#define HPG_WINTV_NTSC_FM 21 #define HPG_WINTV_PAL_BG_FM 21
#define HPG_WINTV_PAL_BG_FM 22 #define HPG_WINTV_PAL_I_FM 22
#define HPG_WINTV_PAL_I_FM 23 #define HPG_WINTV_PAL_D_K_FM 23
#define HPG_WINTV_PAL_D_K_FM 24 #define HPG_WINTV_PRO_NTSC_MN 24
#define HPG_WINTV_PRO_NTSC_MN 25 #define HPG_WINTV_PRO_NTSC_MN_V2 25
#define HPG_WINTV_PRO_NTSC_MN_V2 26 #define HPG_WINTV_PRO_PAL 26
#define HPG_WINTV_PRO_PAL 27 #define HPG_WINTV_PRO_NTSC_MN_V3 27
#define HPG_WINTV_PRO_NTSC_MN_V3 28 #define HPG_WINTV_PRO_PAL_BG 28
#define HPG_WINTV_PRO_PAL_BG 29 #define HPG_WINTV_PRO_PAL_I 29
#define HPG_WINTV_PRO_PAL_I 30 #define HPG_WINTV_PRO_PAL_SECAM_L 30
#define HPG_WINTV_PRO_PAL_SECAM_L 31 #define HPG_WINTV_PRO_PAL_D_K 31
#define HPG_WINTV_PRO_PAL_D_K 32 #define HPG_WINTV_PRO_PAL_SECAM 32
#define HPG_WINTV_PRO_PAL_SECAM 33 #define HPG_WINTV_PRO_PAL_SECAM_V2 33
#define HPG_WINTV_PRO_PAL_SECAM_V2 34 #define HPG_WINTV_PRO_PAL_BG_V2 34
#define HPG_WINTV_PRO_PAL_BG_V2 35 #define HPG_WINTV_PRO_PAL_BG_D_K 35
#define HPG_WINTV_PRO_PAL_BG_D_K 36 #define HPG_WINTV_PRO_PAL_I_D_K 36
#define HPG_WINTV_PRO_PAL_I_D_K 37 #define HPG_WINTV_PRO_NTSC_MN_FM 37
#define HPG_WINTV_PRO_NTSC_MN_FM 38 #define HPG_WINTV_PRO_PAL_BG_FM 38
#define HPG_WINTV_PRO_PAL_BG_FM 39 #define HPG_WINTV_PRO_PAL_I_FM 39
#define HPG_WINTV_PRO_PAL_I_FM 40 #define HPG_WINTV_PRO_PAL_D_K_FM 40
#define HPG_WINTV_PRO_PAL_D_K_FM 41 #define HPG_WINTV_PRO_TEMIC_PAL_FM 41
#define HPG_WINTV_PRO_TEMIC_PAL_FM 42 #define HPG_WINTV_PRO_TEMIC_PAL_BG_FM 42
#define HPG_WINTV_PRO_TEMIC_PAL_BG_FM 43 #define HPG_WINTV_PRO_PAL_FM 43
#define HPG_WINTV_PRO_PAL_FM 44 #define HPG_WINTV_PRO_NTSC_MN_FM_V2 44
#define HPG_WINTV_PRO_NTSC_MN_FM_V2 45 #define CAMTEL_TVB330 45
#define CAMTEL_TVB330 46 #define DIGITAL_VIDEO_CREATOR_I 46
#define DIGITAL_VIDEO_CREATOR_I 47 #define GLOBAL_VILLAGE_GV_007_NTSC 47
#define GLOBAL_VILLAGE_GV_007_NTSC 48 #define DAZZLE_DVC_50_REV_1_NTSC 48
#define DAZZLE_DVC_50_REV_1_NTSC 49 #define DAZZLE_DVC_80_REV_1_PAL 49
#define DAZZLE_DVC_80_REV_1_PAL 50 #define DAZZLE_DVC_90_REV_1_SECAM 50
#define DAZZLE_DVC_90_REV_1_SECAM 51 #define ESKAPE_LABS_MYTV2GO 51
#define ESKAPE_LABS_MYTV2GO 52 #define PINNA_PCTV_USB_PAL 52
#define PINNA_PCTV_USB_PAL 53 #define PINNA_PCTV_USB_SECAM 53
#define PINNA_PCTV_USB_SECAM 54 #define PINNA_PCTV_USB_PAL_FM 54
#define PINNA_PCTV_USB_PAL_FM 55 #define MIRO_PCTV_USB 55
#define MIRO_PCTV_USB 56 #define PINNA_PCTV_USB_NTSC_FM 56
#define PINNA_PCTV_USB_NTSC_FM 57 #define PINNA_PCTV_USB_PAL_FM_V2 57
#define PINNA_PCTV_USB_PAL_FM_V2 58 #define PINNA_PCTV_USB_NTSC_FM_V2 58
#define PINNA_PCTV_USB_NTSC_FM_V2 59 #define PINNA_PCTV_USB_PAL_FM_V3 59
#define PINNA_PCTV_USB_PAL_FM_V3 60 #define PINNA_LINX_VD_IN_CAB_NTSC 60
#define PINNA_LINX_VD_IN_CAB_NTSC 61 #define PINNA_LINX_VD_IN_CAB_PAL 61
#define PINNA_LINX_VD_IN_CAB_PAL 62 #define PINNA_PCTV_BUNGEE_PAL_FM 62
#define PINNA_PCTV_BUNGEE_PAL_FM 63 #define HPG_WINTV 63
#define HPG_WINTV 64
extern const int usbvision_device_data_size; extern const int usbvision_device_data_size;
...@@ -151,7 +151,6 @@ static int PowerOnAtOpen = 1; // Set the default device to power on at startu ...@@ -151,7 +151,6 @@ static int PowerOnAtOpen = 1; // Set the default device to power on at startu
static int video_nr = -1; // Sequential Number of Video Device static int video_nr = -1; // Sequential Number of Video Device
static int radio_nr = -1; // Sequential Number of Radio Device static int radio_nr = -1; // Sequential Number of Radio Device
static int vbi_nr = -1; // Sequential Number of VBI Device static int vbi_nr = -1; // Sequential Number of VBI Device
static char *CustomDevice=NULL; // Set as nothing....
// Grab parameters for the device driver // Grab parameters for the device driver
...@@ -162,7 +161,6 @@ module_param(PowerOnAtOpen, int, 0444); ...@@ -162,7 +161,6 @@ module_param(PowerOnAtOpen, int, 0444);
module_param(video_nr, int, 0444); module_param(video_nr, int, 0444);
module_param(radio_nr, int, 0444); module_param(radio_nr, int, 0444);
module_param(vbi_nr, int, 0444); module_param(vbi_nr, int, 0444);
module_param(CustomDevice, charp, 0444);
#else // Old Style #else // Old Style
MODULE_PARAM(isocMode, "i"); MODULE_PARAM(isocMode, "i");
MODULE_PARM(video_debug, "i"); // Grab the Debug Mode of the device driver MODULE_PARM(video_debug, "i"); // Grab the Debug Mode of the device driver
...@@ -172,7 +170,6 @@ MODULE_PARM(SwitchSVideoInput, "i"); // To help people with Black and White ou ...@@ -172,7 +170,6 @@ MODULE_PARM(SwitchSVideoInput, "i"); // To help people with Black and White ou
MODULE_PARM(video_nr, "i"); // video_nr option allows to specify a certain /dev/videoX device (like /dev/video0 or /dev/video1 ...) MODULE_PARM(video_nr, "i"); // video_nr option allows to specify a certain /dev/videoX device (like /dev/video0 or /dev/video1 ...)
MODULE_PARM(radio_nr, "i"); // radio_nr option allows to specify a certain /dev/radioX device (like /dev/radio0 or /dev/radio1 ...) MODULE_PARM(radio_nr, "i"); // radio_nr option allows to specify a certain /dev/radioX device (like /dev/radio0 or /dev/radio1 ...)
MODULE_PARM(vbi_nr, "i"); // vbi_nr option allows to specify a certain /dev/vbiX device (like /dev/vbi0 or /dev/vbi1 ...) MODULE_PARM(vbi_nr, "i"); // vbi_nr option allows to specify a certain /dev/vbiX device (like /dev/vbi0 or /dev/vbi1 ...)
MODULE_PARM(CustomDevice, "s"); // .... CustomDevice
#endif #endif
MODULE_PARM_DESC(isocMode, " Set the default format for ISOC endpoint. Default: 0x60 (Compression On)"); MODULE_PARM_DESC(isocMode, " Set the default format for ISOC endpoint. Default: 0x60 (Compression On)");
...@@ -181,7 +178,6 @@ MODULE_PARM_DESC(PowerOnAtOpen, " Set the default device to power on when device ...@@ -181,7 +178,6 @@ MODULE_PARM_DESC(PowerOnAtOpen, " Set the default device to power on when device
MODULE_PARM_DESC(video_nr, "Set video device number (/dev/videoX). Default: -1 (autodetect)"); MODULE_PARM_DESC(video_nr, "Set video device number (/dev/videoX). Default: -1 (autodetect)");
MODULE_PARM_DESC(radio_nr, "Set radio device number (/dev/radioX). Default: -1 (autodetect)"); MODULE_PARM_DESC(radio_nr, "Set radio device number (/dev/radioX). Default: -1 (autodetect)");
MODULE_PARM_DESC(vbi_nr, "Set vbi device number (/dev/vbiX). Default: -1 (autodetect)"); MODULE_PARM_DESC(vbi_nr, "Set vbi device number (/dev/vbiX). Default: -1 (autodetect)");
MODULE_PARM_DESC(CustomDevice, " Define the fine tuning parameters for the device. Default: null");
// Misc stuff // Misc stuff
...@@ -1943,143 +1939,6 @@ static struct usb_driver usbvision_driver = { ...@@ -1943,143 +1939,6 @@ static struct usb_driver usbvision_driver = {
.disconnect = usbvision_disconnect .disconnect = usbvision_disconnect
}; };
/*
* customdevice_process()
*
* This procedure preprocesses CustomDevice parameter if any
*
*/
static void customdevice_process(void)
{
unsigned int id_vend,id_prod,radio,tuner;
usbvision_device_data[0]=usbvision_device_data[1];
usbvision_table[0]=usbvision_table[1];
if(CustomDevice)
{
char *parse=CustomDevice;
int tmp;
PDEBUG(DBG_PROBE, "CustomDevice=%s", CustomDevice);
/*format is CustomDevice="0x0573 0x4D31 0 7113 3 PAL 1 1 1 5 -1 -1 -1 -1 -1"
usbvision_device_data[0].idVendor;
usbvision_device_data[0].idProduct;
usbvision_device_data[0].Interface;
usbvision_device_data[0].Codec;
usbvision_device_data[0].VideoChannels;
usbvision_device_data[0].VideoNorm;
usbvision_device_data[0].AudioChannels;
usbvision_device_data[0].Radio;
usbvision_device_data[0].Tuner;
usbvision_device_data[0].TunerType;
usbvision_device_data[0].Vin_Reg1;
usbvision_device_data[0].Vin_Reg2;
usbvision_device_data[0].X_Offset;
usbvision_device_data[0].Y_Offset;
usbvision_device_data[0].Dvi_yuv;
usbvision_device_data[0].ModelString;
*/
rmspace(parse);
usbvision_device_data[0].ModelString="USBVISION Custom Device";
parse+=2;
sscanf(parse,"%u",&id_vend);
usbvision_table[0].idVendor=id_vend;
goto2next(parse);
PDEBUG(DBG_PROBE, "idVendor=0x%.4X", usbvision_table[0].idVendor);
parse+=2;
sscanf(parse,"%u",&id_prod);
usbvision_table[0].idProduct=id_prod;
goto2next(parse);
PDEBUG(DBG_PROBE, "idProduct=0x%.4X", usbvision_table[0].idProduct);
sscanf(parse,"%d",&usbvision_device_data[0].Interface);
goto2next(parse);
PDEBUG(DBG_PROBE, "Interface=%d", usbvision_device_data[0].Interface);
sscanf(parse,"%hd",&usbvision_device_data[0].Codec);
goto2next(parse);
PDEBUG(DBG_PROBE, "Codec=%d", usbvision_device_data[0].Codec);
sscanf(parse,"%d",&tmp);
usbvision_device_data[0].VideoChannels = tmp;
goto2next(parse);
PDEBUG(DBG_PROBE, "VideoChannels=%d", usbvision_device_data[0].VideoChannels);
switch(*parse)
{
case 'P':
PDEBUG(DBG_PROBE, "VideoNorm=PAL");
usbvision_device_data[0].VideoNorm=V4L2_STD_PAL;
break;
case 'S':
PDEBUG(DBG_PROBE, "VideoNorm=SECAM");
usbvision_device_data[0].VideoNorm=V4L2_STD_SECAM;
break;
case 'N':
PDEBUG(DBG_PROBE, "VideoNorm=NTSC");
usbvision_device_data[0].VideoNorm=V4L2_STD_NTSC;
break;
default:
PDEBUG(DBG_PROBE, "VideoNorm=PAL (by default)");
usbvision_device_data[0].VideoNorm=V4L2_STD_PAL;
break;
}
goto2next(parse);
sscanf(parse,"%d",&tmp);
usbvision_device_data[0].AudioChannels = tmp;
goto2next(parse);
PDEBUG(DBG_PROBE, "AudioChannels=%d", usbvision_device_data[0].AudioChannels);
sscanf(parse,"%d",&radio);
usbvision_device_data[0].Radio=(radio?1:0);
goto2next(parse);
PDEBUG(DBG_PROBE, "Radio=%d", usbvision_device_data[0].Radio);
sscanf(parse,"%d",&tuner);
usbvision_device_data[0].Tuner=(tuner?1:0);
goto2next(parse);
PDEBUG(DBG_PROBE, "Tuner=%d", usbvision_device_data[0].Tuner);
sscanf(parse,"%hhu",&usbvision_device_data[0].TunerType);
goto2next(parse);
PDEBUG(DBG_PROBE, "TunerType=%d", usbvision_device_data[0].TunerType);
sscanf(parse,"%d",&tmp);
if(tmp>0) {
usbvision_device_data[0].Vin_Reg1_override = 1;
usbvision_device_data[0].Vin_Reg1 = tmp&0xff;
}
goto2next(parse);
PDEBUG(DBG_PROBE, "Vin_Reg1=%d", usbvision_device_data[0].Vin_Reg1);
sscanf(parse,"%d",&tmp);
if(tmp>0) {
usbvision_device_data[0].Vin_Reg2_override = 1;
usbvision_device_data[0].Vin_Reg2 = tmp&0xff;
}
goto2next(parse);
PDEBUG(DBG_PROBE, "Vin_Reg2=%d", usbvision_device_data[0].Vin_Reg2);
sscanf(parse,"%hd",&usbvision_device_data[0].X_Offset);
goto2next(parse);
PDEBUG(DBG_PROBE, "X_Offset=%d", usbvision_device_data[0].X_Offset);
sscanf(parse,"%hd",&usbvision_device_data[0].Y_Offset);
goto2next(parse);
PDEBUG(DBG_PROBE, "Y_Offset=%d", usbvision_device_data[0].Y_Offset);
sscanf(parse,"%d",&tmp);
if(tmp>0) {
usbvision_device_data[0].Dvi_yuv_override = 1;
usbvision_device_data[0].Dvi_yuv = tmp&0xff;
}
PDEBUG(DBG_PROBE, "Dvi_yuv=%d", usbvision_device_data[0].Dvi_yuv);
//add to usbvision_table also
usbvision_table[0].match_flags=USB_DEVICE_ID_MATCH_DEVICE;
}
}
/* /*
* usbvision_init() * usbvision_init()
* *
...@@ -2104,8 +1963,6 @@ static int __init usbvision_init(void) ...@@ -2104,8 +1963,6 @@ static int __init usbvision_init(void)
usbvision_v4l2_format[7].supported = 0; // V4L2_PIX_FMT_YUV422P usbvision_v4l2_format[7].supported = 0; // V4L2_PIX_FMT_YUV422P
} }
customdevice_process();
errCode = usb_register(&usbvision_driver); errCode = usb_register(&usbvision_driver);
if (errCode == 0) { if (errCode == 0) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment