Re: [PATCH v3 1/1] iommu-api: Add map_sg/unmap_sg functions

2014-07-30 Thread Will Deacon
On Tue, Jul 29, 2014 at 06:21:48PM +0100, Olav Haugan wrote: On 7/29/2014 2:25 AM, Will Deacon wrote: I agree that we can't handle IOMMUs that have a minimum page size larger than the CPU page size, but we should be able to handle the case where the maximum supported page size on the IOMMU

Re: [PATCH v4] devicetree: Add generic IOMMU device tree bindings

2014-07-30 Thread Will Deacon
Hi all, On Fri, Jul 04, 2014 at 04:29:17PM +0100, Thierry Reding wrote: From: Thierry Reding tred...@nvidia.com This commit introduces a generic device tree binding for IOMMU devices. Only a very minimal subset is described here, but it is enough to cover the requirements of both the Exynos

Re: [PATCH v4] devicetree: Add generic IOMMU device tree bindings

2014-07-30 Thread Thierry Reding
On Wed, Jul 30, 2014 at 12:04:25PM +0100, Will Deacon wrote: Hi all, On Fri, Jul 04, 2014 at 04:29:17PM +0100, Thierry Reding wrote: From: Thierry Reding tred...@nvidia.com This commit introduces a generic device tree binding for IOMMU devices. Only a very minimal subset is described

Re: [PATCH v4] devicetree: Add generic IOMMU device tree bindings

2014-07-30 Thread Joerg Roedel
On Wed, Jul 30, 2014 at 03:23:50PM +0200, Thierry Reding wrote: I think there weren't any comments left for me to address and I've mostly been waiting for Joerg to pick it up. Joerg, can you take this through the iommu tree for 3.17? Will acked this, but perhaps you were waiting for an ACK

[PATCH 06/17] ACPICA: Tables: Update for DMAR table changes.

2014-07-30 Thread Lv Zheng
From: Bob Moore robert.mo...@intel.com Update table compiler and disassembler for new DMAR fields introduced in Sept. 2013. Note that Linux DMAR users need to be updated after applying this change. [zetalog: changing drivers/iommu/dmar.c accordingly] Cc: David Woodhouse dw...@infradead.org Cc:

[PATCH 2/4] iommu/amd: Remove change_pte mmu_notifier call-back

2014-07-30 Thread Joerg Roedel
From: Joerg Roedel jroe...@suse.de All calls to this call-back are wrapped with mmu_notifer_invalidate_range_start()/end(), making this notifier pretty useless, so remove it. Signed-off-by: Joerg Roedel jroe...@suse.de Tested-by: Oded Gabbay oded.gab...@amd.com --- drivers/iommu/amd_iommu_v2.c

[PATCH 3/4] iommu/amd: Fix device_state reference counting

2014-07-30 Thread Joerg Roedel
From: Joerg Roedel jroe...@suse.de The references to the device state are not dropped everywhere. This might cause a dead-lock in amd_iommu_free_device(). Fix it. Signed-off-by: Joerg Roedel jroe...@suse.de Tested-by: Oded Gabbay oded.gab...@amd.com --- drivers/iommu/amd_iommu_v2.c | 7 +++

[PATCH 4/4] iommu/amd: Fix 2 typos in comments

2014-07-30 Thread Joerg Roedel
From: Joerg Roedel jroe...@suse.de amd_iommu_pasid_bind - amd_iommu_bind_pasid Signed-off-by: Joerg Roedel jroe...@suse.de --- drivers/iommu/amd_iommu_v2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/iommu/amd_iommu_v2.c b/drivers/iommu/amd_iommu_v2.c index

Re: [PATCH v4] devicetree: Add generic IOMMU device tree bindings

2014-07-30 Thread Will Deacon
On Wed, Jul 30, 2014 at 02:23:50PM +0100, Thierry Reding wrote: On Wed, Jul 30, 2014 at 12:04:25PM +0100, Will Deacon wrote: On Fri, Jul 04, 2014 at 04:29:17PM +0100, Thierry Reding wrote: From: Thierry Reding tred...@nvidia.com This commit introduces a generic device tree binding for

Re: [PATCH v4] devicetree: Add generic IOMMU device tree bindings

2014-07-30 Thread Mark Rutland
Hi Thierry, This looks sane to me. I just have a few questions below which are hopefully simple/stupid. On Fri, Jul 04, 2014 at 04:29:17PM +0100, Thierry Reding wrote: From: Thierry Reding tred...@nvidia.com This commit introduces a generic device tree binding for IOMMU devices. Only a

Re: [PATCH v3] iommu/arm-smmu: avoid calling request_irq in atomic context

2014-07-30 Thread Will Deacon
Hey Mitch, On Tue, Jul 29, 2014 at 07:11:15PM +0100, Mitchel Humpherys wrote: request_irq shouldn't be called from atomic context since it might sleep, but we're calling it with a spinlock held, resulting in: [9.172202] BUG: sleeping function called from invalid context at

Re: [PATCH v3] iommu/arm-smmu: avoid calling request_irq in atomic context

2014-07-30 Thread Mitchel Humpherys
On Wed, Jul 30 2014 at 08:31:14 AM, Will Deacon will.dea...@arm.com wrote: Hey Mitch, On Tue, Jul 29, 2014 at 07:11:15PM +0100, Mitchel Humpherys wrote: request_irq shouldn't be called from atomic context since it might sleep, but we're calling it with a spinlock held, resulting in: [

Re: [PATCH v3] iommu/arm-smmu: avoid calling request_irq in atomic context

2014-07-30 Thread Will Deacon
On Wed, Jul 30, 2014 at 05:51:48PM +0100, Mitchel Humpherys wrote: On Wed, Jul 30 2014 at 08:31:14 AM, Will Deacon will.dea...@arm.com wrote: On Tue, Jul 29, 2014 at 07:11:15PM +0100, Mitchel Humpherys wrote: Changelog: - v3: rework irq request code to avoid requesting the irq every

Re: [PATCH v4] devicetree: Add generic IOMMU device tree bindings

2014-07-30 Thread Olof Johansson
Hi, On Wed, Jul 30, 2014 at 8:26 AM, Mark Rutland mark.rutl...@arm.com wrote: Hi Thierry, This looks sane to me. I just have a few questions below which are hopefully simple/stupid. On Fri, Jul 04, 2014 at 04:29:17PM +0100, Thierry Reding wrote: From: Thierry Reding tred...@nvidia.com

Re: [PATCH v4] devicetree: Add generic IOMMU device tree bindings

2014-07-30 Thread Olof Johansson
On Wed, Jul 30, 2014 at 6:33 AM, Joerg Roedel j...@8bytes.org wrote: On Wed, Jul 30, 2014 at 03:23:50PM +0200, Thierry Reding wrote: I think there weren't any comments left for me to address and I've mostly been waiting for Joerg to pick it up. Joerg, can you take this through the iommu tree

[PATCH v4] iommu/arm-smmu: avoid calling request_irq in atomic context

2014-07-30 Thread Mitchel Humpherys
request_irq shouldn't be called from atomic context since it might sleep, but we're calling it with a spinlock held, resulting in: [9.172202] BUG: sleeping function called from invalid context at kernel/mm/slub.c:926 [9.182989] in_atomic(): 1, irqs_disabled(): 128, pid: 1, name:

Re: [PATCH v4] devicetree: Add generic IOMMU device tree bindings

2014-07-30 Thread Rob Herring
On Wed, Jul 30, 2014 at 9:30 AM, Will Deacon will.dea...@arm.com wrote: On Wed, Jul 30, 2014 at 02:23:50PM +0100, Thierry Reding wrote: On Wed, Jul 30, 2014 at 12:04:25PM +0100, Will Deacon wrote: On Fri, Jul 04, 2014 at 04:29:17PM +0100, Thierry Reding wrote: From: Thierry Reding

Re: [PATCH v4] devicetree: Add generic IOMMU device tree bindings

2014-07-30 Thread Mark Rutland
[...] +Multiple-master IOMMU: +-- + + iommu { + /* the specifier represents the ID of the master */ + #iommu-cells = 1; + }; + + master@1 { + /* device has master ID 42 in the IOMMU */ + iommus =

Re: [PATCH v4] devicetree: Add generic IOMMU device tree bindings

2014-07-30 Thread Arnd Bergmann
On Wednesday 30 July 2014, Thierry Reding wrote: se? I think there weren't any comments left for me to address and I've mostly been waiting for Joerg to pick it up. Joerg, can you take this through the iommu tree for 3.17? Will acked this, but perhaps you were waiting for an ACK from the