Re: [Freedreno] [PATCH 16/17] iommu: remove DOMAIN_ATTR_IO_PGTABLE_CFG

2021-03-04 Thread Rob Clark
On Thu, Mar 4, 2021 at 7:48 AM Robin Murphy wrote: > > On 2021-03-01 08:42, Christoph Hellwig wrote: > > Signed-off-by: Christoph Hellwig > > Moreso than the previous patch, where the feature is at least relatively > generic (note that there's a bunch of in-flight development around >

Re: [RFC PATCH 15/18] cgroup: Introduce ioasids controller

2021-03-04 Thread Jacob Pan
Hi Jason, On Thu, 4 Mar 2021 15:02:53 -0400, Jason Gunthorpe wrote: > On Thu, Mar 04, 2021 at 11:01:44AM -0800, Jacob Pan wrote: > > > > For something like qemu I'd expect to put the qemu process in a cgroup > > > with 1 PASID. Who cares what qemu uses the PASID for, or how it was > > >

Re: [RFC PATCH 15/18] cgroup: Introduce ioasids controller

2021-03-04 Thread Jason Gunthorpe
On Thu, Mar 04, 2021 at 11:01:44AM -0800, Jacob Pan wrote: > > For something like qemu I'd expect to put the qemu process in a cgroup > > with 1 PASID. Who cares what qemu uses the PASID for, or how it was > > allocated? > > For vSVA, we will need one PASID per guest process. But that is up to

Re: [RFC PATCH 15/18] cgroup: Introduce ioasids controller

2021-03-04 Thread Jacob Pan
Hi Jason, On Thu, 4 Mar 2021 13:54:02 -0400, Jason Gunthorpe wrote: > On Thu, Mar 04, 2021 at 09:46:03AM -0800, Jacob Pan wrote: > > > Right, I was assuming have three use cases of IOASIDs: > > 1. host supervisor SVA (not a concern, just one init_mm to bind) > > 2. host user SVA, either one

Re: [RFC PATCH 15/18] cgroup: Introduce ioasids controller

2021-03-04 Thread Jason Gunthorpe
On Thu, Mar 04, 2021 at 09:46:03AM -0800, Jacob Pan wrote: > Right, I was assuming have three use cases of IOASIDs: > 1. host supervisor SVA (not a concern, just one init_mm to bind) > 2. host user SVA, either one IOASID per process or perhaps some private > IOASID for private address space > 3.

Re: [RFC PATCH 15/18] cgroup: Introduce ioasids controller

2021-03-04 Thread Jacob Pan
Hi Jean-Philippe, On Thu, 4 Mar 2021 10:49:37 +0100, Jean-Philippe Brucker wrote: > On Wed, Mar 03, 2021 at 04:02:05PM -0800, Jacob Pan wrote: > > Hi Jacob, > > > > On Wed, 3 Mar 2021 13:17:26 -0800, Jacob Pan > > wrote: > > > > > Hi Tejun, > > > > > > On Wed, 3 Mar 2021 10:44:28 -0500,

Re: [RFC PATCH 4/5] iommu/arm-smmu-v3: Use pinned VMID for NESTED stage with BTM

2021-03-04 Thread Jean-Philippe Brucker
Hi Shameer, On Mon, Feb 22, 2021 at 03:53:37PM +, Shameer Kolothum wrote: > If the SMMU supports BTM and the device belongs to NESTED domain > with shared pasid table, we need to use the VMID allocated by the > KVM for the s2 configuration. Hence, request a pinned VMID from KVM. > >

Re: CAAM: kernel BUG at drivers/crypto/caam/jr.c:230! (and dma-coherent query)

2021-03-04 Thread Robin Murphy
On 2021-03-03 16:40, Horia Geantă wrote: On 3/3/2021 4:57 PM, Sascha Hauer wrote: On Wed, Mar 03, 2021 at 12:26:32PM +0200, Horia Geantă wrote: Adding some people in the loop, maybe they could help in understanding why lack of "dma-coherent" property for a HW-coherent device could lead to

Re: [PATCH 16/17] iommu: remove DOMAIN_ATTR_IO_PGTABLE_CFG

2021-03-04 Thread Robin Murphy
On 2021-03-01 08:42, Christoph Hellwig wrote: Signed-off-by: Christoph Hellwig Moreso than the previous patch, where the feature is at least relatively generic (note that there's a bunch of in-flight development around DOMAIN_ATTR_NESTING), I'm really not convinced that it's beneficial to

Re: [PATCH 14/17] iommu: remove DOMAIN_ATTR_DMA_USE_FLUSH_QUEUE

2021-03-04 Thread Robin Murphy
On 2021-03-01 08:42, Christoph Hellwig wrote: Use explicit methods for setting and querying the information instead. Now that everyone's using iommu-dma, is there any point in bouncing this through the drivers at all? Seems like it would make more sense for the x86 drivers to reflect their

Re: [Patch v8 04/10] vfio/type1: Support binding guest page tables to PASID

2021-03-04 Thread Jason Gunthorpe
On Thu, Mar 04, 2021 at 07:20:22AM +, Liu, Yi L wrote: > > > However, IOMMU is a system device which has little value to be exposed > > to > > > the userspace. Not to mention the device-IOMMU affinity/topology. VFIO > > > nicely abstracts IOMMU from the userspace, why do we want to reverse > >

Re: [PATCH] iommu/vt-d: Fix status code for Allocate/Free PASID command

2021-03-04 Thread Joerg Roedel
On Sat, Feb 27, 2021 at 03:39:09PM +0800, Zenghui Yu wrote: > As per Intel vt-d spec, Rev 3.0 (section 10.4.45 "Virtual Command Response > Register"), the status code of "No PASID available" error in response to > the Allocate PASID command is 2, not 1. The same for "Invalid PASID" error > in

Re: [PATCH] iommu/tegra-smmu: Fix mc errors on tegra124-nyan

2021-03-04 Thread Joerg Roedel
On Thu, Feb 18, 2021 at 02:07:02PM -0800, Nicolin Chen wrote: > drivers/iommu/tegra-smmu.c | 72 +- > 1 file changed, 71 insertions(+), 1 deletion(-) Applied for v5.12, thanks. ___ iommu mailing list

Re: [PATCH 2/5] iommu/vt-d: Remove WO permissions on second-level paging entries

2021-03-04 Thread Joerg Roedel
On Thu, Feb 25, 2021 at 02:26:51PM +0800, Lu Baolu wrote: > When the first level page table is used for IOVA translation, it only > supports Read-Only and Read-Write permissions. The Write-Only permission > is not supported as the PRESENT bit (implying Read permission) should > always set. When

Re: [PATCH] iommu/amd: Fix sleeping in atomic in increase_address_space()

2021-03-04 Thread Joerg Roedel
On Wed, Feb 17, 2021 at 06:10:02PM +, Will Deacon wrote: > > drivers/iommu/amd/iommu.c | 10 ++ > > 1 file changed, 6 insertions(+), 4 deletions(-) > > Acked-by: Will Deacon Applied for v5.12, thanks. There were some conflicts which I resolved, can you please check the result,

Re: cleanup unused or almost unused IOMMU APIs and the FSL PAMU driver

2021-03-04 Thread Joerg Roedel
On Mon, Mar 01, 2021 at 09:42:40AM +0100, Christoph Hellwig wrote: > Diffstat: > arch/powerpc/include/asm/fsl_pamu_stash.h | 12 > drivers/gpu/drm/msm/adreno/adreno_gpu.c |2 > drivers/iommu/amd/iommu.c | 23 > drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c | 85

Re: [RFC PATCH 15/18] cgroup: Introduce ioasids controller

2021-03-04 Thread Jean-Philippe Brucker
On Wed, Mar 03, 2021 at 04:02:05PM -0800, Jacob Pan wrote: > Hi Jacob, > > On Wed, 3 Mar 2021 13:17:26 -0800, Jacob Pan > wrote: > > > Hi Tejun, > > > > On Wed, 3 Mar 2021 10:44:28 -0500, Tejun Heo wrote: > > > > > On Sat, Feb 27, 2021 at 02:01:23PM -0800, Jacob Pan wrote: > > > > IOASIDs

Re: [PATCH v3 1/2] dt-bindings: iommu: add bindings for sprd iommu

2021-03-04 Thread Chunyan Zhang
Hi Robin, On Tue, 16 Feb 2021 at 23:10, Robin Murphy wrote: > > >>> > >>> On Wed, Feb 03, 2021 at 05:07:26PM +0800, Chunyan Zhang wrote: > From: Chunyan Zhang > > This iommu module can be used by Unisoc's multimedia devices, such as > display, Image codec(jpeg) and a few

Re: [PATCH 1/4] iommu/vt-d: Enable write protect for supervisor SVM

2021-03-04 Thread kernel test robot
' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Jacob-Pan/Misc-vSVA-fixes-for-VT-d/20210219-141141 base: https://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git next config: ia64-randconfig-r023-20210304 (attached as .config