Skip to content

Commit

Permalink
sun4u_iommu: add trace event for IOMMU translations
Browse files Browse the repository at this point in the history
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Acked-by: Artyom Tarasenko <atar4qemu@gmail.com>
  • Loading branch information
mcayland committed Jan 9, 2018
1 parent 09ecbb7 commit 602c993
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions hw/sparc64/sun4u_iommu.c
Expand Up @@ -184,6 +184,8 @@ static IOMMUTLBEntry sun4u_translate_iommu(IOMMUMemoryRegion *iommu,
ret.addr_mask = (IOMMU_PAGE_SIZE_8K - 1);
}

trace_sun4u_iommu_translate(ret.iova, ret.translated_addr, tte);

return ret;
}

Expand Down
1 change: 1 addition & 0 deletions hw/sparc64/trace-events
Expand Up @@ -6,3 +6,4 @@ ebus_isa_irq_handler(int n, int level) "Set ISA IRQ %d level %d"
# hw/sparc64/sun4u_iommu.c
sun4u_iommu_mem_read(uint64_t addr, uint64_t val, int size) "addr: 0x%"PRIx64" val: 0x%"PRIx64" size: %d"
sun4u_iommu_mem_write(uint64_t addr, uint64_t val, int size) "addr: 0x%"PRIx64" val: 0x%"PRIx64" size: %d"
sun4u_iommu_translate(uint64_t addr, uint64_t trans_addr, uint64_t tte) "xlate 0x%"PRIx64" => pa 0x%"PRIx64" tte: 0x%"PRIx64

0 comments on commit 602c993

Please sign in to comment.