ly
indicates the allocation of a paging domain for DMA managed by a kernel
driver. The new interface takes a device pointer as its parameter, that
better aligns with the current iommu subsystem.
Signed-off-by: Lu Baolu
---
include/linux/iommu.h | 6 ++
drivers/iommu/iommu.c | 20 +
Replace iommu_domain_alloc() with iommu_paging_domain_alloc().
Signed-off-by: Lu Baolu
---
drivers/vfio/vfio_iommu_type1.c | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/vfio/vfio_iommu_type1.c b/drivers/vfio/vfio_iommu_type1.c
index 3a0218171cfa
driver, make the code compatible with the no-IOMMU
case.
- Various cleanups and refinements.
v1:
https://lore.kernel.org/linux-iommu/20240529053250.91284-1-baolu...@linux.intel.com/
Lu Baolu (20):
iommu: Add iommu_paging_domain_alloc() interface
iommufd: Use iommu_paging_domain_alloc
Replace iommu_domain_alloc() with iommu_paging_domain_alloc().
Signed-off-by: Lu Baolu
---
drivers/vhost/vdpa.c | 14 ++
1 file changed, 6 insertions(+), 8 deletions(-)
diff --git a/drivers/vhost/vdpa.c b/drivers/vhost/vdpa.c
index 63a53680a85c..e31ec9ebc4ce 100644
--- a/drivers
The domain allocated in msm_iommu_new() is for the @dev. Replace
iommu_domain_alloc() with iommu_paging_domain_alloc() to make it explicit.
Signed-off-by: Lu Baolu
Acked-by: Dmitry Baryshkov
---
drivers/gpu/drm/msm/msm_iommu.c | 7 +--
1 file changed, 5 insertions(+), 2 deletions(-)
diff
An iommu domain is allocated in host1x_iommu_attach() and is attached to
host->dev. Use iommu_paging_domain_alloc() to make it explicit.
Signed-off-by: Lu Baolu
---
drivers/gpu/host1x/dev.c | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/host1x/dev.
An iommu domain is allocated in tegra_vde_iommu_init() and is attached to
vde->dev. Use iommu_paging_domain_alloc() to make it explicit.
Signed-off-by: Lu Baolu
---
drivers/media/platform/nvidia/tegra-vde/iommu.c | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/driv
An iommu domain is allocated in venus_firmware_init() and is attached to
core->fw.dev in the same function. Use iommu_paging_domain_alloc() to
make it explicit.
Signed-off-by: Lu Baolu
---
drivers/media/platform/qcom/venus/firmware.c | 6 +++---
1 file changed, 3 insertions(+), 3 deleti
An iommu domain is allocated in ath11k_ahb_fw_resources_init() and is
attached to ab_ahb->fw.dev in the same function.
Use iommu_paging_domain_alloc() to make it explicit.
Signed-off-by: Lu Baolu
Acked-by: Jeff Johnson
---
drivers/net/wireless/ath/ath11k/ahb.c | 6 +++---
1 file changed
An iommu domain is allocated in portal_set_cpu() and is attached to
pcfg->dev in the same function.
Use iommu_paging_domain_alloc() to make it explicit.
Signed-off-by: Lu Baolu
---
drivers/soc/fsl/qbman/qman_portal.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --gi
The domain_alloc_user operation is currently implemented by allocating a
paging domain using iommu_domain_alloc(). This is because it needs to fully
initialize the domain before return. Add a helper to do this to avoid using
iommu_domain_alloc().
Signed-off-by: Lu Baolu
---
drivers/iommu/intel
Signed-off-by: Lu Baolu
---
arch/arm/include/asm/dma-iommu.h | 2 +-
arch/arm/mm/dma-mapping.c| 8
drivers/gpu/drm/exynos/exynos_drm_dma.c | 2 +-
drivers/iommu/ipmmu-vmsa.c | 3 +--
drivers/iommu/mtk_iommu_v1.c | 3 +--
drivers/media
Since arm_iommu_create_mapping() now accepts the device, let's replace
iommu_domain_alloc() with iommu_paging_domain_alloc() to retire the former.
Signed-off-by: Lu Baolu
---
arch/arm/mm/dma-mapping.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/arch/arm/m
Commit <421be3ee36a4> ("drm/rockchip: Refactor IOMMU initialisation") has
refactored rockchip_drm_init_iommu() to pass a device that the domain is
allocated for. Replace iommu_domain_alloc() with
iommu_paging_domain_alloc() to retire the former.
Signed-off-by: Lu Baolu
---
bsystem prevents domains
allocated by one iommu driver from being attached to devices managed
by any different iommu driver.
Signed-off-by: Lu Baolu
---
drivers/gpu/drm/tegra/drm.c | 34 +-
1 file changed, 25 insertions(+), 9 deletions(-)
diff --git a/drivers/gpu/d
The iommu_present() interface is no longer used in the tree anymore.
Remove it to avoid dead code.
Signed-off-by: Lu Baolu
---
include/linux/iommu.h | 6 --
drivers/iommu/iommu.c | 25 -
2 files changed, 31 deletions(-)
diff --git a/include/linux/iommu.h b/include
The iommu_domain_alloc() interface is no longer used in the tree anymore.
Remove it to avoid dead code.
There is increasing demand for supporting multiple IOMMU drivers, and this
is the last bus-based thing standing in the way of that.
Signed-off-by: Lu Baolu
---
include/linux/iommu.h | 6
An iommu domain is allocated in rproc_enable_iommu() and is attached to
rproc->dev.parent in the same function.
Use iommu_paging_domain_alloc() to make it explicit.
Signed-off-by: Lu Baolu
---
drivers/remoteproc/remoteproc_core.c | 6 +++---
1 file changed, 3 insertions(+), 3 deleti
In nvkm_device_tegra_probe_iommu(), a paging domain is allocated for @dev
and attached to it on success. Use iommu_paging_domain_alloc() to make it
explicit.
Signed-off-by: Lu Baolu
---
drivers/gpu/drm/nouveau/nvkm/engine/device/tegra.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions
If the iommu driver doesn't implement its domain_alloc_user callback,
iommufd_hwpt_paging_alloc() rolls back to allocate an iommu paging domain.
Replace iommu_domain_alloc() with iommu_user_domain_alloc() to pass the
device pointer along the path.
Signed-off-by: Lu Baolu
---
drivers/
usnic_uiom_alloc_pd() allocates a paging domain for a given device.
In this case, iommu_domain_alloc(dev->bus) is equivalent to
iommu_paging_domain_alloc(dev). Replace it as iommu_domain_alloc()
has been deprecated.
Signed-off-by: Lu Baolu
Acked-by: Jason Gunthorpe
---
drivers/infiniband
An iommu domain is allocated in ath10k_fw_init() and is attached to
ar_snoc->fw.dev in the same function. Use iommu_paging_domain_alloc() to
make it explicit.
Signed-off-by: Lu Baolu
Acked-by: Jeff Johnson
---
drivers/net/wireless/ath/ath10k/snoc.c | 6 +++---
1 file changed, 3 inserti
rious cleanups and refinements.
v1:
https://lore.kernel.org/linux-iommu/20240529053250.91284-1-baolu...@linux.intel.com/
Lu Baolu (4):
remoteproc: Use iommu_paging_domain_alloc()
media: nvidia: tegra: Use iommu_paging_domain_alloc()
drm/nouveau/tegra: Use iommu_paging_domain_alloc()
iommu: R
The iommu_domain_alloc() interface is no longer used in the tree anymore.
Remove it to avoid dead code.
There is increasing demand for supporting multiple IOMMU drivers, and this
is the last bus-based thing standing in the way of that.
Signed-off-by: Lu Baolu
Reviewed-by: Jason Gunthorpe
In nvkm_device_tegra_probe_iommu(), a paging domain is allocated for @dev
and attached to it on success. Use iommu_paging_domain_alloc() to make it
explicit.
Signed-off-by: Lu Baolu
Acked-by: Thierry Reding
Reviewed-by: Lyude Paul
---
drivers/gpu/drm/nouveau/nvkm/engine/device/tegra.c | 4
An iommu domain is allocated in tegra_vde_iommu_init() and is attached to
vde->dev. Use iommu_paging_domain_alloc() to make it explicit.
Signed-off-by: Lu Baolu
Reviewed-by: Jason Gunthorpe
Acked-by: Thierry Reding
---
drivers/media/platform/nvidia/tegra-vde/iommu.c | 7 ---
1 f
An iommu domain is allocated in rproc_enable_iommu() and is attached to
rproc->dev.parent in the same function.
Use iommu_paging_domain_alloc() to make it explicit.
Signed-off-by: Lu Baolu
Reviewed-by: Jason Gunthorpe
Reviewed-by: Mathieu Poirier
Acked-by: Beleswar Padhi
---
driv
27 matches
Mail list logo