iommu/arm-smmu-v3: Add a type for the STE
authorJason Gunthorpe <jgg@nvidia.com>
Tue, 5 Dec 2023 19:14:33 +0000 (15:14 -0400)
committerWill Deacon <will@kernel.org>
Wed, 13 Dec 2023 12:32:19 +0000 (12:32 +0000)
commit57b89048874c9edd4a17f34c126b4a4188b7b444
tree76d445250be653d7f14641ffb123b6ebeac4724b
parentb41932f544586e606a7493cbc6dfb3c97c6b44d7
iommu/arm-smmu-v3: Add a type for the STE

Instead of passing a naked __le16 * around to represent a STE wrap it in a
"struct arm_smmu_ste" with an array of the correct size. This makes it
much clearer which functions will comprise the "STE API".

Reviewed-by: Moritz Fischer <mdf@kernel.org>
Reviewed-by: Michael Shavit <mshavit@google.com>
Reviewed-by: Eric Auger <eric.auger@redhat.com>
Reviewed-by: Nicolin Chen <nicolinc@nvidia.com>
Tested-by: Shameer Kolothum <shameerali.kolothum.thodi@huawei.com>
Tested-by: Nicolin Chen <nicolinc@nvidia.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Signed-off-by: Will Deacon <will@kernel.org>
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.h