Re: [PATCH v17 00/20] iommu/arm-smmu + drm/msm: per-process GPU pgtables

2020-09-21 Thread Jordan Crouse
On Mon, Sep 21, 2020 at 10:30:57PM +0100, Will Deacon wrote: > On Sat, Sep 05, 2020 at 01:04:06PM -0700, Rob Clark wrote: > > From: Rob Clark > > > > NOTE: I have re-ordered the series, and propose that we could merge this > > series in the following order: > > > >1) 01-11 - merge

Re: [PATCH v17 00/20] iommu/arm-smmu + drm/msm: per-process GPU pgtables

2020-09-21 Thread Rob Clark
On Mon, Sep 21, 2020 at 2:31 PM Will Deacon wrote: > > On Sat, Sep 05, 2020 at 01:04:06PM -0700, Rob Clark wrote: > > From: Rob Clark > > > > NOTE: I have re-ordered the series, and propose that we could merge this > > series in the following order: > > > >1) 01-11 - merge via drm

Re: [Intel-gfx] [PATCH v3 0/6] Convert the intel iommu driver to the dma-iommu api

2020-09-21 Thread Lu Baolu
Hi Logan, On 9/21/20 11:48 PM, Logan Gunthorpe wrote: On 2020-09-20 12:36 a.m., Lu Baolu wrote: Hi Logan, On 2020/9/19 4:47, Logan Gunthorpe wrote: Hi Lu, On 2020-09-11 9:21 p.m., Lu Baolu wrote: Tom Murphy has almost done all the work. His latest patch series was posted here.

Re: [PATCH v5 05/38] drm: prime: use sgtable iterators in drm_prime_sg_to_page_addr_arrays()

2020-09-21 Thread Alex Goins
Tested-by: Alex Goins This change fixes a regression with drm_prime_sg_to_page_addr_arrays() and AMDGPU in v5.9. Commit 39913934 similarly revamped AMDGPU to use sgtable helper functions. When it changed from dma_map_sg_attrs() to dma_map_sgtable(), as a side effect it started correctly

Re: [PATCH 1/3] iommu/io-pgtable-arm: Support coherency for Mali LPAE

2020-09-21 Thread Will Deacon
On Mon, Sep 21, 2020 at 10:53:23PM +0100, Robin Murphy wrote: > On 2020-09-21 18:57, Will Deacon wrote: > > On Wed, Sep 16, 2020 at 12:51:05AM +0100, Robin Murphy wrote: > > > Midgard GPUs have ACE-Lite master interfaces which allows systems to > > > integrate them in an I/O-coherent manner. It

Re: [PATCHv4 1/6] iommu/io-pgtable-arm: Add support to use system cache

2020-09-21 Thread Will Deacon
On Mon, Sep 21, 2020 at 11:03:49PM +0100, Robin Murphy wrote: > On 2020-09-21 19:03, Will Deacon wrote: > > On Fri, Sep 11, 2020 at 07:57:18PM +0530, Sai Prakash Ranjan wrote: > > > Add a quirk IO_PGTABLE_QUIRK_SYS_CACHE to override the > > > attributes set in TCR for the page table walker when >

Re: [PATCHv4 1/6] iommu/io-pgtable-arm: Add support to use system cache

2020-09-21 Thread Robin Murphy
On 2020-09-21 19:03, Will Deacon wrote: On Fri, Sep 11, 2020 at 07:57:18PM +0530, Sai Prakash Ranjan wrote: Add a quirk IO_PGTABLE_QUIRK_SYS_CACHE to override the attributes set in TCR for the page table walker when using system cache. I wonder if the panfrost folks can reuse this for the

Re: [PATCH 1/3] iommu/io-pgtable-arm: Support coherency for Mali LPAE

2020-09-21 Thread Robin Murphy
On 2020-09-21 18:57, Will Deacon wrote: On Wed, Sep 16, 2020 at 12:51:05AM +0100, Robin Murphy wrote: Midgard GPUs have ACE-Lite master interfaces which allows systems to integrate them in an I/O-coherent manner. It seems that from the GPU's viewpoint, the rest of the system is its outer

Re: [PATCH v17 00/20] iommu/arm-smmu + drm/msm: per-process GPU pgtables

2020-09-21 Thread Will Deacon
On Sat, Sep 05, 2020 at 01:04:06PM -0700, Rob Clark wrote: > From: Rob Clark > > NOTE: I have re-ordered the series, and propose that we could merge this > series in the following order: > >1) 01-11 - merge via drm / msm-next >2) 12-15 - merge via iommu, no dependency on

Re: [PATCH v3 6/8] iommu/arm-smmu: Add impl hook for inherit boot mappings

2020-09-21 Thread Will Deacon
On Sat, Sep 12, 2020 at 10:25:59PM -0500, Bjorn Andersson wrote: > On Fri 11 Sep 12:13 CDT 2020, Robin Murphy wrote: > > On 2020-09-04 16:55, Bjorn Andersson wrote: > > > Add a new operation to allow platform implementations to inherit any > > > stream mappings from the boot loader. > > > > Is

Re: [PATCH] iommu/qcom: add missing put_device() call in qcom_iommu_of_xlate()

2020-09-21 Thread Will Deacon
On Tue, Sep 22, 2020 at 03:13:53AM +0800, kernel test robot wrote: > Thank you for the patch! Perhaps something to improve: > > [auto build test WARNING on iommu/next] > [also build test WARNING on linus/master v5.9-rc6 next-20200921] > [cannot apply to robclark/msm-next] &

Re: [PATCH v2] iommu/arm: Add module parameter to set msi iova address

2020-09-21 Thread Will Deacon
On Mon, Sep 14, 2020 at 11:13:07AM -0700, Vennila Megavannan wrote: > From: Srinath Mannam > > Add provision to change default value of MSI IOVA base to platform's > suitable IOVA using module parameter. The present hardcoded MSI IOVA base > may not be the accessible IOVA ranges of platform. >

Re: [PATCH] iommu/qcom: add missing put_device() call in qcom_iommu_of_xlate()

2020-09-21 Thread kernel test robot
Hi Yu, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on iommu/next] [also build test WARNING on linus/master v5.9-rc6 next-20200921] [cannot apply to robclark/msm-next] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting

kdump boot failing with IVRS checksum failure

2020-09-21 Thread Jerry Snitselaar
Hello Joerg, We are seeing a kdump kernel boot failure in test on an HP DL325 Gen10 and it was tracked down to 387caf0b759a ("iommu/amd: Treat per-device exclusion ranges as r/w unity-mapped regions"). Reproduced on 5.9-rc5 and goes away with revert of the commit. There is a follow on commit

Re: [PATCH] iommu/qcom: add missing put_device() call in qcom_iommu_of_xlate()

2020-09-21 Thread Rob Clark
On Mon, Sep 21, 2020 at 11:27 AM Rob Clark wrote: > > On Mon, Sep 21, 2020 at 10:50 AM Will Deacon wrote: > > > > On Fri, Sep 18, 2020 at 09:13:57AM +0800, Yu Kuai wrote: > > > if of_find_device_by_node() succeed, qcom_iommu_of_xlate() doesn't have > > > a corresponding put_device(). Thus add

Re: [PATCH] iommu/qcom: add missing put_device() call in qcom_iommu_of_xlate()

2020-09-21 Thread Rob Clark
On Mon, Sep 21, 2020 at 10:50 AM Will Deacon wrote: > > On Fri, Sep 18, 2020 at 09:13:57AM +0800, Yu Kuai wrote: > > if of_find_device_by_node() succeed, qcom_iommu_of_xlate() doesn't have > > a corresponding put_device(). Thus add put_device() to fix the exception > > handling for this function

Re: [PATCH] iommu/arm-smmu-v3: Fix endianness annotations

2020-09-21 Thread Will Deacon
On Fri, 18 Sep 2020 16:18:57 +0200, Jean-Philippe Brucker wrote: > When building with C=1, sparse reports some issues regarding endianness > annotations: > > arm-smmu-v3.c:221:26: warning: cast to restricted __le64 > arm-smmu-v3.c:221:24: warning: incorrect type in assignment (different base >

Re: [PATCHv4 1/6] iommu/io-pgtable-arm: Add support to use system cache

2020-09-21 Thread Will Deacon
On Fri, Sep 11, 2020 at 07:57:18PM +0530, Sai Prakash Ranjan wrote: > Add a quirk IO_PGTABLE_QUIRK_SYS_CACHE to override the > attributes set in TCR for the page table walker when > using system cache. I wonder if the panfrost folks can reuse this for the issue discussed over at:

Re: [PATCH 1/3] iommu/io-pgtable-arm: Support coherency for Mali LPAE

2020-09-21 Thread Will Deacon
On Wed, Sep 16, 2020 at 12:51:05AM +0100, Robin Murphy wrote: > Midgard GPUs have ACE-Lite master interfaces which allows systems to > integrate them in an I/O-coherent manner. It seems that from the GPU's > viewpoint, the rest of the system is its outer shareable domain, and so > even when snoop

Re: [PATCH] iommu/qcom: add missing put_device() call in qcom_iommu_of_xlate()

2020-09-21 Thread Will Deacon
On Fri, Sep 18, 2020 at 09:13:57AM +0800, Yu Kuai wrote: > if of_find_device_by_node() succeed, qcom_iommu_of_xlate() doesn't have > a corresponding put_device(). Thus add put_device() to fix the exception > handling for this function implementation. > > Fixes: e86d1aa8b60f ("iommu/arm-smmu: Move

Re: [PATCH] iommu/io-pgtable-arm: Clean up faulty sanity check

2020-09-21 Thread Christoph Hellwig
On Mon, Sep 21, 2020 at 04:08:01PM +0100, Robin Murphy wrote: > Checking for a nonzero dma_pfn_offset was a quick shortcut to validate > whether the DMA == phys assumption could hold at all. Checking for a > non-NULL dma_range_map is not quite equivalent, since a map may be > present to describe a

Re: [Intel-gfx] [PATCH v3 0/6] Convert the intel iommu driver to the dma-iommu api

2020-09-21 Thread Logan Gunthorpe
On 2020-09-20 12:36 a.m., Lu Baolu wrote: > Hi Logan, > > On 2020/9/19 4:47, Logan Gunthorpe wrote: >> Hi Lu, >> >> On 2020-09-11 9:21 p.m., Lu Baolu wrote: >>> Tom Murphy has almost done all the work. His latest patch series was >>> posted here. >>> >>>

[PATCH] iommu/io-pgtable-arm: Clean up faulty sanity check

2020-09-21 Thread Robin Murphy
Checking for a nonzero dma_pfn_offset was a quick shortcut to validate whether the DMA == phys assumption could hold at all. Checking for a non-NULL dma_range_map is not quite equivalent, since a map may be present to describe a limited DMA window even without an offset, and thus this check can

Re: arm-smmu 5000000.iommu: Cannot accommodate DMA offset for IOMMU page tables

2020-09-21 Thread Robin Murphy
, WnR = 0 [2.305581] [] user address but active_mm is swapper [2.311941] Internal error: Oops: 9604 [#1] PREEMPT SMP [2.317512] Modules linked in: [2.320566] CPU: 1 PID: 1 Comm: swapper/0 Tainted: GW 5.9.0-rc5-next-20200921 #1 [2.329352] Hardware name

Re: [PATCH] dma: debug: convert comma to semicolon

2020-09-21 Thread Christoph Hellwig
Thanks, applied to the dma-mapping for-next tree. ___ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu

Re: [PATCH v2 0/2] iommu/arm-smmu-v3: Improve cmdq lock efficiency

2020-09-21 Thread John Garry
On 21/09/2020 14:43, Will Deacon wrote: On Fri, Aug 21, 2020 at 09:54:20PM +0800, John Garry wrote: As mentioned in [0], the CPU may consume many cycles processing arm_smmu_cmdq_issue_cmdlist(). One issue we find is the cmpxchg() loop to get space on the queue takes a lot of time once we start

arm-smmu 5000000.iommu: Cannot accommodate DMA offset for IOMMU page tables

2020-09-21 Thread Naresh Kamboju
arm64 Freescale Layerscape 2088A RDB Board boot failed with linux-next 5.9.0-rc5-next-20200921 kernel tag version. The kernel warning and then kernel panic happened. Reported-by: Naresh Kamboju metadata: git branch: master git repo: https://gitlab.com/Linaro/lkft/mirrors/next/linux-next

Re: [PATCH v2 0/2] iommu/arm-smmu-v3: Improve cmdq lock efficiency

2020-09-21 Thread Will Deacon
On Fri, Aug 21, 2020 at 09:54:20PM +0800, John Garry wrote: > As mentioned in [0], the CPU may consume many cycles processing > arm_smmu_cmdq_issue_cmdlist(). One issue we find is the cmpxchg() loop to > get space on the queue takes a lot of time once we start getting many > CPUs contending - from

RE: [PATCH v10 10/13] iommu/arm-smmu-v3: Check for SVA features

2020-09-21 Thread Shameerali Kolothum Thodi
Hi Jean, > -Original Message- > From: iommu [mailto:iommu-boun...@lists.linux-foundation.org] On Behalf Of > Jean-Philippe Brucker > Sent: 18 September 2020 11:19 > To: iommu@lists.linux-foundation.org; linux-arm-ker...@lists.infradead.org; > linux...@kvack.org > Cc: fenghua...@intel.com;

[PATCH] dma: debug: convert comma to semicolon

2020-09-21 Thread Xu Wang
Replace a comma between expression statements by a semicolon. Signed-off-by: Xu Wang --- kernel/dma/debug.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/dma/debug.c b/kernel/dma/debug.c index 8e9f7b301c6d..126ada40ef09 100644 --- a/kernel/dma/debug.c +++

Re: [PATCH 1/4] ARM/omap1: switch to use dma_direct_set_offset for lbus DMA offsets

2020-09-21 Thread Christoph Hellwig
On Mon, Sep 21, 2020 at 09:44:18AM +0300, Tony Lindgren wrote: > * Janusz Krzysztofik [200919 22:29]: > > Hi Tony, > > > > On Friday, September 18, 2020 7:49:33 A.M. CEST Tony Lindgren wrote: > > > * Christoph Hellwig [200917 17:37]: > > > > Switch the omap1510 platform ohci device to use

Re: [PATCH 1/4] ARM/omap1: switch to use dma_direct_set_offset for lbus DMA offsets

2020-09-21 Thread Tony Lindgren
* Janusz Krzysztofik [200919 22:29]: > Hi Tony, > > On Friday, September 18, 2020 7:49:33 A.M. CEST Tony Lindgren wrote: > > * Christoph Hellwig [200917 17:37]: > > > Switch the omap1510 platform ohci device to use dma_direct_set_offset > > > to set the DMA offset instead of using direct hooks

Re: a saner API for allocating DMA addressable pages v3

2020-09-21 Thread Christoph Hellwig
Any comments? Thomas: this should be identical to the git tree I gave you for mips testing, and you add your tested-by (and reviewd-by tags where applicable)? Helge: for parisc this should effectively be the same as the first version, but I've dropped the tested-by tags due to the reshuffle, and