Skip to content

iommu/amd: SVA Support (Part 4) - SVA and IOPF

Vasant Hegde linux-iommu 9 versions – Applied

Status from this message: Applied, thanks.

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v8 Latest15 patches 8 repliesApplied
  2. v715 patches 0 repliesSuperseded
  3. v615 patches 20 repliesSuperseded
Earlier versions · 6
VersionPostedPatchesRepliesStatus
v514 patches30 repliesSuperseded
v414 patches3 repliesSuperseded
v312 patches13 repliesSuperseded
v211 patches18 repliesSuperseded
v1 posting 2/210 patches19 repliesSuperseded
v1 posting 1/29 of 10 patches1 replySuperseded

Changes in v8 from the cover letter

- Rebased on top of v6.9-rc4
- Added "iommu.h" to ppr.c to fix build error

Patches in v8 Applied

#Subject and filesSizeRepliesApplied
1/15iommu/amd: Rename amd_iommu_v2_supported() as amd_iommu_pasid_supported()drivers/iommu/amd/amd_iommu.h drivers/iommu/amd/init.c+2 -20 replies
2/15iommu/amd: Introduce per device DTE update functiondrivers/iommu/amd/amd_iommu.h drivers/iommu/amd/iommu.c+19 -80 replies
3/15iommu/amd: Add support for enabling/disabling IOMMU featuresdrivers/iommu/amd/iommu.c+28 -00 replies
4/15iommu/amd: Move PPR-related functions into ppr.cdrivers/iommu/amd/Makefile drivers/iommu/amd/amd_iommu.h drivers/iommu/amd/init.c +2 more+139 -1140 replies
5/15iommu/amd: Fix PPR interrupt processing logicdrivers/iommu/amd/ppr.c+0 -40 replies
6/15iommu/amd: Introduce iommu_dev_data.max_pasidsdrivers/iommu/amd/amd_iommu_types.h drivers/iommu/amd/iommu.c+13 -00 replies
7/15iommu/amd: Setup GCR3 table in advance if domain is SVA capabledrivers/iommu/amd/iommu.c+71 -157 replies
8/15iommu/amd: Enable PCI features based on attached domain capabilitydrivers/iommu/amd/amd_iommu.h drivers/iommu/amd/iommu.c+14 -120 replies
9/15iommu/amd: Define per-IOMMU iopf_queuedrivers/iommu/amd/amd_iommu.h drivers/iommu/amd/amd_iommu_types.h drivers/iommu/amd/init.c +1 more+55 -20 replies
10/15iommu/amd: Add support for page responsedrivers/iommu/amd/amd_iommu.h drivers/iommu/amd/iommu.c drivers/iommu/amd/ppr.c+13 -60 replies
11/15iommu/amd: Add IO page fault notifier handlerdrivers/iommu/amd/amd_iommu_types.h drivers/iommu/amd/ppr.c+107 -10 replies
12/15iommu/amd: Add support for enable/disable IOPFdrivers/iommu/amd/Kconfig drivers/iommu/amd/amd_iommu.h drivers/iommu/amd/iommu.c +1 more+77 -80 replies
13/15iommu/amd: Initial SVA support for AMD IOMMUdrivers/iommu/amd/Kconfig drivers/iommu/amd/Makefile drivers/iommu/amd/amd_iommu.h +3 more+156 -60 replies
14/15iommu: Add ops->domain_alloc_sva()drivers/iommu/iommu-sva.c include/linux/iommu.h+14 -50 replies
15/15iommu/amd: Add SVA domain supportdrivers/iommu/amd/amd_iommu.h drivers/iommu/amd/amd_iommu_types.h drivers/iommu/amd/iommu.c +1 more+93 -30 replies

Reviews trailers per patch

All 15 patches have a Reviewed-by or Acked-by.

PatchJason GunthorpeTina ZhangKlara Modin
1/15R-b
2/15R-b
3/15R-b
4/15R-b
5/15R-b
6/15R-b
7/15R-b T-b
8/15R-b
9/15R-b
10/15R-b
11/15R-b
12/15R-b
13/15R-b
14/15R-b
15/15R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v8 thread

Cover letter [PATCH v8 00/15] iommu/amd: SVA Support (Part 4) - SVA and IOPF

This is part 4 of the 4-part series to introduce Share Virtual Address (SVA) support for devices, which can support PCI ATS, PASID and PRI capabilities. These devices are referred to as SVA-capable devices in this series.

It contains the following enhancements:

* Patch 1 - 3:
Rename, add support to enable/disable features, update DTE etc.

* Patch 4 - 12:
Add IOPF support

* Patch 13 - 15:
Introduce SVA support

This patch series is based on top of v6.9-rc4.

This is also available at github :
https://github.com/AMDESE/linux-iommu/tree/iommu_sva_part4_v8_v6.9_rc4

Thanks everyone who reviewed previous version and provided valuable feedbacks.

Changes from v7 -> v8:
- Rebased on top of v6.9-rc4
- Added "iommu.h" to ppr.c to fix build error

v7: https://lore.kernel.org/linux-iommu/[email protected]/T/#t

Changes from v6 -> v7:
- Rebased on top of iommu/next
- Trivial white space fix
- Added Reviewed-by tag

v6: https://lore.kernel.org/linux-iommu/[email protected]/T/#t

Changes from v5 -> v6:
- Rebased on top of SVA Part3 v7
- Reorganized, added few patches
- Patch to track per device max PASIDs
- Patch to setup GCR3 table for SVA capable domain
- Patch to enable PASID/PRI only when domain is capable of PRI support
- Dropped below patches as they are not needed anymore
- iommu/amd: Add GCR3 [un]initialization function
- iommu/amd: Add support for add/remove device for IOPF
- Rework sev[/remove_dev]_dev_pasid() functions
- Dropped late gcr3 setup patch

v5: https://lore.kernel.org/linux-iommu/[email protected]/T/#t

Changes from v4 -> v5:
- Rebased on top of v6.7-rc8 + SVA Part3 patches
- Few minor improvements like renaming structure name for better, introducing macros, etc

v4: https://lore.kernel.org/linux-iommu/[email protected]/

Changes from v3 -> v4:
- Moved amd_iommu_dev_update_dte() after set/clear_dte() so that we can avoid forward declaration
- Dropped "iommu/amd: Do not override PASID entry in GCR3 table"
- Added patch to fix PPR interrupt processing logic
- Renamed enable_iommus_v2() -> enable_iommus_ppr()
- Added ops->domain_alloc_sva()
- Added domain_alloc_sva() support and reorganize SVA patches
- In error path iommu_call_iopf_notifier() calls amd_iommu_complete_ppr() instead of amd_iommu_page_response()

v3: https://lore.kernel.org/linux-iommu/[email protected]/T/#t

Changes from v2 -> v3:
- Rename sva.c -> pasid.c
- Changed amd_iommu_sva_supported() -> amd_iommu_pasid_supported()
- Added patch to update/flush DTE
- Rework part of SVA support
- Move IOPF enablement to PASID bind time

v2: https://lore.kernel.org/linux-iommu/[email protected]/T/#u

Changes from v1 -> v2:
- Added new patch to fix PASID override issue in GCR3 table
- Complete rework of SVA code on top of Tina's SVA series.
- Rework SVA enable code
- Reworked IOPF handler code on top of Baolu's IOPF improvement series.

v1: https://lore.kernel.org/linux-iommu/[email protected]/T/#t

Jason Gunthorpe (1):
iommu: Add ops->domain_alloc_sva()

Suravee Suthikulpanit (3):
iommu/amd: Move PPR-related functions into ppr.c iommu/amd: Define per-IOMMU iopf_queue iommu/amd: Add support for page response

Vasant Hegde (9):
iommu/amd: Rename amd_iommu_v2_supported() as amd_iommu_pasid_supported() iommu/amd: Introduce per device DTE update function iommu/amd: Fix PPR interrupt processing logic
iommu/amd: Introduce iommu_dev_data.max_pasids
iommu/amd: Setup GCR3 table in advance if domain is SVA capable iommu/amd: Enable PCI features based on attached domain capability iommu/amd: Add support for enable/disable IOPF
iommu/amd: Initial SVA support for AMD IOMMU
iommu/amd: Add SVA domain support

Wei Huang (2):
iommu/amd: Add support for enabling/disabling IOMMU features iommu/amd: Add IO page fault notifier handler

 drivers/iommu/amd/Kconfig           |   2 +
 drivers/iommu/amd/Makefile          |   2 +-
 drivers/iommu/amd/amd_iommu.h       |  49 ++++-
 drivers/iommu/amd/amd_iommu_types.h |  33 ++++
 drivers/iommu/amd/init.c            |  85 +++------
 drivers/iommu/amd/iommu.c           | 283 +++++++++++++++++----------
 drivers/iommu/amd/pasid.c           | 202 ++++++++++++++++++++
 drivers/iommu/amd/ppr.c             | 286 ++++++++++++++++++++++++++++
 drivers/iommu/iommu-sva.c           |  16 +-
 include/linux/iommu.h               |   3 +
 10 files changed, 788 insertions(+), 173 deletions(-)
 create mode 100644 drivers/iommu/amd/pasid.c
 create mode 100644 drivers/iommu/amd/ppr.c
Signature · 1 line
2.31.1