On 30/08/2019 23:49, Krishna Reddy wrote:
+ if (smmu->impl->tlb_sync) {
+ smmu->impl->tlb_sync(smmu, page, sync, status);
What I'd hoped is that rather than needing a hook for this, you could just
override smmu_domain->tlb_ops from .init_context to wire up the alternate .s
>> +if (smmu->impl->tlb_sync) {
>> +smmu->impl->tlb_sync(smmu, page, sync, status);
>What I'd hoped is that rather than needing a hook for this, you could just
>override smmu_domain->tlb_ops from .init_context to wire up the alternate
>.sync method directly. That would save this
>Wouldn't it work if you replaced all calls of __arm_smmu_tlb_sync() by
>smmu->impl->tlb_sync() and assign __arm_smmu_tlb_sync() as default for
>devices that don't need to override it? That makes this patch slightly larger,
>but it saves us one level of indirection.
The tlb_ops->tlb_sync can be o
>> +for (i = 0; i < to_nsmmu(smmu)->num_inst; i++)
>It might make more sense to make this the innermost loop, i.e.:
for (i = 0; i < nsmmu->num_inst; i++)
reg &= readl_relaxed(nsmmu_page(smmu, i, page)...
>since polling the instances in parallel rather than in series see
On 29/08/2019 23:47, Krishna Reddy wrote:
tlb_sync hook allows nvidia smmu handle tlb sync
across multiple SMMUs as necessary.
Signed-off-by: Krishna Reddy
---
drivers/iommu/arm-smmu-nvidia.c | 32
drivers/iommu/arm-smmu.c| 8 +---
drivers/iommu
On Thu, Aug 29, 2019 at 03:47:03PM -0700, Krishna Reddy wrote:
> tlb_sync hook allows nvidia smmu handle tlb sync
> across multiple SMMUs as necessary.
>
> Signed-off-by: Krishna Reddy
> ---
> drivers/iommu/arm-smmu-nvidia.c | 32
> drivers/iommu/arm-smmu.c