diff options
author | Peter Xu <peterx@redhat.com> | 2017-02-07 16:28:03 +0800 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2017-02-17 21:52:31 +0200 |
commit | 3213835720f0b79ea60ead8e81f356695a446d1d (patch) | |
tree | 2afba427523e7f8801556d9a936e024e8aad818e /hw/vfio/common.c | |
parent | d4e9b75aa03d3f0e08fa431998764d7f72d78a48 (diff) |
vfio: trace map/unmap for notify as well
We traces its range, but we don't know whether it's a MAP/UNMAP. Let's
dump it as well.
Acked-by: Alex Williamson <alex.williamson@redhat.com>
Reviewed-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/vfio/common.c')
-rw-r--r-- | hw/vfio/common.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/hw/vfio/common.c b/hw/vfio/common.c index 801578b4b9..174f3512d1 100644 --- a/hw/vfio/common.c +++ b/hw/vfio/common.c @@ -305,7 +305,8 @@ static void vfio_iommu_map_notify(IOMMUNotifier *n, IOMMUTLBEntry *iotlb) void *vaddr; int ret; - trace_vfio_iommu_map_notify(iova, iova + iotlb->addr_mask); + trace_vfio_iommu_map_notify(iotlb->perm == IOMMU_NONE ? "UNMAP" : "MAP", + iova, iova + iotlb->addr_mask); if (iotlb->target_as != &address_space_memory) { error_report("Wrong target AS \"%s\", only system memory is allowed", |