[RFC PATCH 2/2] dma-mapping: Clean up dma_get_required_mask() hooks

2018-07-04 Thread Robin Murphy
As for the other mask-related hooks, standardise the arch override into a Kconfig option, and also pull the generic implementation into the DMA mapping code rather than having it hide away in the platform bus code. Signed-off-by: Robin Murphy --- arch/ia64/Kconfig | 1 + arch/

[RFC PATCH 1/2] dma-mapping: Clean up dma_set_*mask() hooks

2018-07-04 Thread Robin Murphy
Arch-specific implementions for dma_set_{coherent_,}mask() currently rely on an inconsistent mix of arch-defined Kconfig symbols and macro overrides. Now that we have a nice centralised home for DMA API gubbins, let's consolidate these loose ends under consistent config options. Signed-off-by: Rob

Re: DMA mappings and crossing boundaries

2018-07-04 Thread Robin Murphy
On 02/07/18 14:37, Benjamin Herrenschmidt wrote: On Mon, 2018-07-02 at 14:06 +0100, Robin Murphy wrote: .../... Thanks Robin, I was starting to depair anybody would reply ;-) AFAIK, dma_alloc_coherent() is defined (Documentation/DMA-API- HOWTO.txt) as always allocating to the next power-of-

Re: [PATCH v2 1/5] dt-bindings: virtio: Specify #iommu-cells value for a virtio-iommu

2018-07-04 Thread Robin Murphy
On 27/06/18 18:46, Rob Herring wrote: On Tue, Jun 26, 2018 at 11:59 AM Jean-Philippe Brucker wrote: On 25/06/18 20:27, Rob Herring wrote: On Thu, Jun 21, 2018 at 08:06:51PM +0100, Jean-Philippe Brucker wrote: A virtio-mmio node may represent a virtio-iommu device. This is discovered by the v

Re: [PATCH v2 0/5] Add virtio-iommu driver

2018-07-04 Thread Jean-Philippe Brucker
On 27/06/18 20:59, Michael S. Tsirkin wrote: >> Another reason to keep the MMIO transport option is that one >> virtio-iommu can manage DMA from endpoints on multiple PCI domains at >> the same time, as well as platform devices. Some VMMs might want that, >> in which case the IOMMU would be a separ

Re: [RFC 0/3] iommu/iova: Unsafe locking in find_iova()

2018-07-04 Thread Dmitry Safonov
Hi, Any opinion on that? It looks to remove a source of possible issues and has a nice diffstat. 2018-06-21 19:08 GMT+01:00 Dmitry Safonov : > find_iova() looks to be using a bad locking practice: it locks the > returned iova only for the search time. > And looking in code, the element can be rem

Re: [PATCH] iommu/amd: fix missing tag from dev_err message

2018-07-04 Thread Walter Harms
Am 03.07.2018 18:38, schrieb Joe Perches: > On Tue, 2018-07-03 at 11:27 -0500, Hook, Gary wrote: >> On 7/3/2018 11:24 AM, Colin Ian King wrote: >>> On 03/07/18 17:21, Hook, Gary wrote: On 7/3/2018 10:55 AM, Joe Perches wrote: > On Tue, 2018-07-03 at 07:56 -0500, Gary R Hook wrote: >