From: Jakob Bornecrantz <wallbraker@gmail.com>
To: Daniel Vetter <daniel@ffwll.ch>
Cc: "linaro-mm-sig@lists.linaro.org" <linaro-mm-sig@lists.linaro.org>,
Daniel Vetter <daniel.vetter@ffwll.ch>,
Thomas Hellstrom <thellstrom@vmware.com>,
"dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>
Subject: Re: dma-buf non-coherent mmap
Date: Fri, 1 Nov 2013 01:17:44 +0100 [thread overview]
Message-ID: <CADdNU4RTRJhmjzFcz1ozcj6uJ7OrAFqcNThXYReDw3DoKChZhQ@mail.gmail.com> (raw)
In-Reply-To: <20131031230051.GK4167@phenom.ffwll.local>
On Fri, Nov 1, 2013 at 12:00 AM, Daniel Vetter <daniel@ffwll.ch> wrote:
> On Thu, Oct 31, 2013 at 10:07:25PM +0100, Thomas Hellstrom wrote:
>> On 10/31/2013 09:48 PM, Dave Airlie wrote:
>> >On Fri, Nov 1, 2013 at 6:40 AM, Thomas Hellstrom <thellstrom@vmware.com> wrote:
>> >>Well, I'd be happy to avoid mmap, but then what does optional mean in this
>> >>context?
>> >>That all generic user-space apps *must* implement a workaround if mmap isn't
>> >>implemented?
>> >>
>> >>It's unfortunate a bit like implicit synchronization mentioned in section 3)
>> >>in Direct Userspace Access/mmap Support
>> >>in the kernel dma-buf doc: It should be avoided, otherwise it might be
>> >>relied upon by userspace and exporters
>> >>not implementing it will suffer.
>> >>
>> >>In reality, people will start using mmap() and won't care to implement
>> >>workarounds if it's not supported, and drivers like
>> >>vmwgfx and non-coherent architectures will suffer.
>> >>
>> >>I haven't looked closely at how DRI3 or Wayland/weston use or will use
>> >>dma-buf, but if they rely on mmap, we're sort
>> >>of lost. MIR uses the following scheme:
>> >DRI3 and wayland won't use dma-buf mmap directly,
>> >
>> >using dma-buf mmap directly is wrong for anything that shares objects
>> >with itself.
>>
>> That sounds good to hear. Perhaps we should add that to the dma-buf docs.
>
> Userspace mmap was essentially added as a concession to the android ion
> guys since they really, really wanted it. We've tried to tell them that
> it's a horrible idea (see all the fun with coherency and syncing), but
> they said that they have userspace for it already and so we let it be.
>
> Imo if you're not running Android userspace there's no need for this at
> all.
But now it turns out that gstreamer is using it and our life is hell. We should
have made it not work for _any_ driver if CONFIG_ANDRIOD wasn't set.
Cheers, Jakob.
next prev parent reply other threads:[~2013-11-01 0:17 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-31 17:00 dma-buf non-coherent mmap Thomas Hellstrom
2013-10-31 17:52 ` Rob Clark
2013-10-31 20:40 ` Thomas Hellstrom
2013-10-31 20:48 ` Dave Airlie
2013-10-31 21:07 ` Thomas Hellstrom
2013-10-31 23:00 ` Daniel Vetter
2013-11-01 0:17 ` Jakob Bornecrantz [this message]
2013-11-01 0:25 ` Rob Clark
2013-11-01 0:37 ` Jakob Bornecrantz
2013-11-01 0:57 ` Rob Clark
2013-11-01 10:03 ` Lucas Stach
2013-11-01 10:17 ` Daniel Vetter
2013-11-01 13:22 ` Rob Clark
2013-11-01 13:32 ` Lucas Stach
2013-11-04 7:53 ` Thomas Hellstrom
2013-11-04 10:22 ` Lucas Stach
2013-11-04 10:48 ` Thomas Hellstrom
2013-11-01 13:54 ` Thomas Hellstrom
2013-10-31 21:10 ` Rob Clark
2013-10-31 21:38 ` Thomas Hellstrom
2013-10-31 22:43 ` [Linaro-mm-sig] " Benjamin Gaignard
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=CADdNU4RTRJhmjzFcz1ozcj6uJ7OrAFqcNThXYReDw3DoKChZhQ@mail.gmail.com \
--to=wallbraker@gmail.com \
--cc=daniel.vetter@ffwll.ch \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=linaro-mm-sig@lists.linaro.org \
--cc=thellstrom@vmware.com \
/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).