[PATCH 0/5] iommu/smmuv3: Add IOMMUFD dirty tracking support for SMMUv3

Shameer Kolothum shameerali.kolothum.thodi at huawei.com
Tue Nov 28 01:49:35 PST 2023


Hi,

This is revisiting the earlier attempts [1, 2] to use SMMUv3 HTTU feature
for dirty page tracking. The Intel/AMD support is already mainline.

The code is now based on the new IOMMUFD APIs and is rebased on
Jason's SMMUv3 driver refactor series[3].

One major change is in patch #3 where the IO PTE walker code is modified
to take care of any iova size instead of iommu pgsize,

This is tested using a Qemu branch based on "vfio: Adopt iommufd" v4 series[4].

Basic sanity tests are done using an emulation setup and on a test hardware
setup. Block page split/merge(BBML) is not part of this series. I am planning
to send it separately.

Complete git branches are here,

https://github.com/hisilicon/kernel-dev/tree/smmuv3_newapi-dbm-arm
https://github.com/hisilicon/qemu/tree/iommufd_cdev_v4-dbm-arm

Please take a look and let me know your feedback.

Thanks,
Shameer
1. https://lore.kernel.org/lkml/20210413085457.25400-1-zhukeqian1@huawei.com/
2. https://lore.kernel.org/linux-iommu/20230518204650.14541-1-joao.m.martins@oracle.com/
3. https://lore.kernel.org/all/0-v2-de8b10590bf5+400-smmuv3_newapi_p1_jgg@nvidia.com/
4. https://lore.kernel.org/qemu-devel/20231102071302.1818071-1-zhenzhong.duan@intel.com/

Jean-Philippe Brucker (1):
  iommu/arm-smmu-v3: Add feature detection for HTTU

Joao Martins (2):
  iommu/arm-smmu-v3: Add set_dirty_tracking() support
  iommu/arm-smmu-v3: Enforce dirty tracking in domain attach/alloc

Keqian Zhu (1):
  iommu/arm-smmu-v3: Add read_and_clear_dirty() support

Kunkun Jiang (1):
  iommu/arm-smmu-v3: Enable HTTU for stage1 with io-pgtable mapping

 drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c | 115 +++++++++++++++++-
 drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.h |   8 ++
 drivers/iommu/io-pgtable-arm.c              | 125 +++++++++++++++++++-
 include/linux/io-pgtable.h                  |   4 +
 4 files changed, 249 insertions(+), 3 deletions(-)

-- 
2.34.1




More information about the linux-arm-kernel mailing list