V4L/DVB (6251): Replace video-buf to a more generic approach
authorMauro Carvalho Chehab <mchehab@infradead.org>
Thu, 23 Aug 2007 19:26:14 +0000 (16:26 -0300)
committerMauro Carvalho Chehab <mchehab@infradead.org>
Wed, 10 Oct 2007 01:14:55 +0000 (22:14 -0300)
commit7a7d9a89d0307b1743d782197e2c5fc5ddf183f3
treef5b1b220672128d089b5a6c469608e90482a6f60
parent7c596fa964806acb3b5ababb7ec4e1da35b140b3
V4L/DVB (6251): Replace video-buf to a more generic approach

video-buf currently does two different tasks:

- Manages video buffers with a common code that allows
  implementing all the V4L2 different modes of buffering;

- Controls memory allocations

While the first task is generic, the second were written to support PCI DMA
Scatter/Gather needs. The original approach can't even work for those
video capture hardware that don't support scatter/gather.

I did one approach to make it more generic. While the approach worked
fine for vivi driver, it were not generic enough to handle USB needs.

This patch creates two different modules, one containing the generic
video buffer handling (videobuf-core) and another with PCI DMA S/G.
After this patch, it would be simpler to write an USB video-buf and a
non-SG DMA module.

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>
drivers/media/video/videobuf-core.c [new file with mode: 0644]
drivers/media/video/videobuf-dma-sg.c [new file with mode: 0644]
include/media/videobuf-core.h [new file with mode: 0644]
include/media/videobuf-dma-sg.h [new file with mode: 0644]