[PATCH v3 3/3] iommu/arm-smmu-v3: Issue CFGI/TLBI twice on Tegra264

Nicolin Chen nicolinc at nvidia.com
Mon Jun 1 11:37:02 PDT 2026


On Mon, Jun 01, 2026 at 10:48:45AM +0000, Ashish Mhetre wrote:
> Apply the workaround for Tegra264 erratum ARM_SMMU_OPT_TLBI_TWICE by
> issuing every CFGI/TLBI cmdlist twice on affected SMMU instances, with
> CMD_SYNC after each. The erratum requires this exact sequencing:
> 
>     TLBI/CFGI ... CMD_SYNC TLBI/CFGI ... CMD_SYNC
> 
> Rename the existing arm_smmu_cmdq_issue_cmdlist() to
> __arm_smmu_cmdq_issue_cmdlist() and add a thin wrapper that, on
> affected SMMUs and when @sync is true, re-issues the same cmdlist a
> second time when arm_smmu_cmd_needs_tlbi_twice() is true.
> 
> For the in-tree batching path, register the Tegra264 condition with
> arm_smmu_cmdq_batch_force_sync() so that a full batch carrying
> CFGI/TLBI commands flushes with sync=true.
> 
> For iommufd VSMMU path add an arm_vsmmu_can_batch_cmd() predicate that
> splits the iommufd batch at cmd which doesn't need doubling.
> 
> Suggested-by: Nicolin Chen <nicolinc at nvidia.com>
> Signed-off-by: Ashish Mhetre <amhetre at nvidia.com>

Reviewed-by: Nicolin Chen <nicolinc at nvidia.com>



More information about the linux-arm-kernel mailing list