Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1445508

Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue instead of vidioc_qbuf

From Javier Martinez Canillas <javier@osg.samsung.com>
Newsgroups linux.kernel
Subject Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue instead of vidioc_qbuf
Date 2016-07-18 16:20 +0200
Message-ID <rWhyN-7ha-11@gated-at.bofh.it> (permalink)
References <rVe9Y-GD-47@gated-at.bofh.it> <rWcfL-3Nz-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hello Hans, Michael and Marek,

Thanks a lot for your feedback.

On 07/18/2016 04:34 AM, Hans Verkuil wrote:
> On 07/15/2016 06:26 PM, Javier Martinez Canillas wrote:
>> The buffer planes' dma-buf are currently mapped when buffers are queued
>> from userspace but it's more appropriate to do the mapping when buffers
>> are queued in the driver since that's when the actual DMA operation are
>> going to happen.
> 
> Does this solve anything? Once the DMA has started the behavior is the same
> as before (QBUF maps the dmabuf), only while the DMA engine hasn't started
> yet are the QBUF calls just accepted and the mapping takes place when the
> DMA is kickstarted. This makes QBUF behave inconsistently.
> 
> You don't describe here WHY this change is needed.
>

Nicolas pointed me to the TODO and suggested me the patch for the reasons
he explained in his latest email. And yes, this should had been tagged as
a RFC and just to know what you think about it. Sorry for missing that.

> I'm not sure I agree with the TODO, and even if I did, I'm not sure I agree
> with this solution. Since queuing the buffer to the driver is not the same
> as 'just before the DMA', since there may be many buffers queued up in the
> driver and you don't know in vb2 when the buffer is at the 'just before the DMA'
> stage.
>

Right, I meant "as closer as possible to when the actual DMA is going to happen"
rather than "just before the DMA".

> Regards,
> 
> 	Hans
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] [media] vb2: map dmabuf for planes on driver queue instead of vidioc_qbuf Javier Martinez Canillas <javier@osg.samsung.com> - 2016-07-15 18:30 +0200
  Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue  instead of vidioc_qbuf Shuah Khan <shuahkh@osg.samsung.com> - 2016-07-15 21:50 +0200
    Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue  instead of vidioc_qbuf Javier Martinez Canillas <javier@osg.samsung.com> - 2016-07-16 00:00 +0200
  Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue instead  of vidioc_qbuf Luis de Bethencourt <luisbg@osg.samsung.com> - 2016-07-16 14:20 +0200
  Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue  instead of vidioc_qbuf Michael Olbrich <m.olbrich@pengutronix.de> - 2016-07-18 10:10 +0200
  Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue  instead of vidioc_qbuf Hans Verkuil <hverkuil@xs4all.nl> - 2016-07-18 10:40 +0200
    Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue  instead of vidioc_qbuf Nicolas Dufresne <nicolas@ndufresne.ca> - 2016-07-18 15:40 +0200
    Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue  instead of vidioc_qbuf Javier Martinez Canillas <javier@osg.samsung.com> - 2016-07-18 16:20 +0200
  Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue instead  of vidioc_qbuf Marek Szyprowski <m.szyprowski@samsung.com> - 2016-07-18 12:30 +0200
  Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue  instead of vidioc_qbuf Sakari Ailus <sakari.ailus@iki.fi> - 2016-07-20 15:30 +0200
    Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue  instead of vidioc_qbuf Javier Martinez Canillas <javier@osg.samsung.com> - 2016-07-20 16:10 +0200
      Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue  instead of vidioc_qbuf Javier Martinez Canillas <javier@osg.samsung.com> - 2016-07-20 16:20 +0200
      Re: [PATCH] [media] vb2: map dmabuf for planes on driver queue  instead of vidioc_qbuf Hans Verkuil <hverkuil@xs4all.nl> - 2016-07-20 16:20 +0200

csiph-web