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

Function cpfl_ctlq_dealloc_ring_res

dpdk/drivers/net/cpfl/cpfl_controlq.c:227–241  ·  view source on GitHub ↗

* cpfl_ctlq_dealloc_ring_res - free up the descriptor buffer structure * @hw: context info for the callback * @cq: pointer to the specific control queue * * DMA buffers are released by the CP itself */

Source from the content-addressed store, hash-verified

225 * DMA buffers are released by the CP itself
226 */
227static void
228cpfl_ctlq_dealloc_ring_res(struct idpf_hw *hw __rte_unused, struct idpf_ctlq_info *cq)
229{
230 int i;
231
232 if (cq->cq_type == IDPF_CTLQ_TYPE_MAILBOX_RX ||
233 cq->cq_type == IDPF_CTLQ_TYPE_CONFIG_RX) {
234 for (i = 0; i < cq->ring_size; i++)
235 idpf_free(hw, cq->bi.rx_buff[i]);
236 /* free the buffer header */
237 idpf_free(hw, cq->bi.rx_buff);
238 } else {
239 idpf_free(hw, cq->bi.tx_msg);
240 }
241}
242
243/**
244 * cpfl_ctlq_add - add one control queue

Callers 2

cpfl_ctlq_addFunction · 0.85
cpfl_ctlq_shutdownFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected