dpaa_eth: fix DMA mapping leak
authorMadalin Bucur <madalin.bucur@oss.nxp.com>
Mon, 23 Dec 2019 07:39:22 +0000 (09:39 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 26 Dec 2019 23:11:31 +0000 (15:11 -0800)
commitc27569fcd6e1b11bd24361346504f2995a256e4e
treea6d6860fd51f9813abba03d67f5d4cd7bf3036ad
parentec34c0157580a68c10dccbdd18c7701f0b317172
dpaa_eth: fix DMA mapping leak

On the error path some fragments remain DMA mapped. Adding a fix
that unmaps all the fragments. Rework cleanup path to be simpler.

Fixes: 8151ee88bad5 ("dpaa_eth: use page backed rx buffers")
Signed-off-by: Madalin Bucur <madalin.bucur@oss.nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/freescale/dpaa/dpaa_eth.c