net: mvneta: Optimize rx path for small frame
authorGregory CLEMENT <gregory.clement@free-electrons.com>
Thu, 1 Dec 2016 17:03:04 +0000 (18:03 +0100)
committerDavid S. Miller <davem@davemloft.net>
Fri, 2 Dec 2016 18:52:00 +0000 (13:52 -0500)
For small frame reuse the phys_addr variable instead of accessing the
uncacheable value in the rx descriptor.

Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
Tested-by: Marcin Wojtas <mw@semihalf.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/mvneta.c

index 0a24571e44b925622afdf586e48f98e06ba31a5d..2445428bd79c649643c29a5b8eb44ac3aba4ea28 100644 (file)
@@ -1918,7 +1918,7 @@ err_drop_frame:
                                goto err_drop_frame;
 
                        dma_sync_single_range_for_cpu(dev->dev.parent,
-                                                     rx_desc->buf_phys_addr,
+                                                     phys_addr,
                                                      MVNETA_MH_SIZE + NET_SKB_PAD,
                                                      rx_bytes,
                                                      DMA_FROM_DEVICE);