MCPcopy Create free account
hub / github.com/F-Stack/f-stack / virtio_free_queues

Function virtio_free_queues

dpdk/drivers/net/virtio/virtio_ethdev.c:292–312  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

290}
291
292static void
293virtio_free_queues(struct virtio_hw *hw)
294{
295 uint16_t nr_vq = virtio_get_nr_vq(hw);
296 struct virtqueue *vq;
297 uint16_t i;
298
299 if (hw->vqs == NULL)
300 return;
301
302 for (i = 0; i < nr_vq; i++) {
303 vq = hw->vqs[i];
304 if (!vq)
305 continue;
306 virtqueue_free(vq);
307 hw->vqs[i] = NULL;
308 }
309
310 rte_free(hw->vqs);
311 hw->vqs = NULL;
312}
313
314static int
315virtio_alloc_queues(struct rte_eth_dev *dev)

Callers 3

virtio_alloc_queuesFunction · 0.85
virtio_dev_closeFunction · 0.85
virtio_init_deviceFunction · 0.85

Calls 3

virtio_get_nr_vqFunction · 0.85
virtqueue_freeFunction · 0.85
rte_freeFunction · 0.85

Tested by

no test coverage detected