Re: [PATCH v8 3/3] iommu/arm-smmu-v3: Enable CFGI/TLBI-repeat workaround on Tegra264
From: Ashish Mhetre
Date: Fri Jul 24 2026 - 00:25:41 EST
On 7/23/2026 12:46 AM, Nicolin Chen wrote:
On Wed, Jul 22, 2026 at 10:20:33AM +0000, Ashish Mhetre wrote:
The host repeats only the invalidations it issues itself. On a nestingI think this "enable" patch is doing a bit too much.
setup the guest submits its own invalidations, either directly through
VCMDQ or via the iommufd user-invalidation path, so the guest is the one
that has to apply the workaround there. Report the erratum to user space
through the new IOMMU_HW_INFO_ARM_SMMUV3_ERRATA_REPEAT_TLBI_CFGI hw_info
flag so a VMM can confirm the guest runs a matching "nvidia,tegra264-smmu"
(or otherwise double the commands itself). The host therefore does not
repeat the guest's user-issued invalidations, which would otherwise be
doubled a second time.
All the iommufd-related changes can be added separately
I would do a cleanup:
- arm-smmu-v3: Factor force_sync
- arm-smmu-v3: Add arm_smmu_erratum_repeat_tlbi_cfgi_key and WAR
- arm-smmu-v3-iommufd: Add IOMMU_HW_INFO_ARM_SMMUV3_ERRATA_REPEAT_TLBI_CFGI
- arm-smmu-v3: Set arm_smmu_erratum_repeat_tlbi_cfgi_key
Okay, I will add one more patch to series for iommu-fd related changes in v9.
+/**You can follow the kdoc style as enum iommufd_option.
+ * enum iommu_hw_info_arm_smmuv3_flags - Flags for ARM SMMUv3 hw_info
+ * @IOMMU_HW_INFO_ARM_SMMUV3_ERRATA_REPEAT_TLBI_CFGI: If set, user space must
+ * issue TLBI/CFGI+SYNC commands twice due to a hardware erratum T264-SMMU-3.
+ * See the description at arm_smmu_erratum_repeat_tlbi_cfgi_key.
Nicolin
Ack, I will fix it in v9.
Thanks,
Ashish Mhetre