summaryrefslogtreecommitdiff
path: root/drivers/dma/sh
diff options
context:
space:
mode:
authorMaxime Ripard <maxime.ripard@free-electrons.com>2014-07-30 08:30:23 (GMT)
committerVinod Koul <vinod.koul@intel.com>2014-07-30 13:44:17 (GMT)
commit4fbd804e009ae9dff29dcb1fbfa0aaffd3992880 (patch)
tree13ca8845a4d581ce90a25e779cb87667d078babf /drivers/dma/sh
parent174427c1bb9e7810743f55a90a64da2c29d67b0b (diff)
downloadlinux-4fbd804e009ae9dff29dcb1fbfa0aaffd3992880.tar.xz
dmaengine: sun6i: Fix memory leaks
The sun6i_dma_prep_memcpy and sun6i_dma_prep_slave_sg functions were both leaking the descriptor they allocated if an error was happening after a successful dma_pool_alloc call. It also fixes a memleak that was happening in the scatter gather list traversal, that was allocating as much descriptor as there was scatter gather items, but only freeing the current descriptor if an error was to arise. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Diffstat (limited to 'drivers/dma/sh')
0 files changed, 0 insertions, 0 deletions