From: Jens Freimann Date: Mon, 17 Dec 2018 21:31:33 +0000 (+0100) Subject: net/virtio: dump packed virtqueue data X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=56785a2d6fad987c025278909307db776df59bd9;p=dpdk.git net/virtio: dump packed virtqueue data Add support to dump packed virtqueue data to the VIRTQUEUE_DUMP() macro. Signed-off-by: Jens Freimann Reviewed-by: Maxime Coquelin --- diff --git a/drivers/net/virtio/virtqueue.h b/drivers/net/virtio/virtqueue.h index 5c81f83772..ed99dfef26 100644 --- a/drivers/net/virtio/virtqueue.h +++ b/drivers/net/virtio/virtqueue.h @@ -429,6 +429,15 @@ virtqueue_notify(struct virtqueue *vq) uint16_t used_idx, nused; \ used_idx = (vq)->vq_ring.used->idx; \ nused = (uint16_t)(used_idx - (vq)->vq_used_cons_idx); \ + if (vtpci_packed_queue((vq)->hw)) { \ + PMD_INIT_LOG(DEBUG, \ + "VQ: - size=%d; free=%d; used_cons_idx=%d; avail_idx=%d;" \ + "VQ: - avail_wrap_counter=%d; used_wrap_counter=%d", \ + (vq)->vq_nentries, (vq)->vq_free_cnt, (vq)->vq_used_cons_idx, \ + (vq)->vq_avail_idx, (vq)->avail_wrap_counter, \ + (vq)->used_wrap_counter); \ + break; \ + } \ PMD_INIT_LOG(DEBUG, \ "VQ: - size=%d; free=%d; used=%d; desc_head_idx=%d;" \ " avail.idx=%d; used_cons_idx=%d; used.idx=%d;" \