Lines Matching defs:txdr
98 struct e1000_tx_ring *txdr);
1379 * @txdr: tx descriptor ring (for a specific queue) to setup
1385 struct e1000_tx_ring *txdr)
1390 size = sizeof(struct e1000_buffer) * txdr->count;
1391 txdr->buffer_info = vmalloc(size);
1392 if (!txdr->buffer_info) {
1397 memset(txdr->buffer_info, 0, size);
1401 txdr->size = txdr->count * sizeof(struct e1000_tx_desc);
1402 txdr->size = ALIGN(txdr->size, 4096);
1404 txdr->desc = dma_alloc_coherent(&pdev->dev, txdr->size, &txdr->dma,
1406 if (!txdr->desc) {
1408 vfree(txdr->buffer_info);
1415 if (!e1000_check_64k_bound(adapter, txdr->desc, txdr->size)) {
1416 void *olddesc = txdr->desc;
1417 dma_addr_t olddma = txdr->dma;
1418 e_err(tx_err, "txdr align check failed: %u bytes at %p\n",
1419 txdr->size, txdr->desc);
1421 txdr->desc = dma_alloc_coherent(&pdev->dev, txdr->size,
1422 &txdr->dma, GFP_KERNEL);
1424 if (!txdr->desc) {
1425 dma_free_coherent(&pdev->dev, txdr->size, olddesc,
1430 if (!e1000_check_64k_bound(adapter, txdr->desc, txdr->size)) {
1432 dma_free_coherent(&pdev->dev, txdr->size, txdr->desc,
1433 txdr->dma);
1434 dma_free_coherent(&pdev->dev, txdr->size, olddesc,
1438 vfree(txdr->buffer_info);
1442 dma_free_coherent(&pdev->dev, txdr->size, olddesc,
1446 memset(txdr->desc, 0, txdr->size);
1448 txdr->next_to_use = 0;
1449 txdr->next_to_clean = 0;
2296 struct e1000_tx_ring *txdr = adapter->tx_ring;
2380 if (E1000_DESC_UNUSED(txdr) + 1 < txdr->count) {