Commit 016d9337 authored by Ziye Yang's avatar Ziye Yang Committed by Ben Walker
Browse files

lib/virtio: change the definition of cookie



Converting to the struct virtio_req is useless.

Signed-off-by: default avatarZiye Yang <ziye.yang@intel.com>
Change-Id: I141268314d28cf87bdef529808c8e18bd1b41c9d
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/459360


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarDarek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
parent e8356fd2
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -384,7 +384,7 @@ virtqueue_dequeue_burst_rx(struct virtqueue *vq, void **rx_pkts,
			   uint32_t *len, uint16_t num)
{
	struct vring_used_elem *uep;
	struct virtio_req *cookie;
	void *cookie;
	uint16_t used_idx, desc_idx;
	uint16_t i;

@@ -394,7 +394,7 @@ virtqueue_dequeue_burst_rx(struct virtqueue *vq, void **rx_pkts,
		uep = &vq->vq_ring.used->ring[used_idx];
		desc_idx = (uint16_t) uep->id;
		len[i] = uep->len;
		cookie = (struct virtio_req *)vq->vq_descx[desc_idx].cookie;
		cookie = vq->vq_descx[desc_idx].cookie;

		if (spdk_unlikely(cookie == NULL)) {
			SPDK_WARNLOG("vring descriptor with no mbuf cookie at %"PRIu16"\n",