linux/drivers/media/pci/ivtv/ivtv-cards.h

/* SPDX-License-Identifier: GPL-2.0-or-later */
/*
    Functions to query card hardware
    Copyright (C) 2003-2004  Kevin Thayer <nufan_wfk at yahoo.com>
    Copyright (C) 2005-2007  Hans Verkuil <[email protected]>

 */

#ifndef IVTV_CARDS_H
#define IVTV_CARDS_H

/* Supported cards */
#define IVTV_CARD_PVR_250
#define IVTV_CARD_PVR_350
#define IVTV_CARD_PVR_150
#define IVTV_CARD_M179
#define IVTV_CARD_MPG600
#define IVTV_CARD_MPG160
#define IVTV_CARD_PG600
#define IVTV_CARD_AVC2410
#define IVTV_CARD_AVC2010
#define IVTV_CARD_TG5000TV
#define IVTV_CARD_VA2000MAX_SNT6
#define IVTV_CARD_CX23416GYC
#define IVTV_CARD_GV_MVPRX
#define IVTV_CARD_GV_MVPRX2E
#define IVTV_CARD_GOTVIEW_PCI_DVD
#define IVTV_CARD_GOTVIEW_PCI_DVD2
#define IVTV_CARD_YUAN_MPC622
#define IVTV_CARD_DCTMTVP1
#define IVTV_CARD_PG600V2
#define IVTV_CARD_CLUB3D
#define IVTV_CARD_AVERTV_MCE116
#define IVTV_CARD_ASUS_FALCON2
#define IVTV_CARD_AVER_PVR150PLUS
#define IVTV_CARD_AVER_EZMAKER
#define IVTV_CARD_AVER_M104
#define IVTV_CARD_BUFFALO_MV5L
#define IVTV_CARD_AVER_ULTRA1500MCE
#define IVTV_CARD_KIKYOU
#define IVTV_CARD_LAST

/* Variants of existing cards but with the same PCI IDs. The driver
   detects these based on other device information.
   These cards must always come last.
   New cards must be inserted above, and the indices of the cards below
   must be adjusted accordingly. */

/* PVR-350 V1 (uses saa7114) */
#define IVTV_CARD_PVR_350_V1
/* 2 variants of Kuroutoshikou CX23416GYC-STVLP (Yuan MPG600GR OEM) */
#define IVTV_CARD_CX23416GYC_NOGR
#define IVTV_CARD_CX23416GYC_NOGRYCS

/* system vendor and device IDs */
#define PCI_VENDOR_ID_ICOMP
#define PCI_DEVICE_ID_IVTV15
#define PCI_DEVICE_ID_IVTV16

/* subsystem vendor ID */
#define IVTV_PCI_ID_HAUPPAUGE
#define IVTV_PCI_ID_HAUPPAUGE_ALT1
#define IVTV_PCI_ID_HAUPPAUGE_ALT2
#define IVTV_PCI_ID_ADAPTEC
#define IVTV_PCI_ID_ASUSTEK
#define IVTV_PCI_ID_AVERMEDIA
#define IVTV_PCI_ID_YUAN1
#define IVTV_PCI_ID_YUAN2
#define IVTV_PCI_ID_YUAN3
#define IVTV_PCI_ID_YUAN4
#define IVTV_PCI_ID_DIAMONDMM
#define IVTV_PCI_ID_IODATA
#define IVTV_PCI_ID_MELCO
#define IVTV_PCI_ID_GOTVIEW1
#define IVTV_PCI_ID_GOTVIEW2
#define IVTV_PCI_ID_SONY

/* hardware flags, no gaps allowed */
enum ivtv_hw_bits {};

#define IVTV_HW_CX25840
#define IVTV_HW_SAA7115
#define IVTV_HW_SAA7127
#define IVTV_HW_MSP34XX
#define IVTV_HW_TUNER
#define IVTV_HW_WM8775
#define IVTV_HW_CS53L32A
#define IVTV_HW_TVEEPROM
#define IVTV_HW_SAA7114
#define IVTV_HW_UPD64031A
#define IVTV_HW_UPD6408X
#define IVTV_HW_SAA717X
#define IVTV_HW_WM8739
#define IVTV_HW_VP27SMPX
#define IVTV_HW_M52790
#define IVTV_HW_GPIO
#define IVTV_HW_I2C_IR_RX_AVER
#define IVTV_HW_I2C_IR_RX_HAUP_EXT
#define IVTV_HW_I2C_IR_RX_HAUP_INT
#define IVTV_HW_Z8F0811_IR_HAUP
#define IVTV_HW_I2C_IR_RX_ADAPTEC

#define IVTV_HW_SAA711X

#define IVTV_HW_IR_ANY

/* video inputs */
#define IVTV_CARD_INPUT_VID_TUNER
#define IVTV_CARD_INPUT_SVIDEO1
#define IVTV_CARD_INPUT_SVIDEO2
#define IVTV_CARD_INPUT_COMPOSITE1
#define IVTV_CARD_INPUT_COMPOSITE2
#define IVTV_CARD_INPUT_COMPOSITE3

/* audio inputs */
#define IVTV_CARD_INPUT_AUD_TUNER
#define IVTV_CARD_INPUT_LINE_IN1
#define IVTV_CARD_INPUT_LINE_IN2

#define IVTV_CARD_MAX_VIDEO_INPUTS
#define IVTV_CARD_MAX_AUDIO_INPUTS
#define IVTV_CARD_MAX_TUNERS

/* SAA71XX HW inputs */
#define IVTV_SAA71XX_COMPOSITE0
#define IVTV_SAA71XX_COMPOSITE1
#define IVTV_SAA71XX_COMPOSITE2
#define IVTV_SAA71XX_COMPOSITE3
#define IVTV_SAA71XX_COMPOSITE4
#define IVTV_SAA71XX_COMPOSITE5
#define IVTV_SAA71XX_SVIDEO0
#define IVTV_SAA71XX_SVIDEO1
#define IVTV_SAA71XX_SVIDEO2
#define IVTV_SAA71XX_SVIDEO3

/* SAA717X needs to mark the tuner input by ORing with this flag */
#define IVTV_SAA717X_TUNER_FLAG

/* Dummy HW input */
#define IVTV_DUMMY_AUDIO

/* GPIO HW inputs */
#define IVTV_GPIO_TUNER
#define IVTV_GPIO_LINE_IN

/* SAA717X HW inputs */
#define IVTV_SAA717X_IN0
#define IVTV_SAA717X_IN1
#define IVTV_SAA717X_IN2

/* V4L2 capability aliases */
#define IVTV_CAP_ENCODER
#define IVTV_CAP_DECODER

struct ivtv_card_video_input {};

struct ivtv_card_audio_input {};

struct ivtv_card_output {};

struct ivtv_card_pci_info {};

/* GPIO definitions */

/* The mask is the set of bits used by the operation */

struct ivtv_gpio_init {};

struct ivtv_gpio_video_input {};

struct ivtv_gpio_audio_input {};

struct ivtv_gpio_audio_mute {};

struct ivtv_gpio_audio_mode {};

struct ivtv_gpio_audio_freq {};

struct ivtv_gpio_audio_detect {};

struct ivtv_card_tuner {};

struct ivtv_card_tuner_i2c {};

/* for card information/parameters */
struct ivtv_card {};

int ivtv_get_input(struct ivtv *itv, u16 index, struct v4l2_input *input);
int ivtv_get_output(struct ivtv *itv, u16 index, struct v4l2_output *output);
int ivtv_get_audio_input(struct ivtv *itv, u16 index, struct v4l2_audio *input);
int ivtv_get_audio_output(struct ivtv *itv, u16 index, struct v4l2_audioout *output);
const struct ivtv_card *ivtv_get_card(u16 index);

#endif