From: Lars Persson Date: Tue, 12 Jan 2016 14:28:13 +0000 (+0100) Subject: dwc_eth_qos: Fix dma address for multi-fragment skbs X-Git-Tag: firefly_0821_release~3391^2~143 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=ca0f94da27314276153d38ea02f514348515bf87;p=firefly-linux-kernel-4.4.55.git dwc_eth_qos: Fix dma address for multi-fragment skbs [ Upstream commit d461873272169a3fc3a8d155d7b1c92e9d97b419 ] The offset inside the fragment was not used for the dma address and silent data corruption resulted because TSO makes the checksum match. Fixes: 077742dac2c7 ("dwc_eth_qos: Add support for Synopsys DWC Ethernet QoS") Signed-off-by: Lars Persson Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/net/ethernet/synopsys/dwc_eth_qos.c b/drivers/net/ethernet/synopsys/dwc_eth_qos.c index 9066d7a8483c..f96c6b3606f2 100644 --- a/drivers/net/ethernet/synopsys/dwc_eth_qos.c +++ b/drivers/net/ethernet/synopsys/dwc_eth_qos.c @@ -2107,7 +2107,7 @@ static int dwceqos_tx_frags(struct sk_buff *skb, struct net_local *lp, dd = &lp->tx_descs[lp->tx_next]; /* Set DMA Descriptor fields */ - dd->des0 = dma_handle; + dd->des0 = dma_handle + consumed_size; dd->des1 = 0; dd->des2 = dma_size;