Lines Matching refs:rx_buf
75 struct efx_rx_buffer *rx_buf) in efx_recycle_rx_page() argument
79 struct page *page = rx_buf->page; in efx_recycle_rx_page()
83 if (!(rx_buf->flags & EFX_RX_BUF_LAST_IN_PAGE)) in efx_recycle_rx_page()
102 efx_unmap_rx_buffer(efx, rx_buf); in efx_recycle_rx_page()
103 put_page(rx_buf->page); in efx_recycle_rx_page()
108 struct efx_rx_buffer *rx_buf, in efx_recycle_rx_pages() argument
117 efx_recycle_rx_page(channel, rx_buf); in efx_recycle_rx_pages()
118 rx_buf = efx_rx_buf_next(rx_queue, rx_buf); in efx_recycle_rx_pages()
123 struct efx_rx_buffer *rx_buf, in efx_discard_rx_packet() argument
128 efx_recycle_rx_pages(channel, rx_buf, n_frags); in efx_discard_rx_packet()
130 efx_free_rx_buffers(rx_queue, rx_buf, n_frags); in efx_discard_rx_packet()
176 struct efx_rx_buffer *rx_buf) in efx_fini_rx_buffer() argument
179 if (rx_buf->page) in efx_fini_rx_buffer()
180 put_page(rx_buf->page); in efx_fini_rx_buffer()
183 if (rx_buf->flags & EFX_RX_BUF_LAST_IN_PAGE) { in efx_fini_rx_buffer()
184 efx_unmap_rx_buffer(rx_queue->efx, rx_buf); in efx_fini_rx_buffer()
185 efx_free_rx_buffers(rx_queue, rx_buf, 1); in efx_fini_rx_buffer()
187 rx_buf->page = NULL; in efx_fini_rx_buffer()
279 struct efx_rx_buffer *rx_buf; in efx_fini_rx_queue() local
295 rx_buf = efx_rx_buffer(rx_queue, index); in efx_fini_rx_queue()
296 efx_fini_rx_buffer(rx_queue, rx_buf); in efx_fini_rx_queue()
323 struct efx_rx_buffer *rx_buf) in efx_unmap_rx_buffer() argument
325 struct page *page = rx_buf->page; in efx_unmap_rx_buffer()
338 struct efx_rx_buffer *rx_buf, in efx_free_rx_buffers() argument
342 if (rx_buf->page) { in efx_free_rx_buffers()
343 put_page(rx_buf->page); in efx_free_rx_buffers()
344 rx_buf->page = NULL; in efx_free_rx_buffers()
346 rx_buf = efx_rx_buf_next(rx_queue, rx_buf); in efx_free_rx_buffers()
378 struct efx_rx_buffer *rx_buf; in efx_init_rx_buffers() local
412 rx_buf = efx_rx_buffer(rx_queue, index); in efx_init_rx_buffers()
413 rx_buf->dma_addr = dma_addr + efx->rx_ip_align + in efx_init_rx_buffers()
415 rx_buf->page = page; in efx_init_rx_buffers()
416 rx_buf->page_offset = page_offset + efx->rx_ip_align + in efx_init_rx_buffers()
418 rx_buf->len = efx->rx_dma_len; in efx_init_rx_buffers()
419 rx_buf->flags = 0; in efx_init_rx_buffers()
426 rx_buf->flags = EFX_RX_BUF_LAST_IN_PAGE; in efx_init_rx_buffers()
511 efx_rx_packet_gro(struct efx_channel *channel, struct efx_rx_buffer *rx_buf, in efx_rx_packet_gro() argument
523 efx_free_rx_buffers(rx_queue, rx_buf, n_frags); in efx_rx_packet_gro()
535 skb->ip_summed = ((rx_buf->flags & EFX_RX_PKT_CSUMMED) ? in efx_rx_packet_gro()
538 skb->csum_level = !!(rx_buf->flags & EFX_RX_PKT_CSUM_LEVEL); in efx_rx_packet_gro()
542 rx_buf->page, rx_buf->page_offset, in efx_rx_packet_gro()
543 rx_buf->len); in efx_rx_packet_gro()
544 rx_buf->page = NULL; in efx_rx_packet_gro()
545 skb->len += rx_buf->len; in efx_rx_packet_gro()
549 rx_buf = efx_rx_buf_next(&channel->rx_queue, rx_buf); in efx_rx_packet_gro()