Lines Matching refs:txd_info
1389 struct mtk_tx_dma_desc_info txd_info = { in mtk_tx_map() local
1419 txd_info.addr = dma_map_single(eth->dma_dev, skb->data, txd_info.size, in mtk_tx_map()
1421 if (unlikely(dma_mapping_error(eth->dma_dev, txd_info.addr))) in mtk_tx_map()
1424 mtk_tx_set_dma_desc(dev, itxd, &txd_info); in mtk_tx_map()
1428 setup_tx_buf(eth, itx_buf, itxd_pdma, txd_info.addr, txd_info.size, in mtk_tx_map()
1455 memset(&txd_info, 0, sizeof(struct mtk_tx_dma_desc_info)); in mtk_tx_map()
1456 txd_info.size = min_t(unsigned int, frag_size, in mtk_tx_map()
1458 txd_info.qid = queue; in mtk_tx_map()
1459 txd_info.last = i == skb_shinfo(skb)->nr_frags - 1 && in mtk_tx_map()
1460 !(frag_size - txd_info.size); in mtk_tx_map()
1461 txd_info.addr = skb_frag_dma_map(eth->dma_dev, frag, in mtk_tx_map()
1462 offset, txd_info.size, in mtk_tx_map()
1464 if (unlikely(dma_mapping_error(eth->dma_dev, txd_info.addr))) in mtk_tx_map()
1467 mtk_tx_set_dma_desc(dev, txd, &txd_info); in mtk_tx_map()
1477 setup_tx_buf(eth, tx_buf, txd_pdma, txd_info.addr, in mtk_tx_map()
1478 txd_info.size, k++); in mtk_tx_map()
1480 frag_size -= txd_info.size; in mtk_tx_map()
1481 offset += txd_info.size; in mtk_tx_map()
1752 struct mtk_tx_dma_desc_info *txd_info, in mtk_xdp_frame_map() argument
1761 txd_info->addr = dma_map_single(eth->dma_dev, data, in mtk_xdp_frame_map()
1762 txd_info->size, DMA_TO_DEVICE); in mtk_xdp_frame_map()
1763 if (unlikely(dma_mapping_error(eth->dma_dev, txd_info->addr))) in mtk_xdp_frame_map()
1770 txd_info->addr = page_pool_get_dma_addr(page) + in mtk_xdp_frame_map()
1772 dma_sync_single_for_device(eth->dma_dev, txd_info->addr, in mtk_xdp_frame_map()
1773 txd_info->size, DMA_BIDIRECTIONAL); in mtk_xdp_frame_map()
1775 mtk_tx_set_dma_desc(dev, txd, txd_info); in mtk_xdp_frame_map()
1782 setup_tx_buf(eth, tx_buf, txd_pdma, txd_info->addr, txd_info->size, in mtk_xdp_frame_map()
1795 struct mtk_tx_dma_desc_info txd_info = { in mtk_xdp_submit_frame() local
1827 err = mtk_xdp_frame_map(eth, dev, &txd_info, txd, tx_buf, in mtk_xdp_submit_frame()
1832 if (txd_info.last) in mtk_xdp_submit_frame()
1846 memset(&txd_info, 0, sizeof(struct mtk_tx_dma_desc_info)); in mtk_xdp_submit_frame()
1847 txd_info.size = skb_frag_size(&sinfo->frags[index]); in mtk_xdp_submit_frame()
1848 txd_info.last = index + 1 == nr_frags; in mtk_xdp_submit_frame()
1849 txd_info.qid = mac->id; in mtk_xdp_submit_frame()