From: Nicolas Dufresne <nicolas@ndufresne.ca>
To: Stanimir Varbanov <stanimir.varbanov@linaro.org>,
Sakari Ailus <sakari.ailus@iki.fi>
Cc: Mauro Carvalho Chehab <mchehab@kernel.org>,
Pawel Osciak <pawel@osciak.com>,
Marek Szyprowski <m.szyprowski@samsung.com>,
Kyungmin Park <kyungmin.park@samsung.com>,
linux-media@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] media: vb2: unify calling of set_page_dirty_lock
Date: Tue, 13 Mar 2018 22:02:05 -0400 [thread overview]
Message-ID: <1520992925.5128.18.camel@ndufresne.ca> (raw)
In-Reply-To: <1520989785.5128.16.camel@ndufresne.ca>
Le mardi 13 mars 2018 à 21:09 -0400, Nicolas Dufresne a écrit :
> > I've looked into this again. I have hit the same issue but with CPU
> > to
> > DRM, using DMABuf allocated from DRM Dumb buffers. In that case,
> > using
> > DMA_BUF_IOCTL_SYNC fixes the issues.
> >
> > This raises a lot of question around the model used in V4L2. As you
> > mention, prepare/finish are missing in dma-vmalloc mem_ops. I'll
> > give
> > a
> > try implementing that, it should cover my initial use case, but
> > then
> > I
> > believe it will fail if my pipeline is:
> >
> > UVC -> in plane CPU modification -> DRM
> >
> > Because we don't implement begin/end_cpu_access on our exported
> > DMABuf.
> > It should also fail for the following use case:
> >
> > UVC (importer) -> DRM
> >
> > UVC driver won't call the remote dmabuf being/end_cpu_access
> > method.
> > This one is difficult because UVC driver and vivid don't seem to be
> > aware of being an importer, exported or simply exporting to CPU
> > (through mmap). I believe what we have now pretty much assumes the
> > what
> > we export as vmalloc is to be used by CPU only. Also, the usual
> > direction used by prepare/finish ops won't work for drivers like
> > vivid
> > and UVC that write into the buffers using the cpu.
> >
> > To be continued ...
>
> While I was writing that, I was already outdated, as of now, we only
> have one ops, called sync. This implements the to_cpu direction only.
Replying to myself again, obviously looking at the old videobuf code
can only get one confused.
Nicolas
prev parent reply other threads:[~2018-03-14 2:02 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-29 11:26 [PATCH] media: vb2: unify calling of set_page_dirty_lock Stanimir Varbanov
2017-10-10 7:42 ` Stanimir Varbanov
2017-10-10 8:01 ` Marek Szyprowski
2017-10-10 8:54 ` Sakari Ailus
2017-10-10 15:40 ` Nicolas Dufresne
2017-10-15 20:40 ` Sakari Ailus
2017-10-15 23:09 ` Nicolas Dufresne
2017-10-16 11:24 ` Sakari Ailus
2017-10-17 10:14 ` Sakari Ailus
2017-10-17 14:19 ` Nicolas Dufresne
2017-10-18 8:34 ` Stanimir Varbanov
2018-03-14 0:44 ` Nicolas Dufresne
2018-03-14 1:09 ` Nicolas Dufresne
2018-03-14 2:02 ` Nicolas Dufresne [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1520992925.5128.18.camel@ndufresne.ca \
--to=nicolas@ndufresne.ca \
--cc=kyungmin.park@samsung.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=m.szyprowski@samsung.com \
--cc=mchehab@kernel.org \
--cc=pawel@osciak.com \
--cc=sakari.ailus@iki.fi \
--cc=stanimir.varbanov@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).