mbox series

[0/5] virt-dma and i.MX SDMA fixes

Message ID 20191206135344.29330-1-s.hauer@pengutronix.de (mailing list archive)
Headers show
Series virt-dma and i.MX SDMA fixes | expand

Message

Sascha Hauer Dec. 6, 2019, 1:53 p.m. UTC
The i.MX SDMA driver leaks memory when a currently running descriptor is
aborted. Calling vchan_terminate_vdesc() on it to fix this revealed that
the virt-dma support calls the desc_free with the spin_lock held. This
doesn't work for the SDMA driver because it calls dma_free_coherent in
its desc_free hook. This series aims to fix that up.

Sascha

Sascha Hauer (5):
  dmaengine: virt-dma: Add missing locking around list operations
  dmaengine: virt-dma: Do not call desc_free() under a spin_lock
  dmaengine: imx-sdma: rename function
  dmaengine: imx-sdma: find desc first in sdma_tx_status
  dmaengine: imx-sdma: Fix memory leak

 drivers/dma/imx-sdma.c | 37 ++++++++++++++++++++++---------------
 drivers/dma/virt-dma.c |  1 +
 drivers/dma/virt-dma.h | 26 ++++++++++----------------
 3 files changed, 33 insertions(+), 31 deletions(-)