Skip to content

iommu/amd: Use generic IOVA allocator

Joerg Roedel linux-iommu lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest20 patches 9 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/20iommu: Add apply_dm_region call-back to iommu-opsdrivers/iommu/iommu.c include/linux/iommu.h+6 -00 replies
2/20iommu/amd: Select IOMMU_IOVA for AMD IOMMUdrivers/iommu/Kconfig+1 -00 replies
3/20iommu/amd: Allocate iova_domain for dma_ops_domaindrivers/iommu/amd_iommu.c+19 -10 replies
4/20iommu/amd: Create a list of reserved iova addressesdrivers/iommu/amd_iommu.c+69 -00 replies
5/20iommu/amd: Implement apply_dm_region call-backdrivers/iommu/amd_iommu.c+15 -00 replies
6/20iommu/amd: Pass gfp-flags to iommu_map_page()drivers/iommu/amd_iommu.c+4 -30 replies
7/20iommu/amd: Remove special mapping code for dma_ops pathdrivers/iommu/amd_iommu.c+14 -934 replies
8/20iommu/amd: Make use of the generic IOVA allocatordrivers/iommu/amd_iommu.c+26 -1570 replies
9/20iommu/amd: Remove other remains of old address allocatordrivers/iommu/amd_iommu.c+5 -3000 replies
10/20iommu/amd: Remove align-parameter from __map_single()drivers/iommu/amd_iommu.c+3 -100 replies
11/20iommu/amd: Set up data structures for flush queuedrivers/iommu/amd_iommu.c+39 -10 replies
12/20iommu/amd: Allow NULL pointer parameter for domain_flush_complete()drivers/iommu/amd_iommu.c+1 -10 replies
13/20iommu/amd: Implement flush queuedrivers/iommu/amd_iommu.c+67 -40 replies
14/20iommu/amd: Implement timeout to flush unmap queuesdrivers/iommu/amd_iommu.c+28 -00 replies
15/20iommu/amd: Introduce dir2prot() helperdrivers/iommu/amd_iommu.c+13 -70 replies
16/20iommu/amd: Optimize map_sg and unmap_sgdrivers/iommu/amd_iommu.c+52 -254 replies
17/20iommu/amd: Use dev_data->domain in get_domain()drivers/iommu/amd_iommu.c+1 -60 replies
18/20iommu/amd: Handle IOMMU_DOMAIN_DMA in ops->domain_free call-backdrivers/iommu/amd_iommu.c+17 -80 replies
19/20iommu/amd: Flush iova queue before releasing dma_ops_domaindrivers/iommu/amd_iommu.c+14 -30 replies
20/20iommu/amd: Use container_of to get dma_ops_domaindrivers/iommu/amd_iommu.c drivers/iommu/amd_iommu_types.h+27 -120 replies

Reviews trailers per patch

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

Read the v1 thread

Cover letter [PATCH 00/20] iommu/amd: Use generic IOVA allocator

Hi,

here is a patch-set to make the AMD IOMMU driver use the generic IOVA allocator, which is already used in the Intel VT-d driver and a few other places.

The main reason for the conversion is to make the driver benefit from the recent scalability improvements to the IOVA code. Some of these improvements happened in the Intel VT-d driver, these are not re-used but, for now, re-implemented.

This leaves more room for merging things together into common code for the future.

The allocator that was previously used will be removed with these patches.

Please review.

Thanks,

Joerg

Joerg Roedel (20):
iommu: Add apply_dm_region call-back to iommu-ops iommu/amd: Select IOMMU_IOVA for AMD IOMMU
iommu/amd: Allocate iova_domain for dma_ops_domain iommu/amd: Create a list of reserved iova addresses iommu/amd: Implement apply_dm_region call-back iommu/amd: Pass gfp-flags to iommu_map_page()
iommu/amd: Remove special mapping code for dma_ops path iommu/amd: Make use of the generic IOVA allocator iommu/amd: Remove other remains of old address allocator iommu/amd: Remove align-parameter from __map_single() iommu/amd: Set up data structures for flush queue iommu/amd: Allow NULL pointer parameter for domain_flush_complete() iommu/amd: Implement flush queue
iommu/amd: Implement timeout to flush unmap queues iommu/amd: Introduce dir2prot() helper
iommu/amd: Optimize map_sg and unmap_sg
iommu/amd: Use dev_data->domain in get_domain() iommu/amd: Handle IOMMU_DOMAIN_DMA in ops->domain_free call-back iommu/amd: Flush iova queue before releasing dma_ops_domain iommu/amd: Use container_of to get dma_ops_domain

 drivers/iommu/Kconfig           |   1 +
 drivers/iommu/amd_iommu.c       | 976 ++++++++++++++++------------------------
 drivers/iommu/amd_iommu_types.h |   1 -
 drivers/iommu/iommu.c           |   3 +
 include/linux/iommu.h           |   3 +
 5 files changed, 387 insertions(+), 597 deletions(-)
Signature · 1 line
1.9.1