iommu.lists.linux-foundation.org archive mirror
 help / color / mirror / Atom feed
From: Robin Murphy <robin.murphy@arm.com>
To: Christoph Hellwig <hch@infradead.org>,
	"Isaac J. Manjarres" <isaacm@codeaurora.org>
Cc: kernel-team@android.com, iommu@lists.linux-foundation.org,
	pratikp@codeaurora.org, linux-kernel@vger.kernel.org,
	Liam Mark <lmark@codeaurora.org>
Subject: Re: [RFC PATCH] iommu/dma: Allow drivers to reserve an iova range
Date: Mon, 17 Feb 2020 15:50:48 +0000	[thread overview]
Message-ID: <c58fd502-52a4-cb0f-6e7f-e9cc00627313@arm.com> (raw)
In-Reply-To: <20200217080138.GB10342@infradead.org>

On 17/02/2020 8:01 am, Christoph Hellwig wrote:
> On Fri, Feb 14, 2020 at 02:58:16PM -0800, Isaac J. Manjarres wrote:
>> From: Liam Mark <lmark@codeaurora.org>
>>
>> Some devices have a memory map which contains gaps or holes.
>> In order for the device to have as much IOVA space as possible,
>> allow its driver to inform the DMA-IOMMU layer that it should
>> not allocate addresses from these holes.
> 
> Layering violation.  dma-iommu is the translation layer between the
> DMA API and the IOMMU API.  And calls into it from drivers performing
> DMA mappings need to go through the DMA API (and be documented there).

+1

More than that, though, we already have "holes in the address space" 
support for the sake of PCI host bridge windows - assuming this is the 
same kind of thing (i.e. the holes are between memory regions and other 
resources in PA space, so are only relevant once address translation 
comes into the picture), then this is IOMMU API level stuff, so even a 
DMA API level interface would be inappropriate.

Robin.
_______________________________________________
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu

  reply	other threads:[~2020-02-17 15:50 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-14 22:58 [RFC PATCH] iommu/dma: Allow drivers to reserve an iova range Isaac J. Manjarres
2020-02-17  8:01 ` Christoph Hellwig
2020-02-17 15:50   ` Robin Murphy [this message]
2020-02-19  1:57     ` isaacm
2020-02-19 11:15       ` Will Deacon
2020-02-19 20:06         ` isaacm
2020-02-20  8:45           ` Will Deacon
2020-02-20 18:57             ` Pratik Patel
2020-02-19  9:46 ` Joerg Roedel

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=c58fd502-52a4-cb0f-6e7f-e9cc00627313@arm.com \
    --to=robin.murphy@arm.com \
    --cc=hch@infradead.org \
    --cc=iommu@lists.linux-foundation.org \
    --cc=isaacm@codeaurora.org \
    --cc=kernel-team@android.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lmark@codeaurora.org \
    --cc=pratikp@codeaurora.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).