Re: [PATCH 2/2] dma-buf: add helpers for attacher dma-parms

2012-08-06 Thread Tomasz Stanislawski
On 08/06/2012 01:58 PM, Michal Nazarewicz wrote: > > Tomasz Stanislawski writes: >> I recommend to change the semantics for unlimited number of segments >> from 'value 0' to: >> >> #define DMA_SEGMENTS_COUNT_UNLIMITED ((unsigned lon

[PATCH] dma-buf: add reference counting for exporter module

2012-08-08 Thread Tomasz Stanislawski
This patch adds reference counting on a module that exports dma-buf and implements its operations. This prevents the module from being unloaded while DMABUF file is in use. Signed-off-by: Tomasz Stanislawski --- Documentation/dma-buf-sharing.txt |3 ++- drivers/base/dma-buf.c

Re: [PATCH] dma-buf: add reference counting for exporter module

2012-08-08 Thread Tomasz Stanislawski
Hi Laurent, On 08/08/2012 03:35 PM, Laurent Pinchart wrote: > Hi Tomasz, > > Thanks for the patch. > > On Wednesday 08 August 2012 12:17:41 Tomasz Stanislawski wrote: >> This patch adds reference counting on a module that exports dma-buf and >> implements its op

[PATCH v2 1/2] dma-buf: add reference counting for exporter module

2012-08-09 Thread Tomasz Stanislawski
This patch adds reference counting on a module that exported dma-buf and implements its operations. This prevents the module from being unloaded while DMABUF file is in use. Signed-off-by: Tomasz Stanislawski Acked-by: Sumit Semwal Acked-by: Daniel Vetter CC: linux-...@vger.kernel.org

[PATCH v2 2/2] drm: set owner field to for all DMABUF exporters

2012-08-09 Thread Tomasz Stanislawski
This patch sets owner field in DMABUF operations for all DMABUF exporters in DRM subsystem. This prevents an exporting module from being unloaded while exported DMABUF descriptor is in use. Signed-off-by: Tomasz Stanislawski Acked-by: Sumit Semwal Acked-by: Daniel Vetter --- drivers/gpu/drm

[PATCH v2 0/2] Enhance DMABUF with reference counting for exporter module

2012-08-09 Thread Tomasz Stanislawski
Hello, This patchset adds reference counting for an exporter module to DMABUF framework. Moreover, it adds setup of an owner field for exporters in DRM subsystem. v1: Original v2: - split patch into DMABUF and DRM part - allow owner to be NULL Regards, Tomasz Stanislawski Tomasz

Re: [PATCH v2 1/2] dma-buf: add reference counting for exporter module

2012-08-09 Thread Tomasz Stanislawski
Hi Greg, On 08/09/2012 04:23 PM, Greg KH wrote: > On Thu, Aug 09, 2012 at 11:36:21AM +0200, Tomasz Stanislawski wrote: >> This patch adds reference counting on a module that exported dma-buf and >> implements its operations. This prevents the module from being unloaded while >&

[PATCHv8 01/26] v4l: Add DMABUF as a memory type

2012-08-14 Thread Tomasz Stanislawski
From: Sumit Semwal Adds DMABUF memory type to v4l framework. Also adds the related file descriptor in v4l2_plane and v4l2_buffer. Signed-off-by: Tomasz Stanislawski [original work in the PoC for buffer sharing] Signed-off-by: Sumit Semwal Signed-off-by: Sumit Semwal Acked-by: Laurent

[PATCHv8 00/26] Integration of videobuf2 with DMABUF

2012-08-14 Thread Tomasz Stanislawski
ERNEL_MAPPING Sumit Semwal (4): v4l: Add DMABUF as a memory type v4l: vb2: add support for shared buffer (dma_buf) v4l: vb: remove warnings about MEMORY_DMABUF v4l: vb2-dma-contig: add support for dma_buf importing Tomasz Stanislawski (15): Documentation: media: description of DMABUF im

[PATCHv8 02/26] Documentation: media: description of DMABUF importing in V4L2

2012-08-14 Thread Tomasz Stanislawski
This patch adds description and usage examples for importing DMABUF file descriptor in V4L2. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park CC: linux-...@vger.kernel.org --- Documentation/DocBook/media/v4l/compat.xml |4 + Documentation/DocBook/media/v4l/io.xml

[PATCHv8 03/26] v4l: vb2: add support for shared buffer (dma_buf)

2012-08-14 Thread Tomasz Stanislawski
sample allocator of dma-buf shared buffer is given at [1]] [1]: Rob Clark's DRM: https://github.com/robclark/kernel-omap4/commits/drmplane-dmabuf Signed-off-by: Tomasz Stanislawski [original work in the PoC for buffer sharing] Signed-off-by: Sumit Semwal Signed-off-by: Sumit Semwal

[PATCHv8 04/26] v4l: vb: remove warnings about MEMORY_DMABUF

2012-08-14 Thread Tomasz Stanislawski
From: Sumit Semwal Adding DMABUF memory type causes videobuf to complain about not using it in some switch cases. This patch removes these warnings. Signed-off-by: Sumit Semwal Acked-by: Laurent Pinchart --- drivers/media/video/videobuf-core.c |4 1 file changed, 4 insertions(+) dif

[PATCHv8 05/26] v4l: vb2-dma-contig: Shorten vb2_dma_contig prefix to vb2_dc

2012-08-14 Thread Tomasz Stanislawski
From: Laurent Pinchart Signed-off-by: Laurent Pinchart --- drivers/media/video/videobuf2-dma-contig.c | 36 ++-- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/drivers/media/video/videobuf2-dma-contig.c b/drivers/media/video/videobuf2-dma-contig.c ind

[PATCHv8 06/26] v4l: vb2-dma-contig: remove reference of alloc_ctx from a buffer

2012-08-14 Thread Tomasz Stanislawski
This patch removes a reference to alloc_ctx from an instance of a DMA contiguous buffer. It helps to avoid a risk of a dangling pointer if the context is released while the buffer is still valid. Moreover it removes one dereference step while accessing a device structure. Signed-off-by: Tomasz

[PATCHv8 07/26] v4l: vb2-dma-contig: Reorder functions

2012-08-14 Thread Tomasz Stanislawski
From: Laurent Pinchart Group functions by buffer type. Signed-off-by: Laurent Pinchart --- drivers/media/video/videobuf2-dma-contig.c | 92 1 file changed, 54 insertions(+), 38 deletions(-) diff --git a/drivers/media/video/videobuf2-dma-contig.c b/drivers/media

[PATCHv8 09/26] v4l: vb2: add prepare/finish callbacks to allocators

2012-08-14 Thread Tomasz Stanislawski
From: Marek Szyprowski This patch adds support for prepare/finish callbacks in VB2 allocators. These callback are used for buffer flushing. Signed-off-by: Marek Szyprowski Acked-by: Laurent Pinchart --- drivers/media/video/videobuf2-core.c | 11 +++ include/media/videobuf2-core.h

[PATCHv8 08/26] v4l: vb2-dma-contig: add support for scatterlist in userptr mode

2012-08-14 Thread Tomasz Stanislawski
Seung-Woo Kim . Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Laurent Pinchart --- drivers/media/video/videobuf2-dma-contig.c | 226 ++-- 1 file changed, 210 insertions(+), 16 deletions(-) diff --git a/drivers/media/video/videobuf2-dma

[PATCHv8 10/26] v4l: vb2-dma-contig: add prepare/finish to dma-contig allocator

2012-08-14 Thread Tomasz Stanislawski
From: Marek Szyprowski Add prepare/finish callbacks to vb2-dma-contig allocator. Signed-off-by: Marek Szyprowski --- drivers/media/video/videobuf2-dma-contig.c | 24 1 file changed, 24 insertions(+) diff --git a/drivers/media/video/videobuf2-dma-contig.c b/drivers/

[PATCHv8 11/26] v4l: vb2-dma-contig: add support for dma_buf importing

2012-08-14 Thread Tomasz Stanislawski
] Signed-off-by: Tomasz Stanislawski [integration with refactored dma-contig allocator] Acked-by: Laurent Pinchart --- drivers/media/video/videobuf2-dma-contig.c | 120 +++- 1 file changed, 118 insertions(+), 2 deletions(-) diff --git a/drivers/media/video

[PATCHv8 12/26] v4l: vb2-vmalloc: add support for dmabuf importing

2012-08-14 Thread Tomasz Stanislawski
This patch adds support for importing DMABUF files for vmalloc allocator in Videobuf2. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video/videobuf2-vmalloc.c | 56 +++ 1 file changed, 56 insertions(+) diff --git a/drivers

[PATCHv8 13/26] v4l: vivi: support for dmabuf importing

2012-08-14 Thread Tomasz Stanislawski
This patch enhances VIVI driver with a support for importing a buffer from DMABUF file descriptors. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video/Kconfig |1 + drivers/media/video/vivi.c |2 +- 2 files changed, 2 insertions(+), 1 deletion

[PATCHv8 14/26] v4l: s5p-tv: mixer: support for dmabuf importing

2012-08-14 Thread Tomasz Stanislawski
This patch enhances s5p-tv with support for DMABUF importing via V4L2_MEMORY_DMABUF memory type. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video/s5p-tv/Kconfig |1 + drivers/media/video/s5p-tv/mixer_video.c |2 +- 2 files changed, 2

[PATCHv8 15/26] v4l: s5p-fimc: support for dmabuf importing

2012-08-14 Thread Tomasz Stanislawski
This patch enhances s5p-fimc with support for DMABUF importing via V4L2_MEMORY_DMABUF memory type. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Sylwester Nawrocki --- drivers/media/video/s5p-fimc/Kconfig|1 + drivers/media/video/s5p-fimc/fimc-capture.c

[PATCHv8 16/26] v4l: vb2-dma-contig: let mmap method to use dma_mmap_coherent call

2012-08-14 Thread Tomasz Stanislawski
From: Marek Szyprowski Let mmap method to use dma_mmap_coherent call. Moreover, this patch removes vb2_mmap_pfn_range from videobuf2 helpers as it was suggested by Laurent Pinchart. The function is no longer used in vb2 code. Signed-off-by: Marek Szyprowski Signed-off-by: Tomasz Stanislawski

[PATCHv8 19/26] v4l: vb2: add buffer exporting via dmabuf

2012-08-14 Thread Tomasz Stanislawski
This patch adds extension to videobuf2-core. It allow to export a mmap buffer as a file descriptor. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Laurent Pinchart --- drivers/media/video/videobuf2-core.c | 67 ++ include/media

[PATCHv8 18/26] v4l: add buffer exporting via dmabuf

2012-08-14 Thread Tomasz Stanislawski
This patch adds extension to V4L2 api. It allow to export a mmap buffer as file descriptor. New ioctl VIDIOC_EXPBUF is added. It takes a buffer offset used by mmap and return a file descriptor on success. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video

[PATCHv8 20/26] v4l: vb2-dma-contig: add support for DMABUF exporting

2012-08-14 Thread Tomasz Stanislawski
This patch adds support for exporting a dma-contig buffer using DMABUF interface. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video/videobuf2-dma-contig.c | 204 1 file changed, 204 insertions(+) diff --git a/drivers/media

[PATCHv8 21/26] v4l: vb2-dma-contig: add reference counting for a device from allocator context

2012-08-14 Thread Tomasz Stanislawski
descriptor(s). The device pointer kept in a buffer must be valid for the whole buffer's lifetime. Therefore MMAP buffers should take a reference to the device to avoid risk of dangling pointers. Signed-off-by: Tomasz Stanislawski --- drivers/media/video/videobuf2-dma-contig.c |5 +++

[PATCHv8 22/26] media: vb2: fail if user ptr buffer is not correctly aligned

2012-08-14 Thread Tomasz Stanislawski
From: Marek Szyprowski Signed-off-by: Marek Szyprowski --- drivers/media/video/videobuf2-dma-contig.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/drivers/media/video/videobuf2-dma-contig.c b/drivers/media/video/videobuf2-dma-contig.c index d44766e..11f4a46 100644 --- a/dr

[PATCHv8 23/26] v4l: vb2: add support for DMA_ATTR_NO_KERNEL_MAPPING

2012-08-14 Thread Tomasz Stanislawski
From: Marek Szyprowski Signed-off-by: Marek Szyprowski --- drivers/media/video/atmel-isi.c |2 +- drivers/media/video/blackfin/bfin_capture.c |2 +- drivers/media/video/marvell-ccic/mcam-core.c |3 ++- drivers/media/video/mx2_camera.c |2 +- drivers/med

[PATCHv8 24/26] v4l: s5p-fimc: support for dmabuf exporting

2012-08-14 Thread Tomasz Stanislawski
This patch enhances s5p-fimc with support for DMABUF exporting via VIDIOC_EXPBUF ioctl. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video/s5p-fimc/fimc-capture.c |9 + 1 file changed, 9 insertions(+) diff --git a/drivers/media/video/s5p-fimc

[PATCHv8 25/26] v4l: s5p-tv: mixer: support for dmabuf exporting

2012-08-14 Thread Tomasz Stanislawski
This patch enhances s5p-tv with support for DMABUF exporting via VIDIOC_EXPBUF ioctl. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video/s5p-tv/mixer_video.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/drivers/media/video/s5p-tv

[PATCHv8 26/26] v4l: s5p-mfc: support for dmabuf exporting

2012-08-14 Thread Tomasz Stanislawski
This patch enhances s5p-mfc with support for DMABUF exporting via VIDIOC_EXPBUF ioctl. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park CC: Kamil Debski --- drivers/media/video/s5p-mfc/s5p_mfc_dec.c | 18 ++ drivers/media/video/s5p-mfc/s5p_mfc_enc.c | 18

[PATCHv8 17/26] Documentation: media: description of DMABUF exporting in V4L2

2012-08-14 Thread Tomasz Stanislawski
This patch adds description and usage examples for exporting DMABUF file descriptor in V4L2. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park CC: linux-...@vger.kernel.org --- Documentation/DocBook/media/v4l/compat.xml|3 + Documentation/DocBook/media/v4l/io.xml

Re: [PATCHv8 20/26] v4l: vb2-dma-contig: add support for DMABUF exporting

2012-08-21 Thread Tomasz Stanislawski
Hi Laurent, Thank you for your comments. On 08/21/2012 12:03 PM, Laurent Pinchart wrote: > Hi Tomasz, > > Thanks for the patch. > > Just a couple of small comments below. > > On Tuesday 14 August 2012 17:34:50 Tomasz Stanislawski wrote: >> This patch adds support

Re: [PATCHv8 01/26] v4l: Add DMABUF as a memory type

2012-08-22 Thread Tomasz Stanislawski
Hi Hans, Thank your for the review. Please refer to the comments below. On 08/22/2012 12:27 PM, Hans Verkuil wrote: > On Tue August 14 2012 17:34:31 Tomasz Stanislawski wrote: >> From: Sumit Semwal >> >> Adds DMABUF memory type to v4l framework. Also adds the related

Re: [PATCH] [media] s5p-tv: Fix potential NULL pointer dereference error

2012-09-24 Thread Tomasz Stanislawski
__devinit mxr_probe(struct platform_device > *pdev) > > mdev = kzalloc(sizeof *mdev, GFP_KERNEL); > if (!mdev) { > - mxr_err(mdev, "not enough memory.\n"); > + dev_err(dev, "not enough memory.\n"); > re

Re: [PATCH v2] drivers/media/platform/s5p-tv/sdo_drv.c: fix error return code

2012-09-24 Thread Tomasz Stanislawski
s > follows: (http://coccinelle.lip6.fr/) > > // > ( > if@p1 (\(ret < 0\|ret != 0\)) > { ... return ret; } > | > ret@p1 = 0 > ) > ... when != ret = e1 > when != &ret > *if(...) > { > ... when != ret = e2 > when forall > return ret;

Re: [PATCHv8 02/26] Documentation: media: description of DMABUF importing in V4L2

2012-09-24 Thread Tomasz Stanislawski
Hi Hans, Thank you for review. On 08/22/2012 12:47 PM, Hans Verkuil wrote: > On Tue August 14 2012 17:34:32 Tomasz Stanislawski wrote: >> This patch adds description and usage examples for importing >> DMABUF file descriptor in V4L2. >> >> Signed-off-by: Tomasz Sta

Re: [PATCHv8 13/26] v4l: vivi: support for dmabuf importing

2012-09-25 Thread Tomasz Stanislawski
On 08/22/2012 01:47 PM, Hans Verkuil wrote: > On Wed August 22 2012 12:56:30 Hans Verkuil wrote: >> On Tue August 14 2012 17:34:43 Tomasz Stanislawski wrote: >>> This patch enhances VIVI driver with a support for importing a buffer >>> from DMABUF file descriptors. >

Re: [PATCHv8 18/26] v4l: add buffer exporting via dmabuf

2012-09-25 Thread Tomasz Stanislawski
Hi Hans, Thank you for review. Please refer to the comments below. On 08/22/2012 01:41 PM, Hans Verkuil wrote: > On Tue August 14 2012 17:34:48 Tomasz Stanislawski wrote: >> This patch adds extension to V4L2 api. It allow to export a mmap buffer as >> file >> descriptor. Ne

Re: [PATCHv8 18/26] v4l: add buffer exporting via dmabuf

2012-09-26 Thread Tomasz Stanislawski
Hi Hans, Thank your for your comments. On 09/26/2012 08:39 AM, Hans Verkuil wrote: > On Tue September 25 2012 18:30:43 Tomasz Stanislawski wrote: >> Hi Hans, >> Thank you for review. >> Please refer to the comments below. >> >> On 08/22/2012 01:41 PM, Hans Verkuil

Re: Question: interaction between selection API, ENUM_FRAMESIZES and S_FMT?

2013-07-02 Thread Tomasz Stanislawski
that the changes are dramatic but fixing issues with pipeline configuration is worth it. What do you think about the proposed idea? Regards, Tomasz Stanislawski [1] http://www.spinics.net/lists/linux-media/msg34541.html -- To unsubscribe from this list: send the line "unsubscribe linux

Re: [PATCHv8 21/26] v4l: vb2-dma-contig: add reference counting for a device from allocator context

2012-09-27 Thread Tomasz Stanislawski
Hi Laurent, On 08/15/2012 10:04 PM, Laurent Pinchart wrote: > Hi Tomasz, > > Thanks for the patch. > > On Tuesday 14 August 2012 17:34:51 Tomasz Stanislawski wrote: >> This patch adds taking reference to the device for MMAP buffers. >> >> Such buffers, may be ex

[PATCHv9 00/25] Integration of videobuf2 with DMABUF

2012-10-02 Thread Tomasz Stanislawski
to use dma_mmap_coherent call v4l: vb2-dma-contig: fail if user ptr buffer is not correctly aligned Sumit Semwal (4): v4l: Add DMABUF as a memory type v4l: vb2: add support for shared buffer (dma_buf) v4l: vb: remove warnings about MEMORY_DMABUF v4l: vb2-dma-contig: add support for dm

[PATCHv9 01/25] v4l: Add DMABUF as a memory type

2012-10-02 Thread Tomasz Stanislawski
From: Sumit Semwal Adds DMABUF memory type to v4l framework. Also adds the related file descriptor in v4l2_plane and v4l2_buffer. Signed-off-by: Tomasz Stanislawski [original work in the PoC for buffer sharing] Signed-off-by: Sumit Semwal Signed-off-by: Sumit Semwal Acked-by: Laurent

[PATCHv9 02/25] Documentation: media: description of DMABUF importing in V4L2

2012-10-02 Thread Tomasz Stanislawski
This patch adds description and usage examples for importing DMABUF file descriptor in V4L2. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park CC: linux-...@vger.kernel.org --- Documentation/DocBook/media/v4l/compat.xml |4 + Documentation/DocBook/media/v4l/io.xml

[PATCHv9 03/25] v4l: vb2: add support for shared buffer (dma_buf)

2012-10-02 Thread Tomasz Stanislawski
sample allocator of dma-buf shared buffer is given at [1]] [1]: Rob Clark's DRM: https://github.com/robclark/kernel-omap4/commits/drmplane-dmabuf Signed-off-by: Tomasz Stanislawski [original work in the PoC for buffer sharing] Signed-off-by: Sumit Semwal Signed-off-by: Sumit Semwal

[PATCHv9 04/25] v4l: vb: remove warnings about MEMORY_DMABUF

2012-10-02 Thread Tomasz Stanislawski
From: Sumit Semwal Adding DMABUF memory type causes videobuf to complain about not using it in some switch cases. This patch removes these warnings. Signed-off-by: Sumit Semwal Acked-by: Laurent Pinchart --- drivers/media/video/videobuf-core.c |4 1 file changed, 4 insertions(+) dif

[PATCHv9 05/25] v4l: vb2-dma-contig: shorten vb2_dma_contig prefix to vb2_dc

2012-10-02 Thread Tomasz Stanislawski
From: Laurent Pinchart Signed-off-by: Laurent Pinchart --- drivers/media/video/videobuf2-dma-contig.c | 36 ++-- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/drivers/media/video/videobuf2-dma-contig.c b/drivers/media/video/videobuf2-dma-contig.c ind

[PATCHv9 06/25] v4l: vb2-dma-contig: remove reference of alloc_ctx from a buffer

2012-10-02 Thread Tomasz Stanislawski
This patch removes a reference to alloc_ctx from an instance of a DMA contiguous buffer. It helps to avoid a risk of a dangling pointer if the context is released while the buffer is still valid. Moreover it removes one dereference step while accessing a device structure. Signed-off-by: Tomasz

[PATCHv9 07/25] v4l: vb2-dma-contig: reorder functions

2012-10-02 Thread Tomasz Stanislawski
From: Laurent Pinchart Group functions by buffer type. Signed-off-by: Laurent Pinchart --- drivers/media/video/videobuf2-dma-contig.c | 92 1 file changed, 54 insertions(+), 38 deletions(-) diff --git a/drivers/media/video/videobuf2-dma-contig.c b/drivers/media

[PATCHv9 08/25] v4l: vb2-dma-contig: add support for scatterlist in userptr mode

2012-10-02 Thread Tomasz Stanislawski
Seung-Woo Kim . Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Laurent Pinchart --- drivers/media/video/videobuf2-dma-contig.c | 226 ++-- 1 file changed, 210 insertions(+), 16 deletions(-) diff --git a/drivers/media/video/videobuf2-dma

[PATCHv9 09/25] v4l: vb2: add prepare/finish callbacks to allocators

2012-10-02 Thread Tomasz Stanislawski
From: Marek Szyprowski This patch adds support for prepare/finish callbacks in VB2 allocators. These callback are used for buffer flushing. Signed-off-by: Marek Szyprowski Acked-by: Laurent Pinchart --- drivers/media/video/videobuf2-core.c | 11 +++ include/media/videobuf2-core.h

[PATCHv9 10/25] v4l: vb2-dma-contig: add prepare/finish to dma-contig allocator

2012-10-02 Thread Tomasz Stanislawski
From: Marek Szyprowski Add prepare/finish callbacks to vb2-dma-contig allocator. Signed-off-by: Marek Szyprowski Acked-by: Laurent Pinchart --- drivers/media/video/videobuf2-dma-contig.c | 24 1 file changed, 24 insertions(+) diff --git a/drivers/media/video/videob

[PATCHv9 11/25] v4l: vb2-dma-contig: add support for dma_buf importing

2012-10-02 Thread Tomasz Stanislawski
] Signed-off-by: Tomasz Stanislawski [integration with refactored dma-contig allocator] Acked-by: Laurent Pinchart --- drivers/media/video/Kconfig|1 + drivers/media/video/videobuf2-dma-contig.c | 120 +++- 2 files changed, 119 insertions(+), 2

[PATCHv9 12/25] v4l: vb2-vmalloc: add support for dmabuf importing

2012-10-02 Thread Tomasz Stanislawski
This patch adds support for importing DMABUF files for vmalloc allocator in Videobuf2. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Laurent Pinchart --- drivers/media/video/videobuf2-vmalloc.c | 56 +++ 1 file changed, 56 insertions

[PATCHv9 13/25] v4l: vivi: support for dmabuf importing

2012-10-02 Thread Tomasz Stanislawski
This patch enhances VIVI driver with a support for importing a buffer from DMABUF file descriptors. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video/vivi.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/video/vivi.c b

[PATCHv9 14/25] v4l: s5p-tv: mixer: support for dmabuf importing

2012-10-02 Thread Tomasz Stanislawski
This patch enhances s5p-tv with support for DMABUF importing via V4L2_MEMORY_DMABUF memory type. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video/s5p-tv/mixer_video.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media

[PATCHv9 15/25] v4l: s5p-fimc: support for dmabuf importing

2012-10-02 Thread Tomasz Stanislawski
This patch enhances s5p-fimc with support for DMABUF importing via V4L2_MEMORY_DMABUF memory type. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Sylwester Nawrocki --- drivers/media/video/s5p-fimc/fimc-capture.c |2 +- 1 file changed, 1 insertion(+), 1 deletion

[PATCHv9 16/25] v4l: vb2-dma-contig: let mmap method to use dma_mmap_coherent call

2012-10-02 Thread Tomasz Stanislawski
From: Marek Szyprowski Let mmap method to use dma_mmap_coherent call. Moreover, this patch removes vb2_mmap_pfn_range from videobuf2 helpers as it was suggested by Laurent Pinchart. The function is no longer used in vb2 code. Signed-off-by: Marek Szyprowski Signed-off-by: Tomasz Stanislawski

[PATCHv9 17/25] Documentation: media: description of DMABUF exporting in V4L2

2012-10-02 Thread Tomasz Stanislawski
This patch adds description and usage examples for exporting DMABUF file descriptor in V4L2. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park CC: linux-...@vger.kernel.org --- Documentation/DocBook/media/v4l/compat.xml|3 + Documentation/DocBook/media/v4l/io.xml

[PATCHv9 18/25] v4l: add buffer exporting via dmabuf

2012-10-02 Thread Tomasz Stanislawski
This patch adds extension to V4L2 api. It allow to export a mmap buffer as file descriptor. New ioctl VIDIOC_EXPBUF is added. It takes a buffer offset used by mmap and return a file descriptor on success. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video

[PATCHv9 19/25] v4l: vb2: add buffer exporting via dmabuf

2012-10-02 Thread Tomasz Stanislawski
This patch adds extension to videobuf2-core. It allow to export a mmap buffer as a file descriptor. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Laurent Pinchart --- drivers/media/video/videobuf2-core.c | 82 ++ include/media

[PATCHv9 20/25] v4l: vb2-dma-contig: add support for DMABUF exporting

2012-10-02 Thread Tomasz Stanislawski
This patch adds support for exporting a dma-contig buffer using DMABUF interface. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video/videobuf2-dma-contig.c | 200 1 file changed, 200 insertions(+) diff --git a/drivers/media

[PATCHv9 21/25] v4l: vb2-dma-contig: add reference counting for a device from allocator context

2012-10-02 Thread Tomasz Stanislawski
descriptor(s). The device pointer kept in a buffer must be valid for the whole buffer's lifetime. Therefore MMAP buffers should take a reference to the device to avoid risk of dangling pointers. Signed-off-by: Tomasz Stanislawski --- drivers/media/video/videobuf2-dma-contig.c |5 +++

[PATCHv9 22/25] v4l: vb2-dma-contig: fail if user ptr buffer is not correctly aligned

2012-10-02 Thread Tomasz Stanislawski
From: Marek Szyprowski The DMA transfer must be aligned to a specific value. If userptr is not aligned to DMA requirements then unexpected corruptions of the memory may occur before or after a buffer. To prevent such situations, all unligned userptr buffers are rejected at VIDIOC_QBUF. Signed-o

[PATCHv9 23/25] v4l: s5p-fimc: support for dmabuf exporting

2012-10-02 Thread Tomasz Stanislawski
This patch enhances s5p-fimc with support for DMABUF exporting via VIDIOC_EXPBUF ioctl. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park CC: Sylwester Nawrocki --- drivers/media/video/s5p-fimc/fimc-capture.c |9 + 1 file changed, 9 insertions(+) diff --git a

[PATCHv9 24/25] v4l: s5p-tv: mixer: support for dmabuf exporting

2012-10-02 Thread Tomasz Stanislawski
This patch enhances s5p-tv with support for DMABUF exporting via VIDIOC_EXPBUF ioctl. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/video/s5p-tv/mixer_video.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/drivers/media/video/s5p-tv

[PATCHv9 25/25] v4l: s5p-mfc: support for dmabuf exporting

2012-10-02 Thread Tomasz Stanislawski
This patch enhances s5p-mfc with support for DMABUF exporting via VIDIOC_EXPBUF ioctl. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park CC: Kamil Debski --- drivers/media/video/s5p-mfc/s5p_mfc_dec.c | 14 ++ drivers/media/video/s5p-mfc/s5p_mfc_enc.c | 14

[GIT PULL FOR v3.7] media: s5p-hdmi: add HPD GPIO to platform data

2012-10-05 Thread Tomasz Stanislawski
media tree. Regards, Tomasz Stanislawski The following changes since commit 2425bb3d4016ed95ce83a90b53bd92c7f31091e4: em28xx: regression fix: use DRX-K sync firmware requests on em28xx (2012-10-02 17:15:22 -0300) are available in the git repository at: git://git.infradead.org/users/kmpark/linu

Re: [PATCHv9 18/25] v4l: add buffer exporting via dmabuf

2012-10-08 Thread Tomasz Stanislawski
Hi Hans, On 10/07/2012 04:17 PM, Hans Verkuil wrote: > On Sun October 7 2012 15:38:30 Laurent Pinchart wrote: >> Hi Hans, >> >> On Friday 05 October 2012 10:55:40 Hans Verkuil wrote: >>> On Tue October 2 2012 16:27:29 Tomasz Stanislawski wrote: >>>> This

Re: [PATCHv9 18/25] v4l: add buffer exporting via dmabuf

2012-10-08 Thread Tomasz Stanislawski
Hi Hans, On 10/08/2012 11:54 AM, Hans Verkuil wrote: > On Mon October 8 2012 11:40:37 Tomasz Stanislawski wrote: >> Hi Hans, >> >> On 10/07/2012 04:17 PM, Hans Verkuil wrote: >>> On Sun October 7 2012 15:38:30 Laurent Pinchart wrote: >>>> Hi Hans, >>

Re: [PATCHv9 19/25] v4l: vb2: add buffer exporting via dmabuf

2012-10-10 Thread Tomasz Stanislawski
On 10/06/2012 02:22 PM, Hans Verkuil wrote: > On Tue October 2 2012 16:27:30 Tomasz Stanislawski wrote: >> This patch adds extension to videobuf2-core. It allow to export a mmap buffer >> as a file descriptor. >> >> Signed-off-by: Tomasz Stanislawski >> Signed-o

[PATCHv10 00/26] Integration of videobuf2 with DMABUF

2012-10-10 Thread Tomasz Stanislawski
ma_buf) v4l: vb: remove warnings about MEMORY_DMABUF v4l: vb2-dma-contig: add support for dma_buf importing Tomasz Stanislawski (16): Documentation: media: description of DMABUF importing in V4L2 v4l: vb2-dma-contig: remove reference of alloc_ctx from a buffer v4l: vb2-dma-contig: add suppo

[PATCHv10 01/26] v4l: Add DMABUF as a memory type

2012-10-10 Thread Tomasz Stanislawski
From: Sumit Semwal Adds DMABUF memory type to v4l framework. Also adds the related file descriptor in v4l2_plane and v4l2_buffer. Signed-off-by: Tomasz Stanislawski [original work in the PoC for buffer sharing] Signed-off-by: Sumit Semwal Signed-off-by: Sumit Semwal Acked-by: Laurent

[PATCHv10 02/26] Documentation: media: description of DMABUF importing in V4L2

2012-10-10 Thread Tomasz Stanislawski
This patch adds description and usage examples for importing DMABUF file descriptor in V4L2. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park CC: linux-...@vger.kernel.org --- Documentation/DocBook/media/v4l/compat.xml |4 + Documentation/DocBook/media/v4l/io.xml

[PATCHv10 03/26] v4l: vb2: add support for shared buffer (dma_buf)

2012-10-10 Thread Tomasz Stanislawski
sample allocator of dma-buf shared buffer is given at [1]] [1]: Rob Clark's DRM: https://github.com/robclark/kernel-omap4/commits/drmplane-dmabuf Signed-off-by: Tomasz Stanislawski [original work in the PoC for buffer sharing] Signed-off-by: Sumit Semwal Signed-off-by: Sumit Semwal

[PATCHv10 04/26] v4l: vb: remove warnings about MEMORY_DMABUF

2012-10-10 Thread Tomasz Stanislawski
From: Sumit Semwal Adding DMABUF memory type causes videobuf to complain about not using it in some switch cases. This patch removes these warnings. Signed-off-by: Sumit Semwal Acked-by: Laurent Pinchart Acked-by: Hans Verkuil --- drivers/media/v4l2-core/videobuf-core.c |4 1 file c

[PATCHv10 05/26] v4l: vb2-dma-contig: shorten vb2_dma_contig prefix to vb2_dc

2012-10-10 Thread Tomasz Stanislawski
From: Laurent Pinchart Signed-off-by: Laurent Pinchart Acked-by: Hans Verkuil --- drivers/media/v4l2-core/videobuf2-dma-contig.c | 36 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/drivers/media/v4l2-core/videobuf2-dma-contig.c b/drivers/media/v4l2

[PATCHv10 06/26] v4l: vb2-dma-contig: remove reference of alloc_ctx from a buffer

2012-10-10 Thread Tomasz Stanislawski
This patch removes a reference to alloc_ctx from an instance of a DMA contiguous buffer. It helps to avoid a risk of a dangling pointer if the context is released while the buffer is still valid. Moreover it removes one dereference step while accessing a device structure. Signed-off-by: Tomasz

[PATCHv10 07/26] v4l: vb2-dma-contig: reorder functions

2012-10-10 Thread Tomasz Stanislawski
From: Laurent Pinchart Group functions by buffer type. Signed-off-by: Laurent Pinchart Acked-by: Hans Verkuil --- drivers/media/v4l2-core/videobuf2-dma-contig.c | 92 ++-- 1 file changed, 54 insertions(+), 38 deletions(-) diff --git a/drivers/media/v4l2-core/videobuf2-d

[PATCHv10 08/26] v4l: vb2-dma-contig: add support for scatterlist in userptr mode

2012-10-10 Thread Tomasz Stanislawski
Seung-Woo Kim . Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Laurent Pinchart Acked-by: Hans Verkuil --- drivers/media/v4l2-core/videobuf2-dma-contig.c | 226 ++-- 1 file changed, 210 insertions(+), 16 deletions(-) diff --git a/drivers/media

[PATCHv10 09/26] v4l: vb2: add prepare/finish callbacks to allocators

2012-10-10 Thread Tomasz Stanislawski
From: Marek Szyprowski This patch adds support for prepare/finish callbacks in VB2 allocators. These callback are used for buffer flushing. Signed-off-by: Marek Szyprowski Acked-by: Laurent Pinchart Acked-by: Hans Verkuil --- drivers/media/v4l2-core/videobuf2-core.c | 11 +++ inclu

[PATCHv10 10/26] v4l: vb2-dma-contig: add prepare/finish to dma-contig allocator

2012-10-10 Thread Tomasz Stanislawski
From: Marek Szyprowski Add prepare/finish callbacks to vb2-dma-contig allocator. Signed-off-by: Marek Szyprowski Acked-by: Laurent Pinchart Acked-by: Hans Verkuil --- drivers/media/v4l2-core/videobuf2-dma-contig.c | 24 1 file changed, 24 insertions(+) diff --git

[PATCHv10 11/26] v4l: vb2-dma-contig: add support for dma_buf importing

2012-10-10 Thread Tomasz Stanislawski
] Signed-off-by: Tomasz Stanislawski [integration with refactored dma-contig allocator] Acked-by: Laurent Pinchart --- drivers/media/v4l2-core/Kconfig|1 + drivers/media/v4l2-core/videobuf2-dma-contig.c | 120 +++- 2 files changed, 119 insertions

[PATCHv10 12/26] v4l: vb2-vmalloc: add support for dmabuf importing

2012-10-10 Thread Tomasz Stanislawski
This patch adds support for importing DMABUF files for vmalloc allocator in Videobuf2. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Laurent Pinchart Acked-by: Hans Verkuil --- drivers/media/v4l2-core/Kconfig |1 + drivers/media/v4l2-core/videobuf2

[PATCHv10 13/26] v4l: vivi: support for dmabuf importing

2012-10-10 Thread Tomasz Stanislawski
This patch enhances VIVI driver with a support for importing a buffer from DMABUF file descriptors. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Hans Verkuil --- drivers/media/platform/vivi.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a

[PATCHv10 14/26] v4l: s5p-tv: mixer: support for dmabuf importing

2012-10-10 Thread Tomasz Stanislawski
This patch enhances s5p-tv with support for DMABUF importing via V4L2_MEMORY_DMABUF memory type. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Hans Verkuil --- drivers/media/platform/s5p-tv/mixer_video.c |2 +- 1 file changed, 1 insertion(+), 1 deletion

[PATCHv10 15/26] v4l: s5p-fimc: support for dmabuf importing

2012-10-10 Thread Tomasz Stanislawski
This patch enhances s5p-fimc with support for DMABUF importing via V4L2_MEMORY_DMABUF memory type. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Sylwester Nawrocki Acked-by: Hans Verkuil --- drivers/media/platform/s5p-fimc/fimc-capture.c |2 +- drivers/media

[PATCHv10 16/26] v4l: vb2-dma-contig: let mmap method to use dma_mmap_coherent call

2012-10-10 Thread Tomasz Stanislawski
From: Marek Szyprowski Let mmap method to use dma_mmap_coherent call. Moreover, this patch removes vb2_mmap_pfn_range from videobuf2 helpers as it was suggested by Laurent Pinchart. The function is no longer used in vb2 code. Signed-off-by: Marek Szyprowski Signed-off-by: Tomasz Stanislawski

[PATCHv10 17/26] Documentation: media: description of DMABUF exporting in V4L2

2012-10-10 Thread Tomasz Stanislawski
This patch adds description and usage examples for exporting DMABUF file descriptor in V4L2. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park CC: linux-...@vger.kernel.org --- Documentation/DocBook/media/v4l/compat.xml|3 + Documentation/DocBook/media/v4l/io.xml

[PATCHv10 18/26] v4l: add buffer exporting via dmabuf

2012-10-10 Thread Tomasz Stanislawski
This patch adds extension to V4L2 api. It allow to export a mmap buffer as file descriptor. New ioctl VIDIOC_EXPBUF is added. It takes a buffer offset used by mmap and return a file descriptor on success. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park --- drivers/media/v4l2

[PATCHv10 19/26] v4l: vb2: add buffer exporting via dmabuf

2012-10-10 Thread Tomasz Stanislawski
This patch adds extension to videobuf2-core. It allow to export a mmap buffer as a file descriptor. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Laurent Pinchart Acked-by: Hans Verkuil --- drivers/media/v4l2-core/v4l2-mem2mem.c | 13 + drivers/media/v4l2

[PATCHv10 20/26] v4l: vb2-dma-contig: add support for DMABUF exporting

2012-10-10 Thread Tomasz Stanislawski
This patch adds support for exporting a dma-contig buffer using DMABUF interface. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Hans Verkuil --- drivers/media/v4l2-core/videobuf2-dma-contig.c | 200 1 file changed, 200 insertions(+) diff

[PATCHv10 21/26] v4l: vb2-dma-contig: add reference counting for a device from allocator context

2012-10-10 Thread Tomasz Stanislawski
descriptor(s). The device pointer kept in a buffer must be valid for the whole buffer's lifetime. Therefore MMAP buffers should take a reference to the device to avoid risk of dangling pointers. Signed-off-by: Tomasz Stanislawski Acked-by: Hans Verkuil --- drivers/media/v4l2-core/videobuf

[PATCHv10 22/26] v4l: vb2-dma-contig: fail if user ptr buffer is not correctly aligned

2012-10-10 Thread Tomasz Stanislawski
From: Marek Szyprowski The DMA transfer must be aligned to a specific value. If userptr is not aligned to DMA requirements then unexpected corruptions of the memory may occur before or after a buffer. To prevent such situations, all unligned userptr buffers are rejected at VIDIOC_QBUF. Signed-o

[PATCHv10 23/26] v4l: vb2-dma-contig: align buffer size to PAGE_SIZE

2012-10-10 Thread Tomasz Stanislawski
Most operations on DMA and DMABUF framework need page aligned buffers. This fix guarantees this requirement for vb2-dma-contig buffers. Signed-off-by: Tomasz Stanislawski --- drivers/media/v4l2-core/videobuf2-dma-contig.c |3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/media

[PATCHv10 24/26] v4l: s5p-fimc: support for dmabuf exporting

2012-10-10 Thread Tomasz Stanislawski
This patch enhances s5p-fimc with support for DMABUF exporting via VIDIOC_EXPBUF ioctl. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park CC: Sylwester Nawrocki Acked-by: Hans Verkuil --- drivers/media/platform/s5p-fimc/fimc-capture.c |9 + drivers/media/platform

[PATCHv10 25/26] v4l: s5p-tv: mixer: support for dmabuf exporting

2012-10-10 Thread Tomasz Stanislawski
This patch enhances s5p-tv with support for DMABUF exporting via VIDIOC_EXPBUF ioctl. Signed-off-by: Tomasz Stanislawski Signed-off-by: Kyungmin Park Acked-by: Hans Verkuil --- drivers/media/platform/s5p-tv/mixer_video.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a

<    1   2   3   4   5   >