Skip to content

iommu: Make core iommu-groups code more generic

Joerg Roedel linux-iommu lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest8 patches 6 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/8iommu: Revive device_group iommu-ops call-backdrivers/iommu/iommu.c include/linux/iommu.h+7 -40 replies
2/8iommu: Export and rename iommu_group_get_for_pci_dev()drivers/iommu/iommu.c include/linux/iommu.h+9 -20 replies
3/8iommu: Add generic_device_group() functiondrivers/iommu/iommu.c include/linux/iommu.h+17 -00 replies
4/8iommu: Add device_group call-back to x86 iommu driversdrivers/iommu/amd_iommu.c drivers/iommu/intel-iommu.c+2 -00 replies
5/8iommu/fsl: Convert to device_group call-backdrivers/iommu/fsl_pamu_domain.c+16 -250 replies
6/8iommu/arm-smmu: Switch to device_group call-backdrivers/iommu/arm-smmu-v3.c drivers/iommu/arm-smmu.c+47 -310 replies
7/8iommu: Remove is_pci_dev() fall-back from iommu_group_get_for_devdrivers/iommu/iommu.c+0 -20 replies
8/8iommu: Move default domain allocation to iommu_group_get_for_dev()drivers/iommu/iommu.c+10 -82 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/8] iommu: Make core iommu-groups code more generic

Hi,

this patch-set makes the core code for managing iommu-groups more generic by lifting its dependencies on PCI. The core function iommu_group_get_for_dev() had a hard dev_is_pci() check in it, followed by PCI specific handling.

This check is removed in favour of the the revived device_group() iommu-ops call-back. With this call-back an IOMMU driver can define how the devices it manages are grouped together. Two functions, one generic and one for PCI devices, are provided that can be uses as a device_group() call-back or might be used in such a call-back.

The existing drivers making use of the iommu_group_get_for_dev() function are converted to this call-back.

Joerg

Joerg Roedel (8):
iommu: Revive device_group iommu-ops call-back
iommu: Export and rename iommu_group_get_for_pci_dev()
iommu: Add generic_device_group() function
iommu: Add device_group call-back to x86 iommu drivers iommu/fsl: Convert to device_group call-back iommu/arm-smmu: Switch to device_group call-back
iommu: Remove is_pci_dev() fall-back from iommu_group_get_for_dev
iommu: Move default domain allocation to iommu_group_get_for_dev()

 drivers/iommu/amd_iommu.c       |  1 +
 drivers/iommu/arm-smmu-v3.c     |  1 +
 drivers/iommu/arm-smmu.c        | 77 ++++++++++++++++++++++++-----------------
 drivers/iommu/fsl_pamu_domain.c | 41 +++++++++-------------
 drivers/iommu/intel-iommu.c     |  1 +
 drivers/iommu/iommu.c           | 46 +++++++++++++++++-------
 include/linux/iommu.h           |  7 +++-
 7 files changed, 105 insertions(+), 69 deletions(-)
Signature · 1 line
1.9.1