summaryrefslogtreecommitdiff
path: root/linux/drivers
AgeCommit message (Collapse)Author
2007-10-10cx88: Replace list_for_each+list_entry with list_for_each_entryTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2007-10-10dvb: Replace list_for_each+list_entry with list_for_each_entryTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2007-10-10Rename patch forgot to rename #include <linux/video-buf-dvb.h>Mauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> Building were not broken, since the building system were using the kernel's video-buf-dvb.h. This changeset will be merged with cs 6257 at -git. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-09 V4L: zc0301, remove bad usage of ERESTARTSYSMauro Carvalho Chehab
From: Jiri Slaby <jirislaby@gmail.com> zc0301, remove bad usage of ERESTARTSYS down_read_trylock can't be interrupted and so ERESTARTSYS would reach userspace, which is not permitted. Change it to EAGAIN Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Acked-by: Luca Risolia <luca.risolia@studio.unibo.it> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-09 V4L: w9968cf, remove bad usage of ERESTARTSYSMauro Carvalho Chehab
From: Jiri Slaby <jirislaby@gmail.com> w9968cf, remove bad usage of ERESTARTSYS down_read_trylock can't be interrupted and so ERESTARTSYS would reach userspace, which is not permitted. Change it to EAGAIN Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Acked-by: Luca Risolia <luca.risolia@studio.unibo.it> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-08 Few clenups for saa7134 resume codeMauro Carvalho Chehab
From: Maxim Levitsky <maximlevitsky@gmail.com> *Disable DMA explictly on suspend *Enable DMA on resume, after all buffers were configured *Disable overlay on resume - apps should enable it when X is resumed ` Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-05 V4L: videobuf-core.c avoid NULL dereferences in videobuf-coreMauro Carvalho Chehab
From: Brandon Philips <bphilips@suse.de> The return value of videobuf_alloc() is unchecked but this function will return NULL on an error. Check for NULL and make videobuf_reqbufs() return the number of successfully allocated buffers. Also, fix saa7146_video.c and bttv-driver.c to use this returned buffer count. Tested against the vivi driver. Not tested against saa7146 or bt8xx devices. Signed-off-by: Brandon Philips <bphilips@suse.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-08merge: http://linuxtv.org/hg/~tap/v4l-dvbMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-08merge: http://linuxtv.org/hg/~mkrufky/pendingMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-08pvrusb: Update DEBUGIFC sysfs to kernel 2.6.13+Trent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> The prototypes for the show and store methods of a device_attribute changed in kernel 2.6.13, but the code in pvrusb2 was never updated. I guess the DEBUGIFC stuff isn't used much.... Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2007-10-08compat: Remove unneeded #ifTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> Both true and false branch of the #if had the exact same code, just line wrapped differently. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2007-10-08dvb: Add dependencies for VIDEOBUF_DVBTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> It needs to select VIDEOBUF_GEN and VIDEOBUF_DMA_SG, since it uses those modules. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2007-10-08cx23885: remove wrong Kconfig selection of VIDEOBUFMichael Krufky
From: Michael Krufky <mkrufky@linuxtv.org> fix bad Kconfig dependency of cx23885 module. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2007-10-08dib0700: add support for AverMedia DVB-T Express cardMichael Krufky
From: Joachim Steiger <roh@hyte.de> add Avermedia dvb-t express card 34 (usb2) id Signed-off-by: Joachim Steiger <roh@hyte.de> Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2007-10-08V4L: convert struct class_device to struct deviceMauro Carvalho Chehab
From: Kay Sievers <kay.sievers@vrfy.org> The currently used "struct class_device" will be removed from the kernel. Here is a patch that converts all users in drivers/media/video/ to struct device. Reviewed-by: Thierry Merle <thierry.merle@free.fr> Reviewed-by: Mike Isely <isely@pobox.com> Reviewed-by: Luca Risolia <luca.risolia@studio.unibo.it> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
2007-10-08saa7134: add autodetection for KWorld ATSC-115Michael Krufky
From: Eric Sandeen <sandeen@sandeen.net> Recognize the KWorld ATSC115 PCI ID as a hardware clone of the ATSC110. Signed-off-by: Eric Sandeen <sandeen@sandeen.net> Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
2007-10-08videobuf_core init always require callback implementationMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> In the past, videobuf_queue_init were used to initialize PCI DMA videobuffers. This patch renames it, to avoid confusion with the previous kernel API, doing: s/videobuf_queue_init/void videobuf_queue_core_init/ Also, the operations is now part of the function parameter. The function will also add a test if this is defined, otherwise producing BUG. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-08Fix: avoid oops on some SMP machinesMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> This workaround fix a bug that happens on some SMP machines. On those machines, videobuf_iolock is called too soon, before file .mmap handler. This patch calls the scheduler before iolocking, allowing it to properly call the pending mmap. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-08remove videobuf_set_pci_opsMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> Before the videobuf redesign, a procedure for re-using videobuf without PCI scatter/gather where provided by changing the pci-dependent operations by other operations. With the newer approach, those methods are obsolete and can safelly be removed. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-08Remove reference to dead CONFIG_UST and ust.h header.Mauro Carvalho Chehab
From: "Robert P. J. Day" <rpjday@mindspring.com> Signed-off-by: Robert P. J. Day <rpjday@mindspring.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-08compat: remove strlcpyMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> This is already defined on compat.h Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-08Fix DMA Scatter/Gather constructorMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> cx23885 driver were converted to use the newer videobuf support. Unfortunately, the constructor weren't changed. This causes an oops, since the abstract methods (implemented as callbacks) aren't defined. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-07Add support for MSI TV @nywhere A/D NBMauro Carvalho Chehab
From: Mauro Carvalho Chehab <mchehab@infradead.org> This is a Lifeview hybrid OEM board. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-08-24 Remove pointless kmalloc() return value cast in Zoran PCI controller driverMauro Carvalho Chehab
From: Jesper Juhl <jesper.juhl@gmail.com> No need to cast the void pointer returned by kmalloc() in drivers/media/video/zoran_driver.c::v4l_fbuffer_alloc(). Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-04cx23885: Update to new videobuf codeTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> cx23885 was still uses the old video-buf includes and code, which would only `work' if one happened to be compiling against a kernel that had the old headers. Even then, it wouldn't actually work, it would just compile without errors. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2007-10-04videobuf: Remove references to old Kconfig option nameTrent Piepho
From: Trent Piepho <xyzzy@speakeasy.org> CONFIG_VIDEO_BUF_DVB became CONFIG_VIDEOBUF_DVB. But in these cases, it makes more sense to use CONFIG_VIDEO_SAA7134_DVB or CONFIG_VIDEO_CX88_DVB_MODULE depending on the driver. The reference in cx23885.h should just be removed, as the code there needs to be included if DVB is on or off. I do not think you can even compile the cx23885 driver without DVB. It's clearly just leftover from when the file was obvious copied from the cx88 driver (which is not mentioned in the copyright BTW). Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
2007-10-03en_50221: convert to kthread APIMauro Carvalho Chehab
From: Christoph Hellwig <hch@infradead.org> Here's an attempted update to the full kthread API + wake_up_process: Signed-off-by: Andrew Morton <akpm@linux-foundation.org> CC: Andrew de Quincey <adq_dvb@lidskialf.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-02Buf: fix typo that caused data loss when readng streams from deviceMaxim Levitsky
If videobuf_read_stream reads two or more buffers it was overwriting the first one Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> http://thread.gmane.org/gmane.comp.video.video4linux/34978/focus=34981 Reviewed-by: Ricardo Cerqueira <v4l@cerqueira.org>
2007-09-27vivi cleanup: remove the unused varsMauro Carvalho Chehab
Last patch series made vivi driver simpler. This patch removes the now unused vars. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-27V4L: videobuf-core.c lock before streaming checkbphilips@suse.de
The reading/streaming fields are used for mutual exclusion of the queue and should be protected by the queue lock. Signed-off-by: Brandon Philips <bphilips@suse.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> http://thread.gmane.org/gmane.comp.video.video4linux/34978/focus=34981 Reviewed-by: Ricardo Cerqueira <v4l@cerqueira.org>
2007-09-27V4L: vivi.c remove the "resource" lockingbphilips@suse.de
The "resource" locking in vivi isn't needed since streamon/streamoff/read_stream do mutual exclusion using q->reading/q->streaming. Plus it is sort of broken: a) res_locked() use in vivi_read() is racey. b) res_free() calls mutex_lock twice causing streamoff to break Signed-off-by: Brandon Philips <bphilips@suse.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-27V4L: vivi.c replace logic in vivi_poll with videobuf_poll_streambphilips@suse.de
Since vivi is using videobuf_read_stream() it can use videobuf_poll_stream() now. Signed-off-by: Brandon Philips <bphilips@suse.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-27V4L: vivi.c vidioc_try_fmt_cap() negotiate a valid fieldbphilips@suse.de
If the client provides V4L2_FIELD_ANY vivi should return a valid field :) Signed-off-by: Brandon Philips <bphilips@suse.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-27V4L: properly fix support for capturing interlaced video in saa7134Maxim Levitsky
By "capturing interlaced video" I mean that card ensures that top field is really top and vice versa (I think it takes the filed ID from signal) Properly turn on/off that support depending on signal state Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-27V4L: Add basic support for suspend/resume for saa7134Maxim Levitsky
This adds support for suspend/resume for core of saa7134 Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-27V4L: Honor dev->ctl_invert when setting up the decoder in saa7134Maxim Levitsky
when user sets dev->ctl_invert, driver writes negative values to SAA7134_DEC_LUMA_CONTRAST and SAA7134_DEC_CHROMA_SATURATION, but general code that initializes decorder ignores that Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-27V4L: Fix a "scheduling while atomic" bug in saa7134Maxim Levitsky
set_tvnorm can sleep in saa7134_i2c_xfer (it will be called through tuner code) but code calls it under spinlock. Fix that Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-27V4L: Fix a lock inversion in generic videobuf codeMaxim Levitsky
videobuf_qbuf takes q->lock, and then calls q->ops->buf_prepare which by design in all drivers calls videobuf_iolock which calls videobuf_dma_init_user and this takes current->mm->mmap_sem on the other hand if user calls mumap from other thread, sys_munmap takes current->mm->mmap_sem and videobuf_vm_close takes q->lock Since this can occur only for V4L2_MEMORY_MMAP buffers, take current->mm->mmap_sem in qbuf, before q->lock, and don't take current->mm->mmap_sem videobuf_dma_init_user for those buffers Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> http://thread.gmane.org/gmane.comp.video.video4linux/34978/focus=34981 Reviewed-by: Ricardo Cerqueira <v4l@cerqueira.org>
2007-09-27videobuf cleanup: mmap check is common to all videobuf. Make it at coreMauro Carvalho Chehab
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> http://thread.gmane.org/gmane.comp.video.video4linux/34978/focus=34981 Reviewed-by: Ricardo Cerqueira <v4l@cerqueira.org>
2007-09-25Prevent for calling mmap_free without an allocated bufferMauro Carvalho Chehab
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> http://thread.gmane.org/gmane.comp.video.video4linux/34978/focus=34981 Reviewed-by: Ricardo Cerqueira <v4l@cerqueira.org>
2007-09-22Make the vertical lines to moveMauro Carvalho Chehab
While this is not the standard color bar behaviour, having some movement there allows to check if buffers are being properly handled. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-07Fix buffer release codeMauro Carvalho Chehab
Release code should happen before the cleaning of map variable. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-06An allocation error message were being printed as a debug msgMauro Carvalho Chehab
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-09-06Cleans mem->vmalloc after vfreeMauro Carvalho Chehab
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-10-02Fix Kconfig dependencyMauro Carvalho Chehab
Thanks to Michael Krufky for pointing this to me. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-08-27Fix vivi poll() methodMauro Carvalho Chehab
Due to the replace of videobuf_read_one to videobuf_read_stream, poll() method implementation is wrong. This fixes poll() implementation, making read of /dev/video? to work again. With this method, an USB driver can use video-buf, without needing to request memory from the DMA-safe area. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-08-23Rename video-buf-dvb to videobuf-dvb to be consistent with the other patchesMauro Carvalho Chehab
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-08-23Remove the obsolete video-buf moduleMauro Carvalho Chehab
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> http://thread.gmane.org/gmane.comp.video.video4linux/34978/focus=34981 Reviewed-by: Ricardo Cerqueira <v4l@cerqueira.org>
2007-08-02Convert vivi to use videobuf-vmallocMauro Carvalho Chehab
This patch removes the usage of videobuf-dma-sg from vivi driver, using instead videobuf-vmalloc. This way, vivi will be useful for testing the newer method. Reverting this patch won't hurt vivi, since both methods work fine. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> --- linux/drivers/media/video/vivi.c | 211 ++------------------------------------- 1 file changed, 14 insertions(+), 197 deletions(-)
2007-08-02Add videobuf-vmallocMauro Carvalho Chehab
Adds a newer videobuf-vmalloc module. This module uses the same videobuf controls, but implements memory allocation based on vmalloc methods. With this method, an USB driver can use video-buf, without needing to request memory from the DMA-safe area. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> --- linux/drivers/media/Kconfig | 4 linux/drivers/media/video/Kconfig | 2 linux/drivers/media/video/Makefile | 1 linux/drivers/media/video/videobuf-vmalloc.c | 385 ++++++++++++++++++++++++++ linux/include/media/videobuf-vmalloc.h | 44 ++ 5 files changed, 435 insertions(+), 1 deletion(-)