linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: linux-arm-kernel@lists.infradead.org
Cc: Pintu Kumar <pintu.k@outlook.com>,
	"linux-mm@kvack.org" <linux-mm@kvack.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linaro-mm-sig@lists.linaro.org" <linaro-mm-sig@lists.linaro.org>
Subject: Re: Questions regarding DMA buffer sharing using IOMMU
Date: Mon, 12 May 2014 14:00:57 +0200	[thread overview]
Message-ID: <5218408.5YRJXjS4BX@wuerfel> (raw)
In-Reply-To: <BAY169-W12541AD089785F8BFBD4E26EF350@phx.gbl>

On Monday 12 May 2014 15:12:41 Pintu Kumar wrote:
> Hi, 
> I have some queries regarding IOMMU and CMA buffer sharing. 
> We have an embedded linux device (kernel 3.10, RAM: 256Mb) in 
> which camera and codec supports IOMMU but the display does not support IOMMU. 
> Thus for camera capture we are using iommu buffers using
> ION/DMABUF. But for all display rendering we are using CMA buffers. 
> So, the question is how to achieve buffer sharing (zero-copy)
> between Camera and Display using only IOMMU? 
> Currently we are achieving zero-copy using CMA. And we are
> exploring options to use IOMMU. 
> Now we wanted to know which option is better? To use IOMMU or CMA? 
> If anybody have come across these design please share your thoughts and results. 

There is a slight performance overhead in using the IOMMU in general,
because the IOMMU has to fetch the page table entries from memory
at least some of the time.

If that overhead is within the constraints you have for transfers between
camera and codec, you are always better off using IOMMU since that
means you don't have to do memory migration.

Note however, that we don't have a way to describe IOMMU relations
to devices in DT, so whatever you come up with to do this will most
likely be incompatible with what we do in future kernel versions.

	Arnd

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2014-05-12 12:01 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-12  9:42 Pintu Kumar
2014-05-12 12:00 ` Arnd Bergmann [this message]
2014-05-12 14:37   ` Pintu Kumar
2014-05-12 16:27     ` Laura Abbott
2014-05-13  4:57       ` Pintu Kumar
2014-05-13  5:41       ` Pintu Kumar

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=5218408.5YRJXjS4BX@wuerfel \
    --to=arnd@arndb.de \
    --cc=linaro-mm-sig@lists.linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=pintu.k@outlook.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