linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH RFC v1 0/3] Add set_rid_user and unset_rid_user support
@ 2023-04-06  6:25 Nicolin Chen
  2023-04-06  6:25 ` [PATCH RFC v1 1/3] iommu: Add set/unset_rid_user ops Nicolin Chen
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Nicolin Chen @ 2023-04-06  6:25 UTC (permalink / raw)
  To: jgg, robin.murphy, kevin.tian
  Cc: eric.auger, yi.l.liu, baolu.lu, will, joro,
	shameerali.kolothum.thodi, jean-philippe, linux-arm-kernel, iommu,
	linux-kernel

This is a pair of new uAPI/ops for user space to set a user space virtual
Request ID for a passthrough PCI device, down to the IOMMU driver. This's
primarily used by SMMUv3 driver for now, to link the vSID and the pSID of
a device behind the SMMU. The link (lookup table) will be used to verify
an ATC_INV command from the user space for that device, and then replace
the virtual SID with the corresponding physical SID.

This is a RFC series, since I am not confident at all about the uAPI/ops
namings. Hopefully we can finalize this small series soon and include it
in the next version of SMMUv3 nesting series.

This series is available on Github:
https://github.com/nicolinc/iommufd/commits/set_rid_user-rfc-v1

Thanks!
Nicolin

Nicolin Chen (3):
  iommu: Add set/unset_rid_user ops
  iommufd: Add IOMMUFD_CMD_DEVICE_SET_RID and
    IOMMUFD_CMD_DEVICE_UNSET_RID
  iommu/arm-smmu-v3: Implement set_rid_user and unset_rid_user

 drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c | 45 +++++++++++++++++++++
 drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.h |  2 +
 drivers/iommu/iommufd/device.c              | 39 ++++++++++++++++++
 drivers/iommu/iommufd/iommufd_private.h     |  2 +
 drivers/iommu/iommufd/main.c                |  4 ++
 include/linux/iommu.h                       |  4 ++
 include/uapi/linux/iommufd.h                | 31 ++++++++++++++
 7 files changed, 127 insertions(+)

-- 
2.40.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

end of thread, other threads:[~2023-04-06  6:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-04-06  6:25 [PATCH RFC v1 0/3] Add set_rid_user and unset_rid_user support Nicolin Chen
2023-04-06  6:25 ` [PATCH RFC v1 1/3] iommu: Add set/unset_rid_user ops Nicolin Chen
2023-04-06  6:25 ` [PATCH RFC v1 2/3] iommufd: Add IOMMUFD_CMD_DEVICE_SET_RID and IOMMUFD_CMD_DEVICE_UNSET_RID Nicolin Chen
2023-04-06  6:25 ` [PATCH RFC v1 3/3] iommu/arm-smmu-v3: Implement set_rid_user and unset_rid_user Nicolin Chen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).