-
Florian Fainelli authored
commit 8c4799ac upstream. __bcmgenet_tx_reclaim() and bcmgenet_free_rx_buffers() are not using the same struct device during unmap that was used for the map operation, which makes DMA-API debugging warn about it. Fix this by always using &priv->pdev->dev throughout the driver, using an identical device reference for all map/unmap calls. Fixes: 1c1008c7 ("net: bcmgenet: add main driver file") Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> [bwh: Backported to 3.16: - Adjust context - Also fix call from bcmgenet_desc_rx(), fixed upstream in commit d6707bec "net: bcmgenet: rewrite bcmgenet_rx_refill()"] Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
a0579d7e