Lines Matching refs:unmap_q
90 struct bnad_tx_unmap *unmap_q, in bnad_tx_buff_unmap() argument
97 unmap = &unmap_q[index]; in bnad_tx_buff_unmap()
115 unmap = &unmap_q[index]; in bnad_tx_buff_unmap()
139 struct bnad_tx_unmap *unmap_q = tcb->unmap_q; in bnad_txq_cleanup() local
144 skb = unmap_q[i].skb; in bnad_txq_cleanup()
147 bnad_tx_buff_unmap(bnad, unmap_q, tcb->q_depth, i); in bnad_txq_cleanup()
163 struct bnad_tx_unmap *unmap_q = tcb->unmap_q; in bnad_txcmpl_process() local
180 unmap = &unmap_q[cons]; in bnad_txcmpl_process()
190 cons = bnad_tx_buff_unmap(bnad, unmap_q, q_depth, cons); in bnad_txcmpl_process()
249 struct bnad_rx_unmap_q *unmap_q = rcb->unmap_q; in bnad_rxq_alloc_uninit() local
251 unmap_q->reuse_pi = -1; in bnad_rxq_alloc_uninit()
252 unmap_q->alloc_order = -1; in bnad_rxq_alloc_uninit()
253 unmap_q->map_size = 0; in bnad_rxq_alloc_uninit()
254 unmap_q->type = BNAD_RXBUF_NONE; in bnad_rxq_alloc_uninit()
261 struct bnad_rx_unmap_q *unmap_q = rcb->unmap_q; in bnad_rxq_alloc_init() local
268 unmap_q->type = BNAD_RXBUF_PAGE; in bnad_rxq_alloc_init()
271 unmap_q->alloc_order = 0; in bnad_rxq_alloc_init()
272 unmap_q->map_size = rcb->rxq->buffer_size; in bnad_rxq_alloc_init()
275 unmap_q->alloc_order = 0; in bnad_rxq_alloc_init()
276 unmap_q->map_size = rcb->rxq->buffer_size; in bnad_rxq_alloc_init()
277 unmap_q->type = BNAD_RXBUF_MULTI_BUFF; in bnad_rxq_alloc_init()
279 unmap_q->alloc_order = order; in bnad_rxq_alloc_init()
280 unmap_q->map_size = in bnad_rxq_alloc_init()
286 BUG_ON((PAGE_SIZE << order) % unmap_q->map_size); in bnad_rxq_alloc_init()
324 struct bnad_rx_unmap_q *unmap_q = rcb->unmap_q; in bnad_rxq_cleanup() local
328 struct bnad_rx_unmap *unmap = &unmap_q->unmap[i]; in bnad_rxq_cleanup()
330 if (BNAD_RXBUF_IS_SK_BUFF(unmap_q->type)) in bnad_rxq_cleanup()
342 struct bnad_rx_unmap_q *unmap_q = rcb->unmap_q; in bnad_rxq_refill_page() local
352 alloc_size = PAGE_SIZE << unmap_q->alloc_order; in bnad_rxq_refill_page()
356 unmap = &unmap_q->unmap[prod]; in bnad_rxq_refill_page()
358 if (unmap_q->reuse_pi < 0) { in bnad_rxq_refill_page()
360 unmap_q->alloc_order); in bnad_rxq_refill_page()
363 prev = &unmap_q->unmap[unmap_q->reuse_pi]; in bnad_rxq_refill_page()
365 page_offset = prev->page_offset + unmap_q->map_size; in bnad_rxq_refill_page()
376 unmap_q->map_size, DMA_FROM_DEVICE); in bnad_rxq_refill_page()
387 unmap->vector.len = unmap_q->map_size; in bnad_rxq_refill_page()
388 page_offset += unmap_q->map_size; in bnad_rxq_refill_page()
391 unmap_q->reuse_pi = prod; in bnad_rxq_refill_page()
393 unmap_q->reuse_pi = -1; in bnad_rxq_refill_page()
416 struct bnad_rx_unmap_q *unmap_q = rcb->unmap_q; in bnad_rxq_refill_skb() local
428 unmap = &unmap_q->unmap[prod]; in bnad_rxq_refill_skb()
471 struct bnad_rx_unmap_q *unmap_q = rcb->unmap_q; in bnad_rxq_post() local
478 if (BNAD_RXBUF_IS_SK_BUFF(unmap_q->type)) in bnad_rxq_post()
502 struct bnad_rx_unmap_q *unmap_q; in bnad_cq_drop_packet() local
506 unmap_q = rcb->unmap_q; in bnad_cq_drop_packet()
508 unmap = &unmap_q->unmap[ci]; in bnad_cq_drop_packet()
511 if (BNAD_RXBUF_IS_SK_BUFF(unmap_q->type)) in bnad_cq_drop_packet()
523 struct bnad_rx_unmap_q *unmap_q; in bnad_cq_setup_skb_frags() local
532 unmap_q = rcb->unmap_q; in bnad_cq_setup_skb_frags()
537 prefetch(page_address(unmap_q->unmap[ci].page) + in bnad_cq_setup_skb_frags()
538 unmap_q->unmap[ci].page_offset); in bnad_cq_setup_skb_frags()
544 unmap = &unmap_q->unmap[ci]; in bnad_cq_setup_skb_frags()
591 struct bnad_rx_unmap_q *unmap_q; in bnad_cq_process() local
624 unmap_q = rcb->unmap_q; in bnad_cq_process()
629 if (BNAD_RXBUF_IS_SK_BUFF(unmap_q->type)) { in bnad_cq_process()
630 unmap = &unmap_q->unmap[sop_ci]; in bnad_cq_process()
647 if (BNAD_RXBUF_IS_MULTI_BUFF(unmap_q->type) && in bnad_cq_process()
689 if (BNAD_RXBUF_IS_SK_BUFF(unmap_q->type)) in bnad_cq_process()
714 if (BNAD_RXBUF_IS_SK_BUFF(unmap_q->type)) in bnad_cq_process()
2914 struct bnad_tx_unmap *unmap_q, *unmap, *head_unmap; in bnad_start_xmit() local
2955 unmap_q = tcb->unmap_q; in bnad_start_xmit()
2997 head_unmap = &unmap_q[prod]; in bnad_start_xmit()
3030 bnad_tx_buff_unmap(bnad, unmap_q, q_depth, in bnad_start_xmit()
3045 unmap = &unmap_q[prod]; in bnad_start_xmit()
3052 bnad_tx_buff_unmap(bnad, unmap_q, q_depth, in bnad_start_xmit()
3069 bnad_tx_buff_unmap(bnad, unmap_q, q_depth, tcb->producer_index); in bnad_start_xmit()