18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0-or-later */
28c2ecf20Sopenharmony_ci/*
38c2ecf20Sopenharmony_ci    Functions to query card hardware
48c2ecf20Sopenharmony_ci    Copyright (C) 2003-2004  Kevin Thayer <nufan_wfk at yahoo.com>
58c2ecf20Sopenharmony_ci    Copyright (C) 2005-2007  Hans Verkuil <hverkuil@xs4all.nl>
68c2ecf20Sopenharmony_ci
78c2ecf20Sopenharmony_ci */
88c2ecf20Sopenharmony_ci
98c2ecf20Sopenharmony_ci#ifndef IVTV_CARDS_H
108c2ecf20Sopenharmony_ci#define IVTV_CARDS_H
118c2ecf20Sopenharmony_ci
128c2ecf20Sopenharmony_ci/* Supported cards */
138c2ecf20Sopenharmony_ci#define IVTV_CARD_PVR_250	      0	/* WinTV PVR 250 */
148c2ecf20Sopenharmony_ci#define IVTV_CARD_PVR_350	      1	/* encoder, decoder, tv-out */
158c2ecf20Sopenharmony_ci#define IVTV_CARD_PVR_150	      2	/* WinTV PVR 150 and PVR 500 (really just two
168c2ecf20Sopenharmony_ci					   PVR150s on one PCI board) */
178c2ecf20Sopenharmony_ci#define IVTV_CARD_M179		      3	/* AVerMedia M179 (encoder only) */
188c2ecf20Sopenharmony_ci#define IVTV_CARD_MPG600	      4	/* Kuroutoshikou ITVC16-STVLP/YUAN MPG600, encoder only */
198c2ecf20Sopenharmony_ci#define IVTV_CARD_MPG160	      5	/* Kuroutoshikou ITVC15-STVLP/YUAN MPG160
208c2ecf20Sopenharmony_ci					   cx23415 based, but does not have tv-out */
218c2ecf20Sopenharmony_ci#define IVTV_CARD_PG600		      6	/* YUAN PG600/DIAMONDMM PVR-550 based on the CX Falcon 2 */
228c2ecf20Sopenharmony_ci#define IVTV_CARD_AVC2410	      7	/* Adaptec AVC-2410 */
238c2ecf20Sopenharmony_ci#define IVTV_CARD_AVC2010	      8	/* Adaptec AVD-2010 (No Tuner) */
248c2ecf20Sopenharmony_ci#define IVTV_CARD_TG5000TV	      9 /* NAGASE TRANSGEAR 5000TV, encoder only */
258c2ecf20Sopenharmony_ci#define IVTV_CARD_VA2000MAX_SNT6     10 /* VA2000MAX-STN6 */
268c2ecf20Sopenharmony_ci#define IVTV_CARD_CX23416GYC	     11 /* Kuroutoshikou CX23416GYC-STVLP (Yuan MPG600GR OEM) */
278c2ecf20Sopenharmony_ci#define IVTV_CARD_GV_MVPRX	     12 /* I/O Data GV-MVP/RX, RX2, RX2W */
288c2ecf20Sopenharmony_ci#define IVTV_CARD_GV_MVPRX2E	     13 /* I/O Data GV-MVP/RX2E */
298c2ecf20Sopenharmony_ci#define IVTV_CARD_GOTVIEW_PCI_DVD    14	/* GotView PCI DVD */
308c2ecf20Sopenharmony_ci#define IVTV_CARD_GOTVIEW_PCI_DVD2   15	/* GotView PCI DVD2 */
318c2ecf20Sopenharmony_ci#define IVTV_CARD_YUAN_MPC622        16	/* Yuan MPC622 miniPCI */
328c2ecf20Sopenharmony_ci#define IVTV_CARD_DCTMTVP1	     17 /* DIGITAL COWBOY DCT-MTVP1 */
338c2ecf20Sopenharmony_ci#define IVTV_CARD_PG600V2	     18 /* Yuan PG600V2/GotView PCI DVD Lite */
348c2ecf20Sopenharmony_ci#define IVTV_CARD_CLUB3D	     19 /* Club3D ZAP-TV1x01 */
358c2ecf20Sopenharmony_ci#define IVTV_CARD_AVERTV_MCE116	     20 /* AVerTV MCE 116 Plus */
368c2ecf20Sopenharmony_ci#define IVTV_CARD_ASUS_FALCON2	     21 /* ASUS Falcon2 */
378c2ecf20Sopenharmony_ci#define IVTV_CARD_AVER_PVR150PLUS    22 /* AVerMedia PVR-150 Plus */
388c2ecf20Sopenharmony_ci#define IVTV_CARD_AVER_EZMAKER       23 /* AVerMedia EZMaker PCI Deluxe */
398c2ecf20Sopenharmony_ci#define IVTV_CARD_AVER_M104          24 /* AverMedia M104 miniPCI card */
408c2ecf20Sopenharmony_ci#define IVTV_CARD_BUFFALO_MV5L       25 /* Buffalo PC-MV5L/PCI card */
418c2ecf20Sopenharmony_ci#define IVTV_CARD_AVER_ULTRA1500MCE  26 /* AVerMedia UltraTV 1500 MCE */
428c2ecf20Sopenharmony_ci#define IVTV_CARD_KIKYOU             27 /* Sony VAIO Giga Pocket (ENX Kikyou) */
438c2ecf20Sopenharmony_ci#define IVTV_CARD_LAST		     27
448c2ecf20Sopenharmony_ci
458c2ecf20Sopenharmony_ci/* Variants of existing cards but with the same PCI IDs. The driver
468c2ecf20Sopenharmony_ci   detects these based on other device information.
478c2ecf20Sopenharmony_ci   These cards must always come last.
488c2ecf20Sopenharmony_ci   New cards must be inserted above, and the indices of the cards below
498c2ecf20Sopenharmony_ci   must be adjusted accordingly. */
508c2ecf20Sopenharmony_ci
518c2ecf20Sopenharmony_ci/* PVR-350 V1 (uses saa7114) */
528c2ecf20Sopenharmony_ci#define IVTV_CARD_PVR_350_V1	     (IVTV_CARD_LAST+1)
538c2ecf20Sopenharmony_ci/* 2 variants of Kuroutoshikou CX23416GYC-STVLP (Yuan MPG600GR OEM) */
548c2ecf20Sopenharmony_ci#define IVTV_CARD_CX23416GYC_NOGR    (IVTV_CARD_LAST+2)
558c2ecf20Sopenharmony_ci#define IVTV_CARD_CX23416GYC_NOGRYCS (IVTV_CARD_LAST+3)
568c2ecf20Sopenharmony_ci
578c2ecf20Sopenharmony_ci/* system vendor and device IDs */
588c2ecf20Sopenharmony_ci#define PCI_VENDOR_ID_ICOMP  0x4444
598c2ecf20Sopenharmony_ci#define PCI_DEVICE_ID_IVTV15 0x0803
608c2ecf20Sopenharmony_ci#define PCI_DEVICE_ID_IVTV16 0x0016
618c2ecf20Sopenharmony_ci
628c2ecf20Sopenharmony_ci/* subsystem vendor ID */
638c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_HAUPPAUGE		0x0070
648c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_HAUPPAUGE_ALT1	0x0270
658c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_HAUPPAUGE_ALT2	0x4070
668c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_ADAPTEC		0x9005
678c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_ASUSTEK		0x1043
688c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_AVERMEDIA		0x1461
698c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_YUAN1		0x12ab
708c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_YUAN2		0xff01
718c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_YUAN3		0xffab
728c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_YUAN4		0xfbab
738c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_DIAMONDMM		0xff92
748c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_IODATA		0x10fc
758c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_MELCO		0x1154
768c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_GOTVIEW1		0xffac
778c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_GOTVIEW2		0xffad
788c2ecf20Sopenharmony_ci#define IVTV_PCI_ID_SONY		0x104d
798c2ecf20Sopenharmony_ci
808c2ecf20Sopenharmony_ci/* hardware flags, no gaps allowed */
818c2ecf20Sopenharmony_ci#define IVTV_HW_CX25840			(1 << 0)
828c2ecf20Sopenharmony_ci#define IVTV_HW_SAA7115			(1 << 1)
838c2ecf20Sopenharmony_ci#define IVTV_HW_SAA7127			(1 << 2)
848c2ecf20Sopenharmony_ci#define IVTV_HW_MSP34XX			(1 << 3)
858c2ecf20Sopenharmony_ci#define IVTV_HW_TUNER			(1 << 4)
868c2ecf20Sopenharmony_ci#define IVTV_HW_WM8775			(1 << 5)
878c2ecf20Sopenharmony_ci#define IVTV_HW_CS53L32A		(1 << 6)
888c2ecf20Sopenharmony_ci#define IVTV_HW_TVEEPROM		(1 << 7)
898c2ecf20Sopenharmony_ci#define IVTV_HW_SAA7114			(1 << 8)
908c2ecf20Sopenharmony_ci#define IVTV_HW_UPD64031A		(1 << 9)
918c2ecf20Sopenharmony_ci#define IVTV_HW_UPD6408X		(1 << 10)
928c2ecf20Sopenharmony_ci#define IVTV_HW_SAA717X			(1 << 11)
938c2ecf20Sopenharmony_ci#define IVTV_HW_WM8739			(1 << 12)
948c2ecf20Sopenharmony_ci#define IVTV_HW_VP27SMPX		(1 << 13)
958c2ecf20Sopenharmony_ci#define IVTV_HW_M52790			(1 << 14)
968c2ecf20Sopenharmony_ci#define IVTV_HW_GPIO			(1 << 15)
978c2ecf20Sopenharmony_ci#define IVTV_HW_I2C_IR_RX_AVER		(1 << 16)
988c2ecf20Sopenharmony_ci#define IVTV_HW_I2C_IR_RX_HAUP_EXT	(1 << 17) /* External before internal */
998c2ecf20Sopenharmony_ci#define IVTV_HW_I2C_IR_RX_HAUP_INT	(1 << 18)
1008c2ecf20Sopenharmony_ci#define IVTV_HW_Z8F0811_IR_HAUP		(1 << 19)
1018c2ecf20Sopenharmony_ci#define IVTV_HW_I2C_IR_RX_ADAPTEC	(1 << 20)
1028c2ecf20Sopenharmony_ci
1038c2ecf20Sopenharmony_ci#define IVTV_HW_SAA711X   (IVTV_HW_SAA7115 | IVTV_HW_SAA7114)
1048c2ecf20Sopenharmony_ci
1058c2ecf20Sopenharmony_ci#define IVTV_HW_IR_ANY (IVTV_HW_I2C_IR_RX_AVER | \
1068c2ecf20Sopenharmony_ci			IVTV_HW_I2C_IR_RX_HAUP_EXT | \
1078c2ecf20Sopenharmony_ci			IVTV_HW_I2C_IR_RX_HAUP_INT | \
1088c2ecf20Sopenharmony_ci			IVTV_HW_Z8F0811_IR_HAUP | \
1098c2ecf20Sopenharmony_ci			IVTV_HW_I2C_IR_RX_ADAPTEC)
1108c2ecf20Sopenharmony_ci
1118c2ecf20Sopenharmony_ci/* video inputs */
1128c2ecf20Sopenharmony_ci#define	IVTV_CARD_INPUT_VID_TUNER	1
1138c2ecf20Sopenharmony_ci#define	IVTV_CARD_INPUT_SVIDEO1		2
1148c2ecf20Sopenharmony_ci#define	IVTV_CARD_INPUT_SVIDEO2		3
1158c2ecf20Sopenharmony_ci#define	IVTV_CARD_INPUT_COMPOSITE1	4
1168c2ecf20Sopenharmony_ci#define	IVTV_CARD_INPUT_COMPOSITE2	5
1178c2ecf20Sopenharmony_ci#define	IVTV_CARD_INPUT_COMPOSITE3	6
1188c2ecf20Sopenharmony_ci
1198c2ecf20Sopenharmony_ci/* audio inputs */
1208c2ecf20Sopenharmony_ci#define	IVTV_CARD_INPUT_AUD_TUNER	1
1218c2ecf20Sopenharmony_ci#define	IVTV_CARD_INPUT_LINE_IN1	2
1228c2ecf20Sopenharmony_ci#define	IVTV_CARD_INPUT_LINE_IN2	3
1238c2ecf20Sopenharmony_ci
1248c2ecf20Sopenharmony_ci#define IVTV_CARD_MAX_VIDEO_INPUTS 6
1258c2ecf20Sopenharmony_ci#define IVTV_CARD_MAX_AUDIO_INPUTS 3
1268c2ecf20Sopenharmony_ci#define IVTV_CARD_MAX_TUNERS	   3
1278c2ecf20Sopenharmony_ci
1288c2ecf20Sopenharmony_ci/* SAA71XX HW inputs */
1298c2ecf20Sopenharmony_ci#define IVTV_SAA71XX_COMPOSITE0 0
1308c2ecf20Sopenharmony_ci#define IVTV_SAA71XX_COMPOSITE1 1
1318c2ecf20Sopenharmony_ci#define IVTV_SAA71XX_COMPOSITE2 2
1328c2ecf20Sopenharmony_ci#define IVTV_SAA71XX_COMPOSITE3 3
1338c2ecf20Sopenharmony_ci#define IVTV_SAA71XX_COMPOSITE4 4
1348c2ecf20Sopenharmony_ci#define IVTV_SAA71XX_COMPOSITE5 5
1358c2ecf20Sopenharmony_ci#define IVTV_SAA71XX_SVIDEO0    6
1368c2ecf20Sopenharmony_ci#define IVTV_SAA71XX_SVIDEO1    7
1378c2ecf20Sopenharmony_ci#define IVTV_SAA71XX_SVIDEO2    8
1388c2ecf20Sopenharmony_ci#define IVTV_SAA71XX_SVIDEO3    9
1398c2ecf20Sopenharmony_ci
1408c2ecf20Sopenharmony_ci/* SAA717X needs to mark the tuner input by ORing with this flag */
1418c2ecf20Sopenharmony_ci#define IVTV_SAA717X_TUNER_FLAG 0x80
1428c2ecf20Sopenharmony_ci
1438c2ecf20Sopenharmony_ci/* Dummy HW input */
1448c2ecf20Sopenharmony_ci#define IVTV_DUMMY_AUDIO        0
1458c2ecf20Sopenharmony_ci
1468c2ecf20Sopenharmony_ci/* GPIO HW inputs */
1478c2ecf20Sopenharmony_ci#define IVTV_GPIO_TUNER   0
1488c2ecf20Sopenharmony_ci#define IVTV_GPIO_LINE_IN 1
1498c2ecf20Sopenharmony_ci
1508c2ecf20Sopenharmony_ci/* SAA717X HW inputs */
1518c2ecf20Sopenharmony_ci#define IVTV_SAA717X_IN0 0
1528c2ecf20Sopenharmony_ci#define IVTV_SAA717X_IN1 1
1538c2ecf20Sopenharmony_ci#define IVTV_SAA717X_IN2 2
1548c2ecf20Sopenharmony_ci
1558c2ecf20Sopenharmony_ci/* V4L2 capability aliases */
1568c2ecf20Sopenharmony_ci#define IVTV_CAP_ENCODER (V4L2_CAP_VIDEO_CAPTURE | V4L2_CAP_TUNER | \
1578c2ecf20Sopenharmony_ci			  V4L2_CAP_AUDIO | V4L2_CAP_READWRITE | V4L2_CAP_VBI_CAPTURE | \
1588c2ecf20Sopenharmony_ci			  V4L2_CAP_SLICED_VBI_CAPTURE)
1598c2ecf20Sopenharmony_ci#define IVTV_CAP_DECODER (V4L2_CAP_VIDEO_OUTPUT | V4L2_CAP_SLICED_VBI_OUTPUT)
1608c2ecf20Sopenharmony_ci
1618c2ecf20Sopenharmony_cistruct ivtv_card_video_input {
1628c2ecf20Sopenharmony_ci	u8  video_type;		/* video input type */
1638c2ecf20Sopenharmony_ci	u8  audio_index;	/* index in ivtv_card_audio_input array */
1648c2ecf20Sopenharmony_ci	u16 video_input;	/* hardware video input */
1658c2ecf20Sopenharmony_ci};
1668c2ecf20Sopenharmony_ci
1678c2ecf20Sopenharmony_cistruct ivtv_card_audio_input {
1688c2ecf20Sopenharmony_ci	u8  audio_type;		/* audio input type */
1698c2ecf20Sopenharmony_ci	u32 audio_input;	/* hardware audio input */
1708c2ecf20Sopenharmony_ci	u16 muxer_input;	/* hardware muxer input for boards with a
1718c2ecf20Sopenharmony_ci				   multiplexer chip */
1728c2ecf20Sopenharmony_ci};
1738c2ecf20Sopenharmony_ci
1748c2ecf20Sopenharmony_cistruct ivtv_card_output {
1758c2ecf20Sopenharmony_ci	u8  name[32];
1768c2ecf20Sopenharmony_ci	u16 video_output;  /* hardware video output */
1778c2ecf20Sopenharmony_ci};
1788c2ecf20Sopenharmony_ci
1798c2ecf20Sopenharmony_cistruct ivtv_card_pci_info {
1808c2ecf20Sopenharmony_ci	u16 device;
1818c2ecf20Sopenharmony_ci	u16 subsystem_vendor;
1828c2ecf20Sopenharmony_ci	u16 subsystem_device;
1838c2ecf20Sopenharmony_ci};
1848c2ecf20Sopenharmony_ci
1858c2ecf20Sopenharmony_ci/* GPIO definitions */
1868c2ecf20Sopenharmony_ci
1878c2ecf20Sopenharmony_ci/* The mask is the set of bits used by the operation */
1888c2ecf20Sopenharmony_ci
1898c2ecf20Sopenharmony_cistruct ivtv_gpio_init {		/* set initial GPIO DIR and OUT values */
1908c2ecf20Sopenharmony_ci	u16 direction;		/* DIR setting. Leave to 0 if no init is needed */
1918c2ecf20Sopenharmony_ci	u16 initial_value;
1928c2ecf20Sopenharmony_ci};
1938c2ecf20Sopenharmony_ci
1948c2ecf20Sopenharmony_cistruct ivtv_gpio_video_input {	/* select tuner/line in input */
1958c2ecf20Sopenharmony_ci	u16 mask;		/* leave to 0 if not supported */
1968c2ecf20Sopenharmony_ci	u16 tuner;
1978c2ecf20Sopenharmony_ci	u16 composite;
1988c2ecf20Sopenharmony_ci	u16 svideo;
1998c2ecf20Sopenharmony_ci};
2008c2ecf20Sopenharmony_ci
2018c2ecf20Sopenharmony_cistruct ivtv_gpio_audio_input {	/* select tuner/line in input */
2028c2ecf20Sopenharmony_ci	u16 mask;		/* leave to 0 if not supported */
2038c2ecf20Sopenharmony_ci	u16 tuner;
2048c2ecf20Sopenharmony_ci	u16 linein;
2058c2ecf20Sopenharmony_ci	u16 radio;
2068c2ecf20Sopenharmony_ci};
2078c2ecf20Sopenharmony_ci
2088c2ecf20Sopenharmony_cistruct ivtv_gpio_audio_mute {
2098c2ecf20Sopenharmony_ci	u16 mask;		/* leave to 0 if not supported */
2108c2ecf20Sopenharmony_ci	u16 mute;		/* set this value to mute, 0 to unmute */
2118c2ecf20Sopenharmony_ci};
2128c2ecf20Sopenharmony_ci
2138c2ecf20Sopenharmony_cistruct ivtv_gpio_audio_mode {
2148c2ecf20Sopenharmony_ci	u16 mask;		/* leave to 0 if not supported */
2158c2ecf20Sopenharmony_ci	u16 mono;		/* set audio to mono */
2168c2ecf20Sopenharmony_ci	u16 stereo;		/* set audio to stereo */
2178c2ecf20Sopenharmony_ci	u16 lang1;		/* set audio to the first language */
2188c2ecf20Sopenharmony_ci	u16 lang2;		/* set audio to the second language */
2198c2ecf20Sopenharmony_ci	u16 both;		/* both languages are output */
2208c2ecf20Sopenharmony_ci};
2218c2ecf20Sopenharmony_ci
2228c2ecf20Sopenharmony_cistruct ivtv_gpio_audio_freq {
2238c2ecf20Sopenharmony_ci	u16 mask;		/* leave to 0 if not supported */
2248c2ecf20Sopenharmony_ci	u16 f32000;
2258c2ecf20Sopenharmony_ci	u16 f44100;
2268c2ecf20Sopenharmony_ci	u16 f48000;
2278c2ecf20Sopenharmony_ci};
2288c2ecf20Sopenharmony_ci
2298c2ecf20Sopenharmony_cistruct ivtv_gpio_audio_detect {
2308c2ecf20Sopenharmony_ci	u16 mask;		/* leave to 0 if not supported */
2318c2ecf20Sopenharmony_ci	u16 stereo;		/* if the input matches this value then
2328c2ecf20Sopenharmony_ci				   stereo is detected */
2338c2ecf20Sopenharmony_ci};
2348c2ecf20Sopenharmony_ci
2358c2ecf20Sopenharmony_cistruct ivtv_card_tuner {
2368c2ecf20Sopenharmony_ci	v4l2_std_id std;	/* standard for which the tuner is suitable */
2378c2ecf20Sopenharmony_ci	int	    tuner;	/* tuner ID (from tuner.h) */
2388c2ecf20Sopenharmony_ci};
2398c2ecf20Sopenharmony_ci
2408c2ecf20Sopenharmony_cistruct ivtv_card_tuner_i2c {
2418c2ecf20Sopenharmony_ci	unsigned short radio[2];/* radio tuner i2c address to probe */
2428c2ecf20Sopenharmony_ci	unsigned short demod[2];/* demodulator i2c address to probe */
2438c2ecf20Sopenharmony_ci	unsigned short tv[4];	/* tv tuner i2c addresses to probe */
2448c2ecf20Sopenharmony_ci};
2458c2ecf20Sopenharmony_ci
2468c2ecf20Sopenharmony_ci/* for card information/parameters */
2478c2ecf20Sopenharmony_cistruct ivtv_card {
2488c2ecf20Sopenharmony_ci	int type;
2498c2ecf20Sopenharmony_ci	char *name;
2508c2ecf20Sopenharmony_ci	char *comment;
2518c2ecf20Sopenharmony_ci	u32 v4l2_capabilities;
2528c2ecf20Sopenharmony_ci	u32 hw_video;		/* hardware used to process video */
2538c2ecf20Sopenharmony_ci	u32 hw_audio;		/* hardware used to process audio */
2548c2ecf20Sopenharmony_ci	u32 hw_audio_ctrl;	/* hardware used for the V4L2 controls (only 1 dev allowed) */
2558c2ecf20Sopenharmony_ci	u32 hw_muxer;		/* hardware used to multiplex audio input */
2568c2ecf20Sopenharmony_ci	u32 hw_all;		/* all hardware used by the board */
2578c2ecf20Sopenharmony_ci	struct ivtv_card_video_input video_inputs[IVTV_CARD_MAX_VIDEO_INPUTS];
2588c2ecf20Sopenharmony_ci	struct ivtv_card_audio_input audio_inputs[IVTV_CARD_MAX_AUDIO_INPUTS];
2598c2ecf20Sopenharmony_ci	struct ivtv_card_audio_input radio_input;
2608c2ecf20Sopenharmony_ci	int nof_outputs;
2618c2ecf20Sopenharmony_ci	const struct ivtv_card_output *video_outputs;
2628c2ecf20Sopenharmony_ci	u8 gr_config;		/* config byte for the ghost reduction device */
2638c2ecf20Sopenharmony_ci	u8 xceive_pin;		/* XCeive tuner GPIO reset pin */
2648c2ecf20Sopenharmony_ci
2658c2ecf20Sopenharmony_ci	/* GPIO card-specific settings */
2668c2ecf20Sopenharmony_ci	struct ivtv_gpio_init		gpio_init;
2678c2ecf20Sopenharmony_ci	struct ivtv_gpio_video_input	gpio_video_input;
2688c2ecf20Sopenharmony_ci	struct ivtv_gpio_audio_input	gpio_audio_input;
2698c2ecf20Sopenharmony_ci	struct ivtv_gpio_audio_mute	gpio_audio_mute;
2708c2ecf20Sopenharmony_ci	struct ivtv_gpio_audio_mode	gpio_audio_mode;
2718c2ecf20Sopenharmony_ci	struct ivtv_gpio_audio_freq	gpio_audio_freq;
2728c2ecf20Sopenharmony_ci	struct ivtv_gpio_audio_detect	gpio_audio_detect;
2738c2ecf20Sopenharmony_ci
2748c2ecf20Sopenharmony_ci	struct ivtv_card_tuner tuners[IVTV_CARD_MAX_TUNERS];
2758c2ecf20Sopenharmony_ci	struct ivtv_card_tuner_i2c *i2c;
2768c2ecf20Sopenharmony_ci
2778c2ecf20Sopenharmony_ci	/* list of device and subsystem vendor/devices that
2788c2ecf20Sopenharmony_ci	   correspond to this card type. */
2798c2ecf20Sopenharmony_ci	const struct ivtv_card_pci_info *pci_list;
2808c2ecf20Sopenharmony_ci};
2818c2ecf20Sopenharmony_ci
2828c2ecf20Sopenharmony_ciint ivtv_get_input(struct ivtv *itv, u16 index, struct v4l2_input *input);
2838c2ecf20Sopenharmony_ciint ivtv_get_output(struct ivtv *itv, u16 index, struct v4l2_output *output);
2848c2ecf20Sopenharmony_ciint ivtv_get_audio_input(struct ivtv *itv, u16 index, struct v4l2_audio *input);
2858c2ecf20Sopenharmony_ciint ivtv_get_audio_output(struct ivtv *itv, u16 index, struct v4l2_audioout *output);
2868c2ecf20Sopenharmony_ciconst struct ivtv_card *ivtv_get_card(u16 index);
2878c2ecf20Sopenharmony_ci
2888c2ecf20Sopenharmony_ci#endif
289