net/netvsc: fix ring freeing

The internal receive ring should be freed with rte_ring_free
not rte_free.

Fixes: 4e9c73e96e ("net/netvsc: add Hyper-V network device")

Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>
This commit is contained in:
Stephen Hemminger 2018-08-01 16:18:33 -07:00 committed by Thomas Monjalon
parent 94421f9e76
commit ec3242685a

View File

@ -774,7 +774,7 @@ hn_dev_rx_queue_setup(struct rte_eth_dev *dev,
return 0;
fail:
rte_free(rxq->rx_ring);
rte_ring_free(rxq->rx_ring);
rte_free(rxq->event_buf);
rte_free(rxq);
return -ENOMEM;
@ -790,7 +790,7 @@ hn_dev_rx_queue_release(void *arg)
if (!rxq)
return;
rte_free(rxq->rx_ring);
rte_ring_free(rxq->rx_ring);
rxq->rx_ring = NULL;
rxq->mb_pool = NULL;