diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2017-06-01 15:54:47 +0200 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2017-06-02 18:57:17 +0300 |
commit | b0ac429f1346e9fa13206d748bedc9bd497a55bc (patch) | |
tree | 49702182aaf9732f140f7f8c48384938e9304664 /hw/virtio/virtio.c | |
parent | f811f97040a48358b456b46ecbc9167f0131034f (diff) |
virtio: add virtqueue_alloc_element tracepoint
This tracepoint can help diagnosing failures due to memory
fragmentation in the guest.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/virtio/virtio.c')
-rw-r--r-- | hw/virtio/virtio.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/virtio/virtio.c b/hw/virtio/virtio.c index f99d99fd78..464947f76d 100644 --- a/hw/virtio/virtio.c +++ b/hw/virtio/virtio.c @@ -815,6 +815,7 @@ static void *virtqueue_alloc_element(size_t sz, unsigned out_num, unsigned in_nu assert(sz >= sizeof(VirtQueueElement)); elem = g_malloc(out_sg_end); + trace_virtqueue_alloc_element(elem, sz, in_num, out_num); elem->out_num = out_num; elem->in_num = in_num; elem->in_addr = (void *)elem + in_addr_ofs; |