Skip to content

Commit 5c8aacb

Browse files
saschahauervinodkoul
authored andcommitted
dmaengine: bcm2835: do not call vchan_vdesc_fini() with lock held
vchan_vdesc_fini() can't be called locked. Instead, call vchan_terminate_vdesc() which delays the freeing of the descriptor to vchan_synchronize(). Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Link: https://lore.kernel.org/r/20191216105328.15198-2-s.hauer@pengutronix.de Signed-off-by: Vinod Koul <vkoul@kernel.org>
1 parent 08baca4 commit 5c8aacb

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

‎drivers/dma/bcm2835-dma.c‎

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -797,10 +797,7 @@ static int bcm2835_dma_terminate_all(struct dma_chan *chan)
797797

798798
/* stop DMA activity */
799799
if (c->desc) {
800-
if (c->desc->vd.tx.flags & DMA_PREP_INTERRUPT)
801-
vchan_terminate_vdesc(&c->desc->vd);
802-
else
803-
vchan_vdesc_fini(&c->desc->vd);
800+
vchan_terminate_vdesc(&c->desc->vd);
804801
c->desc = NULL;
805802
bcm2835_dma_abort(c);
806803
}

0 commit comments

Comments
 (0)