Skip to content

Commit 2fba506

Browse files
shinas-marvelldavem330
authored andcommitted
octeon_ep: remove dma sync in trasmit path
Cleanup dma sync calls for scatter gather mappings, since they are coherent allocations and do not need explicit sync to be called. Signed-off-by: Shinas Rasheed <srasheed@marvell.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 5827fe2 commit 2fba506

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

drivers/net/ethernet/marvell/octeon_ep/octep_main.c

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -872,9 +872,6 @@ static netdev_tx_t octep_start_xmit(struct sk_buff *skb,
872872
if (dma_mapping_error(iq->dev, dma))
873873
goto dma_map_err;
874874

875-
dma_sync_single_for_cpu(iq->dev, tx_buffer->sglist_dma,
876-
OCTEP_SGLIST_SIZE_PER_PKT,
877-
DMA_TO_DEVICE);
878875
memset(sglist, 0, OCTEP_SGLIST_SIZE_PER_PKT);
879876
sglist[0].len[3] = len;
880877
sglist[0].dma_ptr[0] = dma;
@@ -894,10 +891,6 @@ static netdev_tx_t octep_start_xmit(struct sk_buff *skb,
894891
frag++;
895892
si++;
896893
}
897-
dma_sync_single_for_device(iq->dev, tx_buffer->sglist_dma,
898-
OCTEP_SGLIST_SIZE_PER_PKT,
899-
DMA_TO_DEVICE);
900-
901894
hw_desc->dptr = tx_buffer->sglist_dma;
902895
}
903896

0 commit comments

Comments
 (0)