net: mvpp2: do not unmap TSO headers buffers
authorAntoine Tenart <antoine.tenart@free-electrons.com>
Mon, 23 Oct 2017 13:24:30 +0000 (15:24 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 24 Oct 2017 09:34:09 +0000 (18:34 +0900)
commit20920267885218fda08dc12c7d3814938ab15b54
treea403563fb4e08b177fd2f8564d7a84e6f171d512
parent822eaf7cfb7c4783375bceadbc7651137346ac00
net: mvpp2: do not unmap TSO headers buffers

The TSO header buffers are coming from a per cpu pool and should not
be unmapped as they are reused. The PPv2 driver was unmapping all
descriptors buffers unconditionally. This patch fixes this by checking
the buffers dma addresses before unmapping them, and by not unmapping
those who are located in the TSO header pool.

Fixes: 186cd4d4e414 ("net: mvpp2: software tso support")
Signed-off-by: Antoine Tenart <antoine.tenart@free-electrons.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/mvpp2.c