Lines Matching refs:tx_ctl
861 struct ks8842_tx_dma_ctl *tx_ctl = &adapter->dma_tx;
864 tx_ctl->adesc = NULL;
865 if (tx_ctl->chan)
866 dmaengine_terminate_all(tx_ctl->chan);
883 struct ks8842_tx_dma_ctl *tx_ctl = &adapter->dma_tx;
888 if (tx_ctl->chan)
889 dma_release_channel(tx_ctl->chan);
890 tx_ctl->chan = NULL;
898 if (sg_dma_address(&tx_ctl->sg))
899 dma_unmap_single(adapter->dev, sg_dma_address(&tx_ctl->sg),
901 sg_dma_address(&tx_ctl->sg) = 0;
903 kfree(tx_ctl->buf);
904 tx_ctl->buf = NULL;
915 struct ks8842_tx_dma_ctl *tx_ctl = &adapter->dma_tx;
925 sg_init_table(&tx_ctl->sg, 1);
927 tx_ctl->chan = dma_request_channel(mask, ks8842_dma_filter_fn,
928 (void *)(long)tx_ctl->channel);
929 if (!tx_ctl->chan) {
935 tx_ctl->buf = kmalloc(DMA_BUFFER_SIZE, GFP_KERNEL);
936 if (!tx_ctl->buf) {
941 sg_dma_address(&tx_ctl->sg) = dma_map_single(adapter->dev,
942 tx_ctl->buf, DMA_BUFFER_SIZE, DMA_TO_DEVICE);
943 if (dma_mapping_error(adapter->dev, sg_dma_address(&tx_ctl->sg))) {
945 sg_dma_address(&tx_ctl->sg) = 0;