summaryrefslogtreecommitdiff
path: root/drivers/media/video/em28xx
AgeCommit message (Collapse)Author
2009-03-30V4L/DVB (11141): em28xx: fix oops on ARM platform when allocating transfer ↵Devin Heitmueller
buffers Add missing URB_NO_TRANSFER_DMA_MAP flag, since the use of consistent memory is not permitted for DMA on the ARM platform. Thanks to Paul Thomas <pthomas8589@gmail.com> for providing sample ARM hardware that was experiencing the oops (tested on the at91rm9200 based LinuxStamp). Thanks to David Brownell <david-b@pacbell.net> for providing insight into the ARM memory architecture. Signed-off-by: Devin Heitmueller <dheitmueller@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (11139): em28xx: add remote control definition for HVR-900 (both ↵Devin Heitmueller
versions) The HVR-900 did not have a remote control defined, so it would not work. Add the line for both versions of the product. Thanks to Jens-Michael Hoffmann (#linuxtv user "jmho") for pointing out the issue and testing the patch. Signed-off-by: Devin Heitmueller <dheitmueller@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10938): em28xx: Prevent general protection fault on rmmodJean Delvare
The removal of the timer which polls the infrared input is racy. Replacing the timer with a delayed work solves the problem. Signed-off-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10840): em28xx-dvb: Remove an unused headerMauro Carvalho Chehab
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10833): em28xx: enable Compro VideoMate ForYou soundVitaly Wool
Compro VideoMate uses an external audio DSP chip, controlled via tvaudio module (tda9874a). This patch improves em28xx infrastructure to support an external audio processor and fixes the Compro VideoMate entry to work with it. Signed-off-by: Vitaly Wool <vital@embeddedalley.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10741): em28xx: Add Kaiser Baas Video to DVD maker supportDouglas Schilling Landgraf
Added usb vendor/product id for Kaiser Baas Video to DVD maker. Thanks to Trevor Campbell <tca42186@bigpond.net.au> for providing all data and tests needed to add this card to em28xx driver. Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10740): em28xx-cards: Add SIIG AVTuner-PVR boardDouglas Schilling Landgraf
Added SIIG AVTuner-PVR to the right entry. Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10739): em28xx-cards: remove incorrect entryDouglas Schilling Landgraf
Removed EM2821_BOARD_PROLINK_PLAYTV_USB2 entry. This entry has a incorrect tuner set. Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10654): em28xx: VideoMate For You USB TV box requires tvaudioMauro Carvalho Chehab
As reported by Vitaly Wool <vital@embeddedalley.com>: > about half a year ago I posted the patch that basically enabled Compro > VideoMate For You USB TV box support. > The main problem is I couldn't get the sound working. > So I kind of decomposed the box and found out the audio decoder chip > used there was Philips TDA9874A. As far as I can see, it's not supported > within the em28xx suite although it is for other TV tuner drivers. A tvaudio modprobing confirms that tda9874a chip is accessible via i2c: tvaudio: TV audio decoder + audio/video mux driver tvaudio: known chips: tda9840, tda9873h, tda9874h/a, tda9850, tda9855, tea6300, tea6320, tea6420, tda8425, pic16c54 (PV951), ta8874z tvaudio' 1-0058: chip found @ 0xb0 tvaudio' 1-0058: tvaudio': chip_read2: reg254=0x11 tvaudio' 1-0058: tvaudio': chip_read2: reg255=0x2 tvaudio' 1-0058: tda9874a_checkit(): DIC=0x11, SIC=0x2. tvaudio' 1-0058: found tda9874a. tvaudio' 1-0058: tda9874h/a found @ 0xb0 (em28xx #0) tvaudio' 1-0058: tda9874h/a: chip_write: reg0=0x0 tvaudio' 1-0058: tda9874h/a: chip_write: reg1=0xc0 tvaudio' 1-0058: tda9874h/a: chip_write: reg2=0x2 tvaudio' 1-0058: tda9874h/a: chip_write: reg11=0x80 tvaudio' 1-0058: tda9874h/a: chip_write: reg12=0x0 tvaudio' 1-0058: tda9874h/a: chip_write: reg13=0x0 tvaudio' 1-0058: tda9874h/a: chip_write: reg14=0x1 tvaudio' 1-0058: tda9874h/a: chip_write: reg15=0x0 tvaudio' 1-0058: tda9874h/a: chip_write: reg16=0x14 tvaudio' 1-0058: tda9874h/a: chip_write: reg17=0x50 tvaudio' 1-0058: tda9874h/a: chip_write: reg18=0xf9 tvaudio' 1-0058: tda9874h/a: chip_write: reg19=0x80 tvaudio' 1-0058: tda9874h/a: chip_write: reg20=0x80 tvaudio' 1-0058: tda9874h/a: chip_write: reg24=0x80 tvaudio' 1-0058: tda9874h/a: chip_write: reg255=0x0 tvaudio' 1-0058: tda9874a_setup(): A2, B/G [0x00]. tvaudio' 1-0058: tda9874h/a: thread started] This patch automatically loads tvaudio when needed (currently, only with this board). Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10556): em28xx-cards: Add Pinnacle Dazzle Video Creator Plus DVC107 ↵Douglas Schilling Landgraf
description Added board Pinnacle Dazzle Video Creator Plus DVC107 to name description field. Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10555): em28xx: CodingStyle fixesNicola Soranzo
Coding style fixes for recent changesets in em28xx. Signed-off-by: Nicola Soranzo <nsoranzo@tiscali.it> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10528): em28xx: support added for IO-DATA GV/MVP SZ - EMPIA-2820 ↵Indika Katugampala
chipset [dougsland@redhat.com: Fixed CodingStyle] Signed-off-by: Indika Katugampala <indika_20012001@yahoo.co.jp> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10525): em28xx: Coding style fixes and a typo correctionNicola Soranzo
Lots of coding style fixes and a typo correction for em28xx. [dougsland@redhat.com: fixed a reject due to a change on em28xx-audio.c] Signed-off-by: Nicola Soranzo <nsoranzo@tiscali.it> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10524): em28xx: Add DVC 101 model to Pinnacle Dazzle descriptionDouglas Schilling Landgraf
Added DVC 101 model to Pinnacle Dazzle description Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10523): em28xx-audio: Add macros EM28XX_START_AUDIO / EM28XX_STOP_AUDIODouglas Schilling Landgraf
Added macros EM28XX_START_AUDIO and EM28XX_STOP_AUDIO for em28xx_cmd(). Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10522): em28xx-audio: replace printk with em28xx_errdevAlexey Klimov
Patch removes printk and place em28xx_errdev macros to provide information about driver name to dmesg. Signed-off-by: Alexey Klimov <klimov.linux@gmail.com> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10521): em28xx-audio: Add lock for usersDouglas Schilling Landgraf
Added lock for users count Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10520): em28xx-audio: Add spinlock for triggerDouglas Schilling Landgraf
Added spinlock for trigger session Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10519): em28xx: Fix for em28xx audio startupRobert Krakora
Essentially if a snd_em28xx_capture_trigger() stop followed by a snd_em28xx_capture_trigger() start would not yield any data because there was some logic put in with an adev->shutdown variable which did not seem warranted in my humble opinion. It would cause snd_em28xx_capture_trigger start never to start up the audio stream until the device was closed and reopened again. Upon re-opening the device adev->shutdown is reset and audio data would again flow. Signed-off-by: Robert Krakora <rob.krakora@messagenetsystems.com> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10518): em28xx: Fix for em28xx memory leak and function renameRobert Krakora
Fix for em28xx memory leak and function rename Signed-off-by: Robert Krakora <rob.krakora@messagenetsystems.com> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10517): em28xx: remove bad check (changeset a31c595188af)Douglas Schilling Landgraf
Removed bad check. Thanks to Robert Krakora <rob.krakora@messagenetsystems.com> to report that. Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10516): em28xx: Add support for Easy Cap Capture DC-60Mauro Carvalho Chehab
Thanks to Peter Senna Tschudin <peter.senna@gmail.com> for borrow me one of those devices. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10515): Adds IR table for the IR provided with this board and ↵Mauro Carvalho Chehab
includes it at Kaiomy entry. Thanks to Peter Senna Tschudin <peter.senna@gmail.com> for borrow me one of those devices. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10514): em28xx: Add support for Kaiomy TVnPC U2 stickMauro Carvalho Chehab
Thanks to Peter Senna Tschudin <peter.senna@gmail.com> for borrow me one of those devices. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10327): em28xx: Add check before call em28xx_isoc_audio_deinit()Douglas Schilling Landgraf
Just call em28xx_isoc_audio_deinit() if em28xx sent a usb_submit(). Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10326): em28xx: Cleanup: fix bad whitespacingDouglas Schilling Landgraf
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10324): em28xx: Correct mailing listAlexey Klimov
Move development mail-list to linux-media on vger.kernel.org. Signed-off-by: Alexey Klimov <klimov.linux@gmail.com> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10323): em28xx: Add entry for GADMEI TVR200Douglas Schilling Landgraf
Added entry for GADMEI TVR200. Thanks to Yohanes Nugroho <yohanes@gmail.com> for testing and data collection. Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10307): em28xx: use usb_make_path to report bus infoThierry MERLE
usb_make_path reports canonical bus info. Use it when reporting bus info in VIDIOC_QUERYCAP. Signed-off-by: Thierry MERLE <thierry.merle@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10291): em28xx: fix VIDIOC_G_CTRL when there is no msp34xx device.Hans Verkuil
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10255): em28xx: Clock (XCLK) CleanupRobert Krakora
Clock (XCLK) Cleanup Signed-off-by: Robert Krakora <rob.krakora@messagenetsystems.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-23Merge branch 'topic/snd_card_new-err' into for-linusTakashi Iwai
2009-02-27V4L/DVB (10659): em28xx: register device to soundcard for sysfsNicola Soranzo
As explained in "Writing an ALSA driver" (T. Iwai), audio drivers should set the struct device for the card before registering the card instance. This will add the correct /sys/class/sound/cardN/device symlink, so HAL can see the device and ConsoleKit sets its ACL permissions for the logged-in user. For em28xx audio capture cards found e.g. in Hauppauge WinTV-HVR-900 (R2), this patch fixes errors like: ALSA lib pcm_hw.c:1429:(_snd_pcm_hw_open) Invalid value for card Error opening audio: Permission denied when running mplayer as a normal user. Signed-off-by: Nicola Soranzo <nsoranzo@tiscali.it> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-29V4L/DVB (10325): em28xx: Fix for fail to submit URB with IRQs and ↵Robert Krakora
Pre-emption Disabled Trace: (Provided by Douglas) BUG: sleeping function called from invalid context at drivers/usb/core/urb.c:558 in_atomic():0, irqs_disabled():1 Pid: 4918, comm: sox Not tainted 2.6.27.5 #1 [<c04246d8>] __might_sleep+0xc6/0xcb [<c058c8b0>] usb_kill_urb+0x1a/0xd8 [<c0488e68>] ? __kmalloc+0x9b/0xfc [<c0488e85>] ? __kmalloc+0xb8/0xfc [<c058cd5a>] ? usb_alloc_urb+0xf/0x31 [<f8dd638c>] em28xx_isoc_audio_deinit+0x2f/0x6c [em28xx_alsa] [<f8dd6573>] em28xx_cmd+0x1aa/0x1c5 [em28xx_alsa] [<f8dd65e1>] snd_em28xx_capture_trigger+0x53/0x68 [em28xx_alsa] [<f8aa8674>] snd_pcm_do_start+0x1c/0x23 [snd_pcm] [<f8aa85d7>] snd_pcm_action_single+0x25/0x4b [snd_pcm] [<f8aa9833>] snd_pcm_action+0x6a/0x76 [snd_pcm] [<f8aa98f5>] snd_pcm_start+0x14/0x16 [snd_pcm] [<f8aae10e>] snd_pcm_lib_read1+0x66/0x273 [snd_pcm] [<f8aac5a3>] ? snd_pcm_kernel_ioctl+0x46/0x5f [snd_pcm] [<f8aae4a7>] snd_pcm_lib_read+0xbf/0xcd [snd_pcm] [<f8aad774>] ? snd_pcm_lib_read_transfer+0x0/0xaf [snd_pcm] [<f89feeb6>] snd_pcm_oss_read3+0x99/0xdc [snd_pcm_oss] [<f89fef9c>] snd_pcm_oss_read2+0xa3/0xbf [snd_pcm_oss] [<c064169d>] ? _cond_resched+0x8/0x32 [<f89ff0be>] snd_pcm_oss_read+0x106/0x150 [snd_pcm_oss] [<f89fefb8>] ? snd_pcm_oss_read+0x0/0x150 [snd_pcm_oss] [<c048c6e2>] vfs_read+0x81/0xdc [<c048c7d6>] sys_read+0x3b/0x60 [<c04039bf>] sysenter_do_call+0x12/0x34 ======================= The culprit in the trace is snd_pcm_action() which invokes a spin lock which disables pre-emption which disables an IRQ which causes the __might_sleep() function to fail the irqs_disabled() test. Since pre-emption is enabled then it is safe to de-allocate the memory if you first unlink each URB. In this instance you are safe since pre-emption is disabled. If pre-emption and irqs are not disabled then call usb_kill_urb(), else call usb_unlink_urb(). Thanks to Douglas for tracking down this bug originally!!! [dougsland@redhat.com: Fixed codyingstyle] Signed-off-by: Robert Krakora <rob.krakora@messagenetsystems.com> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-29V4L/DVB (10261): em28xx: fix kernel panic on audio shutdownDevin Heitmueller
Revert a change made in change 9743 which resulted in a kernel panic in some cases on shutdown of the audio stream. First discovered when working on the Pinnacle 880e support, and later reproduced by a user on the mailing list with the HVR-900 as well. Signed-off-by: Devin Heitmueller <dheitmueller@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-29V4L/DVB (10257): em28xx: Fix for KWorld 330U BoardRobert Krakora
Fix for KWorld 330U Board Many thanks to Devin and Mauro!!! Signed-off-by: Robert Krakora <rob.krakora@messagenetsystems.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-29V4L/DVB (10256): em28xx: Fix for KWorld 330U AC97Robert Krakora
Fix for KWorld 330U AC97 Many thanks to Devin and Mauro again!!! Signed-off-by: Robert Krakora <rob.krakora@messagenetsystems.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-29V4L/DVB (10254): em28xx: Fix audio URB transfer buffer race conditionRobert Krakora
em28xx: Fix audio URB transfer buffer memory leak and race condition/corruption of capture pointer Leak fix kindly contributed by Pádraig Brady. Signed-off-by: Robert Krakora <rob.krakora@messagenetsystems.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-29V4L/DVB (10243): em28xx: fix compile warningHans Verkuil
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-29V4L/DVB (10228): em28xx: fix audio output PCM IN selectionMauro Carvalho Chehab
Some em28xx devices use the PCM IN AC 97 PIN for digital audio. However, currently, the PCM IN selection is not set by the driver. This patch allows specifying the PCM IN expected output, via board description table. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-29V4L/DVB (10192): em28xx: fix input selectionMauro Carvalho Chehab
em28xx were trying to access the third input entry, even for boards that don't support it. This patch reviews the input mux selection fixing this bug and a few other troubles, like not validating the input on one userspace ioctl. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-12drivers/media: Convert to snd_card_create()Takashi Iwai
Convert from snd_card_new() to the new snd_card_create() function. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-01-08V4L/DVB (10185): Use negated usb_endpoint_xfer_control, etcJulia Lawall
This patch extends 134179823b3ca9c8b98e0631906459dbb022ff9b by using usb_endpoint_xfer_control, usb_endpoint_xfer_isoc, usb_endpoint_xfer_bulk, and usb_endpoint_xfer_int in the negated case as well. The semantic patch that makes this change is as follows: (http://www.emn.fr/x-info/coccinelle/) // <smpl> @@ struct usb_endpoint_descriptor *epd; @@ - (usb_endpoint_type(epd) != \(USB_ENDPOINT_XFER_CONTROL\|0\)) + !usb_endpoint_xfer_control(epd) @@ struct usb_endpoint_descriptor *epd; @@ - (usb_endpoint_type(epd) != \(USB_ENDPOINT_XFER_ISOC\|1\)) + !usb_endpoint_xfer_isoc(epd) @@ struct usb_endpoint_descriptor *epd; @@ - (usb_endpoint_type(epd) != \(USB_ENDPOINT_XFER_BULK\|2\)) + !usb_endpoint_xfer_bulk(epd) @@ struct usb_endpoint_descriptor *epd; @@ - (usb_endpoint_type(epd) != \(USB_ENDPOINT_XFER_INT\|3\)) + !usb_endpoint_xfer_int(epd) // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-08V4L/DVB (10177): Fix sparse warnings on em28xxMauro Carvalho Chehab
/home/v4l/master/v4l/em28xx-core.c:396:25: warning: symbol 'outputs' was not declared. Should it be static? /home/v4l/master/v4l/em28xx-input.c:324:6: warning: symbol 'em28xx_ir_start' was not declared. Should it be static? /home/v4l/master/v4l/em28xx-cards.c:1925:5: warning: symbol 'em28xx_init_dev' was not declared. Should it be static? Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-02V4L/DVB (10163): em28xx: allocate adev together with struct em28xx devMauro Carvalho Chehab
Some devices require different setups on struct_audio. Due to that, we may need to change some fields at dev.adev during device probe. So, this patch moves the dynamic memory allocation of adev at em28xx-alsa to the dynamic allocation of struct em28xx dev that happens during device probe. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-02V4L/DVB (10160): em28xx: update chip id for em2710Mauro Carvalho Chehab
em2710 uses the same chip ID as em2820 (0x12). Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-02V4L/DVB (10141): v4l2: debugging API changed to match against driver name ↵Hans Verkuil
instead of ID. Since the i2c driver ID will be removed in the near future we have to modify the v4l2 debugging API to use the driver name instead of driver ID. Note that this API is not used in applications other than v4l2-dbg.cpp as it is for debugging and testing only. Should anyone use the old VIDIOC_G_CHIP_IDENT, then this will be logged with a warning that it is deprecated and will be removed in 2.6.30. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-01-02V4L/DVB (10135): v4l2: introduce v4l2_file_operations.Hans Verkuil
Introduce a struct v4l2_file_operations for v4l2 drivers. Remove the unnecessary inode argument. Move compat32 handling (and llseek) into the v4l2-dev core: this is now handled in the v4l2 core and no longer in the drivers themselves. Note that this changeset reverts an earlier patch that changed the return type of__video_ioctl2 from int to long. This change will be reinstated later in a much improved version. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-12-30V4L/DVB (10130): use USB API functions rather than constantsJulia Lawall
This set of patches introduces calls to the following set of functions: usb_endpoint_dir_in(epd) usb_endpoint_dir_out(epd) usb_endpoint_is_bulk_in(epd) usb_endpoint_is_bulk_out(epd) usb_endpoint_is_int_in(epd) usb_endpoint_is_int_out(epd) usb_endpoint_is_isoc_in(epd) usb_endpoint_is_isoc_out(epd) usb_endpoint_num(epd) usb_endpoint_type(epd) usb_endpoint_xfer_bulk(epd) usb_endpoint_xfer_control(epd) usb_endpoint_xfer_int(epd) usb_endpoint_xfer_isoc(epd) In some cases, introducing one of these functions is not possible, and it just replaces an explicit integer value by one of the following constants: USB_ENDPOINT_XFER_BULK USB_ENDPOINT_XFER_CONTROL USB_ENDPOINT_XFER_INT USB_ENDPOINT_XFER_ISOC An extract of the semantic patch that makes these changes is as follows: (http://www.emn.fr/x-info/coccinelle/) // <smpl> @r1@ struct usb_endpoint_descriptor *epd; @@ - ((epd->bmAttributes & \(USB_ENDPOINT_XFERTYPE_MASK\|3\)) == - \(USB_ENDPOINT_XFER_CONTROL\|0\)) + usb_endpoint_xfer_control(epd) @r5@ struct usb_endpoint_descriptor *epd; @@ - ((epd->bEndpointAddress & \(USB_ENDPOINT_DIR_MASK\|0x80\)) == - \(USB_DIR_IN\|0x80\)) + usb_endpoint_dir_in(epd) // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-12-30V4L/DVB (10125): em28xx: Don't do AC97 vendor detection for i2s audio devicesDevin Heitmueller
The current code was trying to query the AC97 registers for the vendor information even if it was clearly not a AC97 audio device (resulting in errors in the dmesg output). This was due to a bug in the way we did the check. Signed-off-by: Devin Heitmueller <dheitmueller@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>