@@ -83,7 +83,7 @@ static int etnaviv_iommu_map(struct etnaviv_iommu_context *context, u32 iova,
dma_addr_t pa = sg_dma_address(sg) + sg->offset;
unsigned int bytes = sg_dma_len(sg) - sg->offset;
- VERB("map[%d]: %08x %pap(%x)", i, iova, &pa, bytes);
+ VERB("map[%d]: %08x %pap(%x)", i, da, &pa, bytes);
ret = etnaviv_context_map(context, da, pa, bytes, prot);
if (ret)
@@ -113,7 +113,7 @@ static void etnaviv_iommu_unmap(struct etnaviv_iommu_context *context, u32 iova,
etnaviv_context_unmap(context, da, bytes);
- VERB("unmap[%d]: %08x(%x)", i, iova, bytes);
+ VERB("unmap[%d]: %08x(%x)", i, da, bytes);
BUG_ON(!PAGE_ALIGNED(bytes));
The 'iova' variable is invarant within one invoke of the etnaviv_iommu_unmap()/etnaviv_iommu_unmap(), which means that the debug log always print the same GPU virtual address while mapping or unmaping. Made the GPU virtual address being printed increment with real GPUVA being mapped or unmapped. Signed-off-by: Sui Jingfeng <sui.jingfeng@linux.dev> --- drivers/gpu/drm/etnaviv/etnaviv_mmu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)