public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/8] iommu: Remove IOMMU_DEV_FEAT_SVA/_IOPF
@ 2025-03-13  5:19 Lu Baolu
  2025-03-13  5:19 ` [PATCH v4 1/8] iommu/arm-smmu-v3: Put iopf enablement in the domain attach path Lu Baolu
                   ` (10 more replies)
  0 siblings, 11 replies; 23+ messages in thread
From: Lu Baolu @ 2025-03-13  5:19 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Jason Gunthorpe,
	Kevin Tian
  Cc: Dave Jiang, Vinod Koul, Fenghua Yu, Zhangfei Gao, Zhou Wang,
	iommu, linux-kernel, Lu Baolu, Jason Gunthorpe

The new method for driver fault reporting support relies on the domain
to specify a iopf_handler. The driver should detect this and setup the
HW when fault capable domains are attached.

Move SMMUv3 to use this method and have VT-D validate support during
attach so that all three fault capable drivers have a no-op FEAT_SVA and
_IOPF. Then remove them.

This was initiated by Jason. I'm following up to remove FEAT_IOPF and
further clean up.

The whole series is also available at github:
https://github.com/LuBaolu/intel-iommu/commits/iommu_no_feat-v4

Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>

Change log:
v4:
 - Refined arm_smmu_disable_iopf() to improve code clarity.
 - Separate patches for vt-d refactoring have been merged.
 - All patches are based on the latest iommu/next branch to prevent
   potential merge conflicts.

v3: https://lore.kernel.org/linux-iommu/20250228092631.3425464-1-baolu.lu@linux.intel.com/
 - Series has been tested by Zhangfei Gao with arm-smmu-v3 driver.
 - Refined some code according to Kevin's suggestions.
 - No functional change.

v2: https://lore.kernel.org/linux-iommu/20250224051627.2956304-1-baolu.lu@linux.intel.com/
 - Fix removing wrong nesting master_domain in
   arm_smmu_remove_master_domain().
 - Fix iopf enable/disable in iommufd mock driver for domain
   replacement.

v1: https://lore.kernel.org/linux-iommu/20250214061104.1959525-1-baolu.lu@linux.intel.com/

Jason Gunthorpe (2):
  iommu/arm-smmu-v3: Put iopf enablement in the domain attach path
  iommu: Remove IOMMU_DEV_FEAT_SVA

Lu Baolu (6):
  iommu/vt-d: Put iopf enablement in domain attach path
  iommufd/selftest: Put iopf enablement in domain attach path
  dmaengine: idxd: Remove unnecessary IOMMU_DEV_FEAT_IOPF
  uacce: Remove unnecessary IOMMU_DEV_FEAT_IOPF
  iommufd: Remove unnecessary IOMMU_DEV_FEAT_IOPF
  iommu: Remove iommu_dev_enable/disable_feature()

 drivers/accel/amdxdna/aie2_pci.c              |  13 +-
 drivers/dma/idxd/init.c                       |  43 +-----
 drivers/iommu/amd/iommu.c                     |  34 -----
 .../iommu/arm/arm-smmu-v3/arm-smmu-v3-sva.c   |  86 +----------
 drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c   | 137 ++++++++++--------
 drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.h   |  39 +----
 drivers/iommu/intel/iommu.c                   |  71 +++++----
 drivers/iommu/intel/iommu.h                   |  33 +++++
 drivers/iommu/intel/nested.c                  |  16 +-
 drivers/iommu/intel/svm.c                     |   9 +-
 drivers/iommu/iommu-sva.c                     |   3 -
 drivers/iommu/iommu.c                         |  32 ----
 drivers/iommu/iommufd/device.c                |  64 ++++----
 drivers/iommu/iommufd/fault.c                 |  45 ------
 drivers/iommu/iommufd/iommufd_private.h       |   5 -
 drivers/iommu/iommufd/selftest.c              |  64 ++++++--
 drivers/misc/uacce/uacce.c                    |  40 -----
 include/linux/iommu.h                         |  35 -----
 18 files changed, 272 insertions(+), 497 deletions(-)

-- 
2.43.0


^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2025-04-16  7:34 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-13  5:19 [PATCH v4 0/8] iommu: Remove IOMMU_DEV_FEAT_SVA/_IOPF Lu Baolu
2025-03-13  5:19 ` [PATCH v4 1/8] iommu/arm-smmu-v3: Put iopf enablement in the domain attach path Lu Baolu
2025-03-13  5:19 ` [PATCH v4 2/8] iommu: Remove IOMMU_DEV_FEAT_SVA Lu Baolu
2025-03-13  5:19 ` [PATCH v4 3/8] iommu/vt-d: Put iopf enablement in domain attach path Lu Baolu
2025-03-18  9:58   ` Yi Liu
2025-03-18 13:19     ` Baolu Lu
2025-03-13  5:19 ` [PATCH v4 4/8] iommufd/selftest: " Lu Baolu
2025-03-18 10:25   ` Yi Liu
2025-03-18 19:50   ` Nicolin Chen
2025-03-13  5:19 ` [PATCH v4 5/8] dmaengine: idxd: Remove unnecessary IOMMU_DEV_FEAT_IOPF Lu Baolu
2025-03-18 10:20   ` Yi Liu
2025-03-13  5:19 ` [PATCH v4 6/8] uacce: " Lu Baolu
2025-03-13  5:19 ` [PATCH v4 7/8] iommufd: " Lu Baolu
2025-03-13  5:19 ` [PATCH v4 8/8] iommu: Remove iommu_dev_enable/disable_feature() Lu Baolu
2025-03-13  9:51 ` [PATCH v4 0/8] iommu: Remove IOMMU_DEV_FEAT_SVA/_IOPF Zhangfei Gao
2025-03-13 10:57   ` Zhangfei Gao
2025-03-13 11:20     ` Baolu Lu
2025-03-13 11:37       ` Zhangfei Gao
2025-03-14  4:04         ` Zhangfei Gao
2025-03-14  8:11 ` Zhangfei Gao
2025-03-17 14:15   ` Jason Gunthorpe
2025-04-16  7:29 ` Zhangfei Gao
2025-04-16  7:33   ` Baolu Lu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox