iommu/arm-smmu-v3: Add an ops indirection to the STE code
authorJason Gunthorpe <jgg@nvidia.com>
Tue, 30 Apr 2024 17:21:33 +0000 (14:21 -0300)
committerWill Deacon <will@kernel.org>
Wed, 1 May 2024 14:33:51 +0000 (15:33 +0100)
commitde31c355541286aa4c938c982dfcafbf062fcb93
treec2d3bd54103470b397d7b647988c072435c0e249
parent0928fc15f31553c7acb8117b0609799fc0f22fa5
iommu/arm-smmu-v3: Add an ops indirection to the STE code

Prepare to put the CD code into the same mechanism. Add an ops indirection
around all the STE specific code and make the worker functions independent
of the entry content being processed.

get_used and sync ops are provided to hook the correct code.

Signed-off-by: Michael Shavit <mshavit@google.com>
Reviewed-by: Michael Shavit <mshavit@google.com>
Reviewed-by: Nicolin Chen <nicolinc@nvidia.com>
Tested-by: Nicolin Chen <nicolinc@nvidia.com>
Tested-by: Shameer Kolothum <shameerali.kolothum.thodi@huawei.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Link: https://lore.kernel.org/r/1-v9-5040dc602008+177d7-smmuv3_newapi_p2_jgg@nvidia.com
Signed-off-by: Will Deacon <will@kernel.org>
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c