diff options
author | Mike Isely <isely@pobox.com> | 2006-03-28 21:54:25 -0600 |
---|---|---|
committer | Mike Isely <isely@pobox.com> | 2006-03-28 21:54:25 -0600 |
commit | 867f09ddc4c765a136402a0bd10a54ec45b7d820 (patch) | |
tree | 64fe137c2c3ac2eee361ae8f4b7b6814719d2b8c /linux/drivers | |
parent | da1de2e42e2a5c0290c15edbbd4017176ff0b1c2 (diff) | |
parent | fe57e9e343b68651e0666447d96d2db4fbb0a83d (diff) | |
download | mediapointer-dvb-s2-867f09ddc4c765a136402a0bd10a54ec45b7d820.tar.gz mediapointer-dvb-s2-867f09ddc4c765a136402a0bd10a54ec45b7d820.tar.bz2 |
Merge from master
From: Mike Isely <isely@pobox.com>
Signed-off-by: Mike Isely <isely@pobox.com>
Diffstat (limited to 'linux/drivers')
-rw-r--r-- | linux/drivers/media/Kconfig | 68 | ||||
-rw-r--r-- | linux/drivers/media/dvb/dvb-usb/cxusb.c | 54 | ||||
-rw-r--r-- | linux/drivers/media/video/Kconfig | 236 | ||||
-rw-r--r-- | linux/drivers/media/video/Makefile | 19 | ||||
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-alsa.c | 98 | ||||
-rw-r--r-- | linux/drivers/media/video/saa7134/Kconfig | 2 | ||||
-rw-r--r-- | linux/drivers/media/video/saa7134/saa7134-alsa.c | 120 | ||||
-rw-r--r-- | linux/drivers/media/video/saa7134/saa7134-cards.c | 66 | ||||
-rw-r--r-- | linux/drivers/media/video/saa7134/saa7134-dvb.c | 4 | ||||
-rw-r--r-- | linux/drivers/media/video/saa7134/saa7134.h | 7 | ||||
-rw-r--r-- | linux/drivers/media/video/tda9840.c | 5 | ||||
-rw-r--r-- | linux/drivers/media/video/tea6415c.c | 5 | ||||
-rw-r--r-- | linux/drivers/media/video/tea6420.c | 6 | ||||
-rw-r--r-- | linux/drivers/media/video/tvp5150.c | 8 | ||||
-rw-r--r-- | linux/drivers/media/video/video-buf.c | 12 |
15 files changed, 693 insertions, 17 deletions
diff --git a/linux/drivers/media/Kconfig b/linux/drivers/media/Kconfig new file mode 100644 index 000000000..fffc711c2 --- /dev/null +++ b/linux/drivers/media/Kconfig @@ -0,0 +1,68 @@ +# +# Multimedia device configuration +# + +menu "Multimedia devices" + +config VIDEO_DEV + tristate "Video For Linux" + ---help--- + Support for audio/video capture and overlay devices and FM radio + cards. The exact capabilities of each device vary. User tools for + this are available from + <ftp://ftp.uk.linux.org/pub/linux/video4linux/>. + + This kernel includes support for the new Video for Linux Two API, + (V4L2) as well as the original system. Drivers and applications + need to be rewritten to use V4L2, but drivers for popular cards + and applications for most video capture functions already exist. + + Documentation for the original API is included in the file + <file:Documentation/video4linux/API.html>. Documentation for V4L2 is + available on the web at <http://bytesex.org/v4l/>. + + To compile this driver as a module, choose M here: the + module will be called videodev. + +source "drivers/media/video/Kconfig" + +source "drivers/media/radio/Kconfig" + +source "drivers/media/dvb/Kconfig" + +source "drivers/media/common/Kconfig" + +config VIDEO_TUNER + tristate + +config VIDEO_BUF + tristate + +config VIDEO_BUF_DVB + tristate + +config VIDEO_BTCX + tristate + +config VIDEO_IR + tristate + +config VIDEO_TVEEPROM + tristate + +config USB_DABUSB + tristate "DABUSB driver" + depends on USB + ---help--- + A Digital Audio Broadcasting (DAB) Receiver for USB and Linux + brought to you by the DAB-Team + <http://wwwbode.cs.tum.edu/Par/arch/dab/>. This driver can be taken + as an example for URB-based bulk, control, and isochronous + transactions. URB's are explained in + <Documentation/usb/URB.txt>. + + To compile this driver as a module, choose M here: the + module will be called dabusb. + +endmenu + diff --git a/linux/drivers/media/dvb/dvb-usb/cxusb.c b/linux/drivers/media/dvb/dvb-usb/cxusb.c index f20b2bda4..d63f6ec4f 100644 --- a/linux/drivers/media/dvb/dvb-usb/cxusb.c +++ b/linux/drivers/media/dvb/dvb-usb/cxusb.c @@ -233,6 +233,45 @@ static struct dvb_usb_rc_key dvico_mce_rc_keys[] = { { 0xfe, 0x4e, KEY_POWER }, }; +static struct dvb_usb_rc_key dvico_portable_rc_keys[] = { + { 0xfc, 0x02, KEY_SETUP }, /* Profile */ + { 0xfc, 0x43, KEY_POWER2 }, + { 0xfc, 0x06, KEY_EPG }, + { 0xfc, 0x5a, KEY_BACK }, + { 0xfc, 0x05, KEY_MENU }, + { 0xfc, 0x47, KEY_INFO }, + { 0xfc, 0x01, KEY_TAB }, + { 0xfc, 0x42, KEY_PREVIOUSSONG },/* Replay */ + { 0xfc, 0x49, KEY_VOLUMEUP }, + { 0xfc, 0x09, KEY_VOLUMEDOWN }, + { 0xfc, 0x54, KEY_CHANNELUP }, + { 0xfc, 0x0b, KEY_CHANNELDOWN }, + { 0xfc, 0x16, KEY_CAMERA }, + { 0xfc, 0x40, KEY_TUNER }, /* ATV/DTV */ + { 0xfc, 0x45, KEY_OPEN }, + { 0xfc, 0x19, KEY_1 }, + { 0xfc, 0x18, KEY_2 }, + { 0xfc, 0x1b, KEY_3 }, + { 0xfc, 0x1a, KEY_4 }, + { 0xfc, 0x58, KEY_5 }, + { 0xfc, 0x59, KEY_6 }, + { 0xfc, 0x15, KEY_7 }, + { 0xfc, 0x14, KEY_8 }, + { 0xfc, 0x17, KEY_9 }, + { 0xfc, 0x44, KEY_ANGLE }, /* Aspect */ + { 0xfc, 0x55, KEY_0 }, + { 0xfc, 0x07, KEY_ZOOM }, + { 0xfc, 0x0a, KEY_REWIND }, + { 0xfc, 0x08, KEY_PLAYPAUSE }, + { 0xfc, 0x4b, KEY_FASTFORWARD }, + { 0xfc, 0x5b, KEY_MUTE }, + { 0xfc, 0x04, KEY_STOP }, + { 0xfc, 0x56, KEY_RECORD }, + { 0xfc, 0x57, KEY_POWER }, + { 0xfc, 0x41, KEY_UNKNOWN }, /* INPUT */ + { 0xfc, 0x00, KEY_UNKNOWN }, /* HD */ +}; + static int cxusb_dee1601_demod_init(struct dvb_frontend* fe) { static u8 clock_config [] = { CLOCK_CTL, 0x38, 0x28 }; @@ -511,6 +550,11 @@ static struct dvb_usb_properties cxusb_bluebird_lgh064f_properties = { .i2c_algo = &cxusb_i2c_algo, + .rc_interval = 100, + .rc_key_map = dvico_portable_rc_keys, + .rc_key_map_size = ARRAY_SIZE(dvico_portable_rc_keys), + .rc_query = cxusb_rc_query, + .generic_bulk_ctrl_endpoint = 0x01, /* parameter for the MPEG2-data transfer */ .urb = { @@ -600,6 +644,11 @@ static struct dvb_usb_properties cxusb_bluebird_lgz201_properties = { .i2c_algo = &cxusb_i2c_algo, + .rc_interval = 100, + .rc_key_map = dvico_portable_rc_keys, + .rc_key_map_size = ARRAY_SIZE(dvico_portable_rc_keys), + .rc_query = cxusb_rc_query, + .generic_bulk_ctrl_endpoint = 0x01, /* parameter for the MPEG2-data transfer */ .urb = { @@ -640,6 +689,11 @@ static struct dvb_usb_properties cxusb_bluebird_dtt7579_properties = { .i2c_algo = &cxusb_i2c_algo, + .rc_interval = 100, + .rc_key_map = dvico_portable_rc_keys, + .rc_key_map_size = ARRAY_SIZE(dvico_portable_rc_keys), + .rc_query = cxusb_rc_query, + .generic_bulk_ctrl_endpoint = 0x01, /* parameter for the MPEG2-data transfer */ .urb = { diff --git a/linux/drivers/media/video/Kconfig b/linux/drivers/media/video/Kconfig index 762e35670..62e71b527 100644 --- a/linux/drivers/media/video/Kconfig +++ b/linux/drivers/media/video/Kconfig @@ -291,10 +291,6 @@ config VIDEO_HEXIUM_GEMINI source "drivers/media/video/cx88/Kconfig" -source "drivers/media/video/em28xx/Kconfig" - -source "drivers/media/video/pvrusb2/Kconfig" - config VIDEO_OVCAMCHIP tristate "OmniVision Camera Chip support" depends on VIDEO_DEV && I2C @@ -369,4 +365,236 @@ config VIDEO_SAA7127 To compile this driver as a module, choose M here: the module will be called saa7127 +# +# USB Multimedia device configuration +# + +menu "V4L USB devices" + depends on USB && VIDEO_DEV + +source "drivers/media/video/pvrusb2/Kconfig" + +source "drivers/media/video/em28xx/Kconfig" + +config USB_VICAM + tristate "USB 3com HomeConnect (aka vicam) support (EXPERIMENTAL)" + depends on USB && VIDEO_DEV && EXPERIMENTAL + ---help--- + Say Y here if you have 3com homeconnect camera (vicam). + + This driver uses the Video For Linux API. You must say Y or M to + "Video For Linux" (under Multimedia Devices) to use this driver. + Information on this API and pointers to "v4l" programs may be found + at <file:Documentation/video4linux/API.html>. + + To compile this driver as a module, choose M here: the + module will be called vicam. + +config USB_DSBR + tristate "D-Link USB FM radio support (EXPERIMENTAL)" + depends on USB && VIDEO_DEV && EXPERIMENTAL + ---help--- + Say Y here if you want to connect this type of radio to your + computer's USB port. Note that the audio is not digital, and + you must connect the line out connector to a sound card or a + set of speakers. + + This driver uses the Video For Linux API. You must enable + (Y or M in config) Video For Linux (under Character Devices) + to use this driver. Information on this API and pointers to + "v4l" programs may be found at + <file:Documentation/video4linux/API.html>. + + To compile this driver as a module, choose M here: the + module will be called dsbr100. + +config USB_ET61X251 + tristate "USB ET61X[12]51 PC Camera Controller support" + depends on USB && VIDEO_DEV + ---help--- + Say Y here if you want support for cameras based on Etoms ET61X151 + or ET61X251 PC Camera Controllers. + + See <file:Documentation/usb/et61x251.txt> for more informations. + + This driver uses the Video For Linux API. You must say Y or M to + "Video For Linux" to use this driver. + + To compile this driver as a module, choose M here: the + module will be called et61x251. + +config USB_IBMCAM + tristate "USB IBM (Xirlink) C-it Camera support" + depends on USB && VIDEO_DEV + ---help--- + Say Y here if you want to connect a IBM "C-It" camera, also known as + "Xirlink PC Camera" to your computer's USB port. For more + information, read <file:Documentation/usb/ibmcam.txt>. + + This driver uses the Video For Linux API. You must enable + (Y or M in config) Video For Linux (under Character Devices) + to use this driver. Information on this API and pointers to + "v4l" programs may be found at + <file:Documentation/video4linux/API.html>. + + To compile this driver as a module, choose M here: the + module will be called ibmcam. + + This camera has several configuration options which + can be specified when you load the module. Read + <file:Documentation/usb/ibmcam.txt> to learn more. + +config USB_KONICAWC + tristate "USB Konica Webcam support" + depends on USB && VIDEO_DEV + ---help--- + Say Y here if you want support for webcams based on a Konica + chipset. This is known to work with the Intel YC76 webcam. + + This driver uses the Video For Linux API. You must enable + (Y or M in config) Video For Linux (under Character Devices) + to use this driver. Information on this API and pointers to + "v4l" programs may be found at + <file:Documentation/video4linux/API.html>. + + To compile this driver as a module, choose M here: the + module will be called konicawc. + +config USB_OV511 + tristate "USB OV511 Camera support" + depends on USB && VIDEO_DEV + ---help--- + Say Y here if you want to connect this type of camera to your + computer's USB port. See <file:Documentation/usb/ov511.txt> for more + information and for a list of supported cameras. + + This driver uses the Video For Linux API. You must say Y or M to + "Video For Linux" (under Character Devices) to use this driver. + Information on this API and pointers to "v4l" programs may be found + at <file:Documentation/video4linux/API.html>. + + To compile this driver as a module, choose M here: the + module will be called ov511. + +config USB_SE401 + tristate "USB SE401 Camera support" + depends on USB && VIDEO_DEV + ---help--- + Say Y here if you want to connect this type of camera to your + computer's USB port. See <file:Documentation/usb/se401.txt> for more + information and for a list of supported cameras. + + This driver uses the Video For Linux API. You must say Y or M to + "Video For Linux" (under Multimedia Devices) to use this driver. + Information on this API and pointers to "v4l" programs may be found + at <file:Documentation/video4linux/API.html>. + + To compile this driver as a module, choose M here: the + module will be called se401. + +config USB_SN9C102 + tristate "USB SN9C10x PC Camera Controller support" + depends on USB && VIDEO_DEV + ---help--- + Say Y here if you want support for cameras based on SONiX SN9C101, + SN9C102 or SN9C103 PC Camera Controllers. + + See <file:Documentation/usb/sn9c102.txt> for more informations. + + This driver uses the Video For Linux API. You must say Y or M to + "Video For Linux" to use this driver. + + To compile this driver as a module, choose M here: the + module will be called sn9c102. + +config USB_STV680 + tristate "USB STV680 (Pencam) Camera support" + depends on USB && VIDEO_DEV + ---help--- + Say Y here if you want to connect this type of camera to your + computer's USB port. This includes the Pencam line of cameras. + See <file:Documentation/usb/stv680.txt> for more information and for + a list of supported cameras. + + This driver uses the Video For Linux API. You must say Y or M to + "Video For Linux" (under Multimedia Devices) to use this driver. + Information on this API and pointers to "v4l" programs may be found + at <file:Documentation/video4linux/API.html>. + + To compile this driver as a module, choose M here: the + module will be called stv680. + +config USB_W9968CF + tristate "USB W996[87]CF JPEG Dual Mode Camera support" + depends on USB && VIDEO_DEV && I2C && VIDEO_OVCAMCHIP + ---help--- + Say Y here if you want support for cameras based on OV681 or + Winbond W9967CF/W9968CF JPEG USB Dual Mode Camera Chips. + + This driver has an optional plugin, which is distributed as a + separate module only (released under GPL). It allows to use higher + resolutions and framerates, but cannot be included in the official + Linux kernel for performance purposes. + + See <file:Documentation/usb/w9968cf.txt> for more informations. + + This driver uses the Video For Linux and the I2C APIs. It needs the + OmniVision Camera Chip support as well. You must say Y or M to + "Video For Linux", "I2C Support" and "OmniVision Camera Chip + support" to use this driver. + + To compile this driver as a module, choose M here: the + module will be called w9968cf. + +config USB_ZC0301 + tristate "USB ZC0301 Image Processor and Control Chip support" + depends on USB && VIDEO_DEV + ---help--- + Say Y here if you want support for cameras based on the ZC0301 + Image Processor and Control Chip. + + See <file:Documentation/usb/zc0301.txt> for more informations. + + This driver uses the Video For Linux API. You must say Y or M to + "Video For Linux" to use this driver. + + To compile this driver as a module, choose M here: the + module will be called zc0301. + +config USB_PWC + tristate "USB Philips Cameras" + depends on USB && VIDEO_DEV + ---help--- + Say Y or M here if you want to use one of these Philips & OEM + webcams: + * Philips PCA645, PCA646 + * Philips PCVC675, PCVC680, PCVC690 + * Philips PCVC720/40, PCVC730, PCVC740, PCVC750 + * Askey VC010 + * Logitech QuickCam Pro 3000, 4000, 'Zoom', 'Notebook Pro' + and 'Orbit'/'Sphere' + * Samsung MPC-C10, MPC-C30 + * Creative Webcam 5, Pro Ex + * SOTEC Afina Eye + * Visionite VCS-UC300, VCS-UM100 + + The PCA635, PCVC665 and PCVC720/20 are not supported by this driver + and never will be, but the 665 and 720/20 are supported by other + drivers. + + See <file:Documentation/usb/philips.txt> for more information and + installation instructions. + + The built-in microphone is enabled by selecting USB Audio support. + + This driver uses the Video For Linux API. You must say Y or M to + "Video For Linux" (under Character Devices) to use this driver. + Information on this API and pointers to "v4l" programs may be found + at <file:Documentation/video4linux/API.html>. + + To compile this driver as a module, choose M here: the + module will be called pwc. + +endmenu # V4L USB devices + endmenu diff --git a/linux/drivers/media/video/Makefile b/linux/drivers/media/video/Makefile index 27e7b37b1..289ef1abf 100644 --- a/linux/drivers/media/video/Makefile +++ b/linux/drivers/media/video/Makefile @@ -66,4 +66,23 @@ obj-$(CONFIG_VIDEO_CX25840) += cx25840/ obj-$(CONFIG_VIDEO_SAA711X) += saa7115.o obj-$(CONFIG_VIDEO_SAA7127) += saa7127.o +et61x251-objs := et61x251_core.o et61x251_tas5130d1b.o +zc0301-objs := zc0301_core.o zc0301_pas202bcb.o + +obj-$(CONFIG_USB_DABUSB) += dabusb.o +obj-$(CONFIG_USB_DSBR) += dsbr100.o +obj-$(CONFIG_USB_OV511) += ov511.o +obj-$(CONFIG_USB_SE401) += se401.o +obj-$(CONFIG_USB_STV680) += stv680.o +obj-$(CONFIG_USB_W9968CF) += w9968cf.o + +obj-$(CONFIG_USB_SN9C102) += sn9c102/ +obj-$(CONFIG_USB_ET61X251) += et61x251/ +obj-$(CONFIG_USB_PWC) += pwc/ +obj-$(CONFIG_USB_ZC0301) += zc0301/ + +obj-$(CONFIG_USB_IBMCAM) += usbvideo/ +obj-$(CONFIG_USB_KONICAWC) += usbvideo/ +obj-$(CONFIG_USB_VICAM) += usbvideo/ + EXTRA_CFLAGS += -I$(srctree)/drivers/media/dvb/dvb-core diff --git a/linux/drivers/media/video/cx88/cx88-alsa.c b/linux/drivers/media/video/cx88/cx88-alsa.c index 8ecdb41af..80aef2421 100644 --- a/linux/drivers/media/video/cx88/cx88-alsa.c +++ b/linux/drivers/media/video/cx88/cx88-alsa.c @@ -65,7 +65,11 @@ struct cx88_audio_dev { /* audio controls */ int irq; +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_card_t *card; +#else + struct snd_card *card; +#endif spinlock_t reg_lock; @@ -84,7 +88,11 @@ struct cx88_audio_dev { struct cx88_buffer *buf; long opened; +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_pcm_substream_t *substream; +#else + struct snd_pcm_substream *substream; +#endif }; typedef struct cx88_audio_dev snd_cx88_card_t; @@ -101,7 +109,11 @@ typedef struct cx88_audio_dev snd_cx88_card_t; static int index[SNDRV_CARDS] = SNDRV_DEFAULT_IDX; /* Index 0-MAX */ static char *id[SNDRV_CARDS] = SNDRV_DEFAULT_STR; /* ID for this card */ static int enable[SNDRV_CARDS] = {1, [1 ... (SNDRV_CARDS - 1)] = 1}; +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static snd_card_t *snd_cx88_cards[SNDRV_CARDS]; +#else +static struct snd_card *snd_cx88_cards[SNDRV_CARDS]; +#endif #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,10) static unsigned int dummy; @@ -334,7 +346,11 @@ static int dsp_buffer_free(snd_cx88_card_t *chip) /* * Digital hardware definition */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static snd_pcm_hardware_t snd_cx88_digital_hw = { +#else +static struct snd_pcm_hardware snd_cx88_digital_hw = { +#endif .info = SNDRV_PCM_INFO_MMAP | SNDRV_PCM_INFO_INTERLEAVED | SNDRV_PCM_INFO_BLOCK_TRANSFER | @@ -356,16 +372,28 @@ static snd_pcm_hardware_t snd_cx88_digital_hw = { /* * audio pcm capture runtime free */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static void snd_card_cx88_runtime_free(snd_pcm_runtime_t *runtime) +#else +static void snd_card_cx88_runtime_free(struct snd_pcm_runtime *runtime) +#endif { } /* * audio pcm capture open callback */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_cx88_pcm_open(snd_pcm_substream_t *substream) +#else +static int snd_cx88_pcm_open(struct snd_pcm_substream *substream) +#endif { snd_cx88_card_t *chip = snd_pcm_substream_chip(substream); +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_pcm_runtime_t *runtime = substream->runtime; +#else + struct snd_pcm_runtime *runtime = substream->runtime; +#endif int err; if (test_and_set_bit(0, &chip->opened)) @@ -394,7 +422,11 @@ _error: /* * audio close callback */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_cx88_close(snd_pcm_substream_t *substream) +#else +static int snd_cx88_close(struct snd_pcm_substream *substream) +#endif { snd_cx88_card_t *chip = snd_pcm_substream_chip(substream); @@ -407,8 +439,13 @@ static int snd_cx88_close(snd_pcm_substream_t *substream) /* * hw_params callback */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_cx88_hw_params(snd_pcm_substream_t * substream, snd_pcm_hw_params_t * hw_params) +#else +static int snd_cx88_hw_params(struct snd_pcm_substream * substream, + struct snd_pcm_hw_params * hw_params) +#endif { snd_cx88_card_t *chip = snd_pcm_substream_chip(substream); struct cx88_buffer *buf; @@ -467,7 +504,11 @@ static int snd_cx88_hw_params(snd_pcm_substream_t * substream, /* * hw free callback */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_cx88_hw_free(snd_pcm_substream_t * substream) +#else +static int snd_cx88_hw_free(struct snd_pcm_substream * substream) +#endif { snd_cx88_card_t *chip = snd_pcm_substream_chip(substream); @@ -483,7 +524,11 @@ static int snd_cx88_hw_free(snd_pcm_substream_t * substream) /* * prepare callback */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_cx88_prepare(snd_pcm_substream_t *substream) +#else +static int snd_cx88_prepare(struct snd_pcm_substream *substream) +#endif { return 0; } @@ -492,7 +537,11 @@ static int snd_cx88_prepare(snd_pcm_substream_t *substream) /* * trigger callback */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_cx88_card_trigger(snd_pcm_substream_t *substream, int cmd) +#else +static int snd_cx88_card_trigger(struct snd_pcm_substream *substream, int cmd) +#endif { snd_cx88_card_t *chip = snd_pcm_substream_chip(substream); int err; @@ -519,10 +568,18 @@ static int snd_cx88_card_trigger(snd_pcm_substream_t *substream, int cmd) /* * pointer callback */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static snd_pcm_uframes_t snd_cx88_pointer(snd_pcm_substream_t *substream) +#else +static snd_pcm_uframes_t snd_cx88_pointer(struct snd_pcm_substream *substream) +#endif { snd_cx88_card_t *chip = snd_pcm_substream_chip(substream); +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_pcm_runtime_t *runtime = substream->runtime; +#else + struct snd_pcm_runtime *runtime = substream->runtime; +#endif if (chip->read_count) { chip->read_count -= snd_pcm_lib_period_bytes(substream); @@ -539,7 +596,11 @@ static snd_pcm_uframes_t snd_cx88_pointer(snd_pcm_substream_t *substream) /* * operators */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static snd_pcm_ops_t snd_cx88_pcm_ops = { +#else +static struct snd_pcm_ops snd_cx88_pcm_ops = { +#endif .open = snd_cx88_pcm_open, .close = snd_cx88_close, .ioctl = snd_pcm_lib_ioctl, @@ -556,7 +617,11 @@ static snd_pcm_ops_t snd_cx88_pcm_ops = { static int __devinit snd_cx88_pcm(snd_cx88_card_t *chip, int device, char *name) { int err; +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_pcm_t *pcm; +#else + struct snd_pcm *pcm; +#endif err = snd_pcm_new(chip->card, name, device, 0, 1, &pcm); if (err < 0) @@ -571,7 +636,12 @@ static int __devinit snd_cx88_pcm(snd_cx88_card_t *chip, int device, char *name) /**************************************************************************** CONTROL INTERFACE ****************************************************************************/ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_cx88_capture_volume_info(snd_kcontrol_t *kcontrol, snd_ctl_elem_info_t *info) +#else +static int snd_cx88_capture_volume_info(struct snd_kcontrol *kcontrol, + struct snd_ctl_elem_info *info) +#endif { info->type = SNDRV_CTL_ELEM_TYPE_INTEGER; info->count = 1; @@ -582,7 +652,12 @@ static int snd_cx88_capture_volume_info(snd_kcontrol_t *kcontrol, snd_ctl_elem_i } /* OK - TODO: test it */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_cx88_capture_volume_get(snd_kcontrol_t *kcontrol, snd_ctl_elem_value_t *value) +#else +static int snd_cx88_capture_volume_get(struct snd_kcontrol *kcontrol, + struct snd_ctl_elem_value *value) +#endif { snd_cx88_card_t *chip = snd_kcontrol_chip(kcontrol); struct cx88_core *core=chip->core; @@ -593,7 +668,12 @@ static int snd_cx88_capture_volume_get(snd_kcontrol_t *kcontrol, snd_ctl_elem_va } /* OK - TODO: test it */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_cx88_capture_volume_put(snd_kcontrol_t *kcontrol, snd_ctl_elem_value_t *value) +#else +static int snd_cx88_capture_volume_put(struct snd_kcontrol *kcontrol, + struct snd_ctl_elem_value *value) +#endif { snd_cx88_card_t *chip = snd_kcontrol_chip(kcontrol); struct cx88_core *core=chip->core; @@ -609,7 +689,11 @@ static int snd_cx88_capture_volume_put(snd_kcontrol_t *kcontrol, snd_ctl_elem_va return v != old_control; } +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static snd_kcontrol_new_t snd_cx88_capture_volume = { +#else +static struct snd_kcontrol_new snd_cx88_capture_volume = { +#endif .iface = SNDRV_CTL_ELEM_IFACE_MIXER, .name = "Capture Volume", .info = snd_cx88_capture_volume_info, @@ -655,7 +739,11 @@ static int snd_cx88_free(snd_cx88_card_t *chip) /* * Component Destructor */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static void snd_cx88_dev_free(snd_card_t * card) +#else +static void snd_cx88_dev_free(struct snd_card * card) +#endif { snd_cx88_card_t *chip = card->private_data; @@ -668,8 +756,14 @@ static void snd_cx88_dev_free(snd_card_t * card) */ static int devno; +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int __devinit snd_cx88_create(snd_card_t *card, struct pci_dev *pci, snd_cx88_card_t **rchip) +#else +static int __devinit snd_cx88_create(struct snd_card *card, + struct pci_dev *pci, + snd_cx88_card_t **rchip) +#endif { snd_cx88_card_t *chip; struct cx88_core *core; @@ -740,7 +834,11 @@ static int __devinit snd_cx88_create(snd_card_t *card, struct pci_dev *pci, static int __devinit cx88_audio_initdev(struct pci_dev *pci, const struct pci_device_id *pci_id) { +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_card_t *card; +#else + struct snd_card *card; +#endif snd_cx88_card_t *chip; int err; diff --git a/linux/drivers/media/video/saa7134/Kconfig b/linux/drivers/media/video/saa7134/Kconfig index 263498660..e1c1805df 100644 --- a/linux/drivers/media/video/saa7134/Kconfig +++ b/linux/drivers/media/video/saa7134/Kconfig @@ -5,7 +5,6 @@ config VIDEO_SAA7134 select VIDEO_IR select VIDEO_TUNER select CRC32 - select FW_LOADER ---help--- This is a video4linux driver for Philips SAA713x based TV cards. @@ -40,6 +39,7 @@ config VIDEO_SAA7134_DVB tristate "DVB/ATSC Support for saa7134 based TV cards" depends on VIDEO_SAA7134 && DVB_CORE select VIDEO_BUF_DVB + select FW_LOADER ---help--- This adds support for DVB cards based on the Philips saa7134 chip. diff --git a/linux/drivers/media/video/saa7134/saa7134-alsa.c b/linux/drivers/media/video/saa7134/saa7134-alsa.c index 393a3a3bd..54fc877ba 100644 --- a/linux/drivers/media/video/saa7134/saa7134-alsa.c +++ b/linux/drivers/media/video/saa7134/saa7134-alsa.c @@ -80,7 +80,11 @@ MODULE_PARM_DESC(enable, "Enable (or not) the SAA7134 capture interface(s)."); */ typedef struct snd_card_saa7134 { +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_card_t *card; +#else + struct snd_card *card; +#endif spinlock_t mixer_lock; int mixer_volume[MIXER_ADDR_LAST+1][2]; int capture_source[MIXER_ADDR_LAST+1][2]; @@ -107,10 +111,18 @@ typedef struct snd_card_saa7134_pcm { spinlock_t lock; +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_pcm_substream_t *substream; +#else + struct snd_pcm_substream *substream; +#endif } snd_card_saa7134_pcm_t; +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static snd_card_t *snd_saa7134_cards[SNDRV_CARDS]; +#else +static struct snd_card *snd_saa7134_cards[SNDRV_CARDS]; +#endif /* @@ -263,10 +275,18 @@ out: * */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_card_saa7134_capture_trigger(snd_pcm_substream_t * substream, +#else +static int snd_card_saa7134_capture_trigger(struct snd_pcm_substream * substream, +#endif int cmd) { +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_pcm_runtime_t *runtime = substream->runtime; +#else + struct snd_pcm_runtime *runtime = substream->runtime; +#endif snd_card_saa7134_pcm_t *pcm = runtime->private_data; struct saa7134_dev *dev=pcm->dev; int err = 0; @@ -344,9 +364,17 @@ static int dsp_buffer_free(struct saa7134_dev *dev) * */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_card_saa7134_capture_prepare(snd_pcm_substream_t * substream) +#else +static int snd_card_saa7134_capture_prepare(struct snd_pcm_substream * substream) +#endif { +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_pcm_runtime_t *runtime = substream->runtime; +#else + struct snd_pcm_runtime *runtime = substream->runtime; +#endif int bswap, sign; u32 fmt, control; snd_card_saa7134_t *saa7134 = snd_pcm_substream_chip(substream); @@ -433,9 +461,18 @@ static int snd_card_saa7134_capture_prepare(snd_pcm_substream_t * substream) * */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static snd_pcm_uframes_t snd_card_saa7134_capture_pointer(snd_pcm_substream_t * substream) +#else +static snd_pcm_uframes_t +snd_card_saa7134_capture_pointer(struct snd_pcm_substream * substream) +#endif { +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_pcm_runtime_t *runtime = substream->runtime; +#else + struct snd_pcm_runtime *runtime = substream->runtime; +#endif snd_card_saa7134_pcm_t *pcm = runtime->private_data; struct saa7134_dev *dev=pcm->dev; @@ -453,7 +490,11 @@ static snd_pcm_uframes_t snd_card_saa7134_capture_pointer(snd_pcm_substream_t * * ALSA hardware capabilities definition */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static snd_pcm_hardware_t snd_card_saa7134_capture = +#else +static struct snd_pcm_hardware snd_card_saa7134_capture = +#endif { .info = (SNDRV_PCM_INFO_MMAP | SNDRV_PCM_INFO_INTERLEAVED | SNDRV_PCM_INFO_BLOCK_TRANSFER | @@ -476,7 +517,11 @@ static snd_pcm_hardware_t snd_card_saa7134_capture = .periods_max = 1024, }; +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static void snd_card_saa7134_runtime_free(snd_pcm_runtime_t *runtime) +#else +static void snd_card_saa7134_runtime_free(struct snd_pcm_runtime *runtime) +#endif { snd_card_saa7134_pcm_t *pcm = runtime->private_data; @@ -493,8 +538,13 @@ static void snd_card_saa7134_runtime_free(snd_pcm_runtime_t *runtime) * */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_card_saa7134_hw_params(snd_pcm_substream_t * substream, snd_pcm_hw_params_t * hw_params) +#else +static int snd_card_saa7134_hw_params(struct snd_pcm_substream * substream, + struct snd_pcm_hw_params * hw_params) +#endif { snd_card_saa7134_t *saa7134 = snd_pcm_substream_chip(substream); struct saa7134_dev *dev; @@ -573,7 +623,11 @@ static int snd_card_saa7134_hw_params(snd_pcm_substream_t * substream, * */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_card_saa7134_hw_free(snd_pcm_substream_t * substream) +#else +static int snd_card_saa7134_hw_free(struct snd_pcm_substream * substream) +#endif { snd_card_saa7134_t *saa7134 = snd_pcm_substream_chip(substream); struct saa7134_dev *dev; @@ -599,7 +653,11 @@ static int snd_card_saa7134_hw_free(snd_pcm_substream_t * substream) * */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_card_saa7134_capture_close(snd_pcm_substream_t * substream) +#else +static int snd_card_saa7134_capture_close(struct snd_pcm_substream * substream) +#endif { return 0; } @@ -614,9 +672,17 @@ static int snd_card_saa7134_capture_close(snd_pcm_substream_t * substream) * */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_card_saa7134_capture_open(snd_pcm_substream_t * substream) +#else +static int snd_card_saa7134_capture_open(struct snd_pcm_substream * substream) +#endif { +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_pcm_runtime_t *runtime = substream->runtime; +#else + struct snd_pcm_runtime *runtime = substream->runtime; +#endif snd_card_saa7134_pcm_t *pcm; snd_card_saa7134_t *saa7134 = snd_pcm_substream_chip(substream); struct saa7134_dev *dev = saa7134->dev; @@ -652,7 +718,11 @@ static int snd_card_saa7134_capture_open(snd_pcm_substream_t * substream) * ALSA capture callbacks definition */ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static snd_pcm_ops_t snd_card_saa7134_capture_ops = { +#else +static struct snd_pcm_ops snd_card_saa7134_capture_ops = { +#endif .open = snd_card_saa7134_capture_open, .close = snd_card_saa7134_capture_close, .ioctl = snd_pcm_lib_ioctl, @@ -673,7 +743,11 @@ static snd_pcm_ops_t snd_card_saa7134_capture_ops = { static int snd_card_saa7134_pcm(snd_card_saa7134_t *saa7134, int device) { +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_pcm_t *pcm; +#else + struct snd_pcm *pcm; +#endif int err; if ((err = snd_pcm_new(saa7134->card, "SAA7134 PCM", device, 0, 1, &pcm)) < 0) @@ -691,7 +765,12 @@ static int snd_card_saa7134_pcm(snd_card_saa7134_t *saa7134, int device) .get = snd_saa7134_volume_get, .put = snd_saa7134_volume_put, \ .private_value = addr } +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_saa7134_volume_info(snd_kcontrol_t * kcontrol, snd_ctl_elem_info_t * uinfo) +#else +static int snd_saa7134_volume_info(struct snd_kcontrol * kcontrol, + struct snd_ctl_elem_info * uinfo) +#endif { uinfo->type = SNDRV_CTL_ELEM_TYPE_INTEGER; uinfo->count = 2; @@ -700,7 +779,12 @@ static int snd_saa7134_volume_info(snd_kcontrol_t * kcontrol, snd_ctl_elem_info_ return 0; } +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_saa7134_volume_get(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) +#else +static int snd_saa7134_volume_get(struct snd_kcontrol * kcontrol, + struct snd_ctl_elem_value * ucontrol) +#endif { snd_card_saa7134_t *chip = snd_kcontrol_chip(kcontrol); int addr = kcontrol->private_value; @@ -710,7 +794,12 @@ static int snd_saa7134_volume_get(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_ return 0; } +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_saa7134_volume_put(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) +#else +static int snd_saa7134_volume_put(struct snd_kcontrol * kcontrol, + struct snd_ctl_elem_value * ucontrol) +#endif { snd_card_saa7134_t *chip = snd_kcontrol_chip(kcontrol); int change, addr = kcontrol->private_value; @@ -741,7 +830,12 @@ static int snd_saa7134_volume_put(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_ .get = snd_saa7134_capsrc_get, .put = snd_saa7134_capsrc_put, \ .private_value = addr } +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_saa7134_capsrc_info(snd_kcontrol_t * kcontrol, snd_ctl_elem_info_t * uinfo) +#else +static int snd_saa7134_capsrc_info(struct snd_kcontrol * kcontrol, + struct snd_ctl_elem_info * uinfo) +#endif { uinfo->type = SNDRV_CTL_ELEM_TYPE_BOOLEAN; uinfo->count = 2; @@ -750,7 +844,12 @@ static int snd_saa7134_capsrc_info(snd_kcontrol_t * kcontrol, snd_ctl_elem_info_ return 0; } +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_saa7134_capsrc_get(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) +#else +static int snd_saa7134_capsrc_get(struct snd_kcontrol * kcontrol, + struct snd_ctl_elem_value * ucontrol) +#endif { snd_card_saa7134_t *chip = snd_kcontrol_chip(kcontrol); int addr = kcontrol->private_value; @@ -763,7 +862,12 @@ static int snd_saa7134_capsrc_get(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_ return 0; } +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static int snd_saa7134_capsrc_put(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_t * ucontrol) +#else +static int snd_saa7134_capsrc_put(struct snd_kcontrol * kcontrol, + struct snd_ctl_elem_value * ucontrol) +#endif { snd_card_saa7134_t *chip = snd_kcontrol_chip(kcontrol); int change, addr = kcontrol->private_value; @@ -840,7 +944,11 @@ static int snd_saa7134_capsrc_put(snd_kcontrol_t * kcontrol, snd_ctl_elem_value_ return change; } +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static snd_kcontrol_new_t snd_saa7134_controls[] = { +#else +static struct snd_kcontrol_new snd_saa7134_controls[] = { +#endif SAA713x_VOLUME("Video Volume", 0, MIXER_ADDR_TVTUNER), SAA713x_CAPSRC("Video Capture Switch", 0, MIXER_ADDR_TVTUNER), SAA713x_VOLUME("Line Volume", 1, MIXER_ADDR_LINE1), @@ -859,7 +967,11 @@ SAA713x_CAPSRC("Line Capture Switch", 2, MIXER_ADDR_LINE2), static int snd_card_saa7134_new_mixer(snd_card_saa7134_t * chip) { +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_card_t *card = chip->card; +#else + struct snd_card *card = chip->card; +#endif unsigned int idx; int err; @@ -873,7 +985,11 @@ static int snd_card_saa7134_new_mixer(snd_card_saa7134_t * chip) return 0; } +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) static void snd_saa7134_free(snd_card_t * card) +#else +static void snd_saa7134_free(struct snd_card * card) +#endif { snd_card_saa7134_t *chip = card->private_data; @@ -900,7 +1016,11 @@ static void snd_saa7134_free(snd_card_t * card) static int alsa_card_saa7134_create(struct saa7134_dev *dev, int devnum) { +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) snd_card_t *card; +#else + struct snd_card *card; +#endif snd_card_saa7134_t *chip; int err; diff --git a/linux/drivers/media/video/saa7134/saa7134-cards.c b/linux/drivers/media/video/saa7134/saa7134-cards.c index 45eef4148..20d0327c4 100644 --- a/linux/drivers/media/video/saa7134/saa7134-cards.c +++ b/linux/drivers/media/video/saa7134/saa7134-cards.c @@ -210,7 +210,7 @@ struct saa7134_board saa7134_boards[] = { [SAA7134_BOARD_FLYTVPLATINUM_FM] = { /* LifeView FlyTV Platinum FM (LR214WF) */ /* "Peter Missel <peter.missel@onlinehome.de> */ - .name = "LifeView FlyTV Platinum FM", + .name = "LifeView FlyTV Platinum FM / Gold", .audio_clock = 0x00200000, .tuner_type = TUNER_PHILIPS_TDA8290, .radio_type = UNSET, @@ -2662,7 +2662,7 @@ struct saa7134_board saa7134_boards[] = { .mpeg = SAA7134_MPEG_DVB, .inputs = {{ .name = name_comp1, - .vmux = 0, + .vmux = 1, .amux = LINE1, },{ .name = name_svideo, @@ -2673,7 +2673,7 @@ struct saa7134_board saa7134_boards[] = { [SAA7134_BOARD_FLYDVBT_LR301] = { /* LifeView FlyDVB-T */ /* Giampiero Giancipoli <gianci@libero.it> */ - .name = "LifeView FlyDVB-T", + .name = "LifeView FlyDVB-T / Genius VideoWonder DVB-T", .audio_clock = 0x00200000, .tuner_type = TUNER_ABSENT, .radio_type = UNSET, @@ -2849,6 +2849,40 @@ struct saa7134_board saa7134_boards[] = { .tuner_addr = ADDR_UNSET, .radio_addr = ADDR_UNSET, }, + [SAA7134_BOARD_FLYDVBT_HYBRID_CARDBUS] = { + .name = "LifeView FlyDVB-T Hybrid Cardbus", + .audio_clock = 0x00200000, + .tuner_type = TUNER_PHILIPS_TDA8290, + .radio_type = UNSET, + .tuner_addr = ADDR_UNSET, + .radio_addr = ADDR_UNSET, + .mpeg = SAA7134_MPEG_DVB, + .gpiomask = 0x00600000, /* Bit 21 0=Radio, Bit 22 0=TV */ + .inputs = {{ + .name = name_tv, + .vmux = 1, + .amux = TV, + .gpio = 0x200000, /* GPIO21=High for TV input */ + .tv = 1, + },{ + .name = name_svideo, /* S-Video signal on S-Video input */ + .vmux = 8, + .amux = LINE2, + },{ + .name = name_comp1, /* Composite signal on S-Video input */ + .vmux = 0, + .amux = LINE2, + },{ + .name = name_comp2, /* Composite input */ + .vmux = 3, + .amux = LINE2, + }}, + .radio = { + .name = name_radio, + .amux = TV, + .gpio = 0x000000, /* GPIO21=Low for FM radio antenna */ + }, + }, }; const unsigned int saa7134_bcount = ARRAY_SIZE(saa7134_boards); @@ -3374,6 +3408,30 @@ struct pci_device_id saa7134_pci_tbl[] = { .subdevice = 0x0005, .driver_data = SAA7134_BOARD_MD7134_BRIDGE_2, },{ + .vendor = PCI_VENDOR_ID_PHILIPS, + .device = PCI_DEVICE_ID_PHILIPS_SAA7134, + .subvendor = 0x1489, + .subdevice = 0x0301, + .driver_data = SAA7134_BOARD_FLYDVBT_LR301, + },{ + .vendor = PCI_VENDOR_ID_PHILIPS, + .device = PCI_DEVICE_ID_PHILIPS_SAA7133, + .subvendor = 0x5168, /* Animation Technologies (LifeView) */ + .subdevice = 0x0304, + .driver_data = SAA7134_BOARD_FLYTVPLATINUM_FM, + },{ + .vendor = PCI_VENDOR_ID_PHILIPS, + .device = PCI_DEVICE_ID_PHILIPS_SAA7133, + .subvendor = 0x5168, + .subdevice = 0x3306, + .driver_data = SAA7134_BOARD_FLYDVBT_HYBRID_CARDBUS, + },{ + .vendor = PCI_VENDOR_ID_PHILIPS, + .device = PCI_DEVICE_ID_PHILIPS_SAA7133, + .subvendor = 0x5168, + .subdevice = 0x3502, /* whats the difference to 0x3306 ?*/ + .driver_data = SAA7134_BOARD_FLYDVBT_HYBRID_CARDBUS, + },{ /* --- boards without eeprom + subsystem ID --- */ .vendor = PCI_VENDOR_ID_PHILIPS, .device = PCI_DEVICE_ID_PHILIPS_SAA7134, @@ -3540,6 +3598,7 @@ int saa7134_board_init1(struct saa7134_dev *dev) saa_writeb(SAA7134_GPIO_GPSTATUS3, 0x06); break; case SAA7134_BOARD_ADS_DUO_CARDBUS_PTV331: + case SAA7134_BOARD_FLYDVBT_HYBRID_CARDBUS: saa_writeb(SAA7134_GPIO_GPMODE3, 0x08); saa_writeb(SAA7134_GPIO_GPSTATUS3, 0x00); break; @@ -3711,6 +3770,7 @@ int saa7134_board_init2(struct saa7134_dev *dev) } break; case SAA7134_BOARD_ADS_DUO_CARDBUS_PTV331: + case SAA7134_BOARD_FLYDVBT_HYBRID_CARDBUS: /* make the tda10046 find its eeprom */ { u8 data[] = { 0x3c, 0x33, 0x62}; diff --git a/linux/drivers/media/video/saa7134/saa7134-dvb.c b/linux/drivers/media/video/saa7134/saa7134-dvb.c index 1697fe6f8..9cbc8343d 100644 --- a/linux/drivers/media/video/saa7134/saa7134-dvb.c +++ b/linux/drivers/media/video/saa7134/saa7134-dvb.c @@ -1066,6 +1066,10 @@ static int dvb_init(struct saa7134_dev *dev) dev->dvb.frontend = tda10046_attach(&tevion_dvbt220rf_config, &dev->i2c_adap); break; + case SAA7134_BOARD_FLYDVBT_HYBRID_CARDBUS: + dev->dvb.frontend = tda10046_attach(&ads_tech_duo_config, + &dev->i2c_adap); + break; #endif #ifdef HAVE_NXT200X case SAA7134_BOARD_AVERMEDIA_AVERTVHD_A180: diff --git a/linux/drivers/media/video/saa7134/saa7134.h b/linux/drivers/media/video/saa7134/saa7134.h index cbcf9adf7..8600c57b1 100644 --- a/linux/drivers/media/video/saa7134/saa7134.h +++ b/linux/drivers/media/video/saa7134/saa7134.h @@ -230,6 +230,7 @@ struct saa7134_format { #define SAA7134_BOARD_AVERMEDIA_A169_B 91 #define SAA7134_BOARD_AVERMEDIA_A169_B1 92 #define SAA7134_BOARD_MD7134_BRIDGE_2 93 +#define SAA7134_BOARD_FLYDVBT_HYBRID_CARDBUS 94 #define SAA7134_MAXBOARDS 8 #define SAA7134_INPUT_MAX 8 @@ -411,7 +412,11 @@ struct saa7134_dmasound { unsigned int read_count; void * priv_data; #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0) - snd_pcm_substream_t *substream; +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,16) + snd_pcm_substream_t *substream; +#else + struct snd_pcm_substream *substream; +#endif #endif }; diff --git a/linux/drivers/media/video/tda9840.c b/linux/drivers/media/video/tda9840.c index 42a842aec..cc6de147c 100644 --- a/linux/drivers/media/video/tda9840.c +++ b/linux/drivers/media/video/tda9840.c @@ -35,8 +35,13 @@ static int debug = 0; /* insmod parameter */ module_param(debug, int, 0644); MODULE_PARM_DESC(debug, "Turn on/off device debugging (default:off)."); +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) #define dprintk(args...) \ do { if (debug) { printk("%s: %s()[%d]: ",__stringify(KBUILD_MODNAME), __FUNCTION__, __LINE__); printk(args); } } while (0) +#else +#define dprintk(args...) \ + do { if (debug) { printk("%s: %s()[%d]: ", KBUILD_MODNAME, __FUNCTION__, __LINE__); printk(args); } } while (0) +#endif #define SWITCH 0x00 #define LEVEL_ADJUST 0x02 diff --git a/linux/drivers/media/video/tea6415c.c b/linux/drivers/media/video/tea6415c.c index 98434efb0..4e6038324 100644 --- a/linux/drivers/media/video/tea6415c.c +++ b/linux/drivers/media/video/tea6415c.c @@ -37,8 +37,13 @@ static int debug = 0; /* insmod parameter */ module_param(debug, int, 0644); MODULE_PARM_DESC(debug, "Turn on/off device debugging (default:off)."); +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) #define dprintk(args...) \ do { if (debug) { printk("%s: %s()[%d]: ",__stringify(KBUILD_MODNAME), __FUNCTION__, __LINE__); printk(args); } } while (0) +#else +#define dprintk(args...) \ + do { if (debug) { printk("%s: %s()[%d]: ", KBUILD_MODNAME, __FUNCTION__, __LINE__); printk(args); } } while (0) +#endif #define TEA6415C_NUM_INPUTS 8 #define TEA6415C_NUM_OUTPUTS 6 diff --git a/linux/drivers/media/video/tea6420.c b/linux/drivers/media/video/tea6420.c index b5e41f49b..74af061b2 100644 --- a/linux/drivers/media/video/tea6420.c +++ b/linux/drivers/media/video/tea6420.c @@ -37,8 +37,12 @@ static int debug = 0; /* insmod parameter */ module_param(debug, int, 0644); MODULE_PARM_DESC(debug, "Turn on/off device debugging (default:off)."); -#define dprintk(args...) \ +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) do { if (debug) { printk("%s: %s()[%d]: ",__stringify(KBUILD_MODNAME), __FUNCTION__, __LINE__); printk(args); } } while (0) +#else +#define dprintk(args...) \ + do { if (debug) { printk("%s: %s()[%d]: ", KBUILD_MODNAME, __FUNCTION__, __LINE__); printk(args); } } while (0) +#endif /* addresses to scan, found only at 0x4c and/or 0x4d (7-Bit) */ static unsigned short normal_i2c[] = { I2C_ADDR_TEA6420_1, I2C_ADDR_TEA6420_2, I2C_CLIENT_END }; diff --git a/linux/drivers/media/video/tvp5150.c b/linux/drivers/media/video/tvp5150.c index 571ed11dd..8a6c5c0d0 100644 --- a/linux/drivers/media/video/tvp5150.c +++ b/linux/drivers/media/video/tvp5150.c @@ -80,7 +80,7 @@ static struct v4l2_queryctrl tvp5150_qctrl[] = { .minimum = 0, .maximum = 255, .step = 1, - .default_value = 0, + .default_value = 128, .flags = 0, }, { .id = V4L2_CID_CONTRAST, @@ -89,7 +89,7 @@ static struct v4l2_queryctrl tvp5150_qctrl[] = { .minimum = 0, .maximum = 255, .step = 0x1, - .default_value = 0x10, + .default_value = 128, .flags = 0, }, { .id = V4L2_CID_SATURATION, @@ -98,7 +98,7 @@ static struct v4l2_queryctrl tvp5150_qctrl[] = { .minimum = 0, .maximum = 255, .step = 0x1, - .default_value = 0x10, + .default_value = 128, .flags = 0, }, { .id = V4L2_CID_HUE, @@ -107,7 +107,7 @@ static struct v4l2_queryctrl tvp5150_qctrl[] = { .minimum = -128, .maximum = 127, .step = 0x1, - .default_value = 0x10, + .default_value = 0, .flags = 0, } }; diff --git a/linux/drivers/media/video/video-buf.c b/linux/drivers/media/video/video-buf.c index 715feea6b..4ae4e1e7a 100644 --- a/linux/drivers/media/video/video-buf.c +++ b/linux/drivers/media/video/video-buf.c @@ -406,19 +406,25 @@ void videobuf_queue_pci(struct videobuf_queue* q) int videobuf_pci_dma_map(struct pci_dev *pci,struct videobuf_dmabuf *dma) { struct videobuf_queue q; + struct videobuf_queue_ops qops; q.dev=pci; - q.ops->vb_map_sg=(vb_map_sg_t *)pci_unmap_sg; + qops.vb_map_sg=(vb_map_sg_t *)pci_map_sg; + qops.vb_unmap_sg=(vb_map_sg_t *)pci_unmap_sg; + q.ops = &qops; - return (videobuf_dma_unmap(&q,dma)); + return (videobuf_dma_map(&q,dma)); } int videobuf_pci_dma_unmap(struct pci_dev *pci,struct videobuf_dmabuf *dma) { struct videobuf_queue q; + struct videobuf_queue_ops qops; q.dev=pci; - q.ops->vb_map_sg=(vb_map_sg_t *)pci_unmap_sg; + qops.vb_map_sg=(vb_map_sg_t *)pci_map_sg; + qops.vb_unmap_sg=(vb_map_sg_t *)pci_unmap_sg; + q.ops = &qops; return (videobuf_dma_unmap(&q,dma)); } |