projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
981703a
)
dmaengine: stm32-dma: mark pending descriptor complete in terminate_all
author
Amelie Delaunay
<amelie.delaunay@foss.st.com>
Mon, 11 Oct 2021 09:42:57 +0000
(11:42 +0200)
committer
Vinod Koul
<vkoul@kernel.org>
Mon, 18 Oct 2021 06:42:50 +0000
(12:12 +0530)
To prevent accidental repeated completion, mark pending descriptor
complete in terminate_all. It can be the case when terminate_all is called
while no end of transfer interrupt occurs.
Signed-off-by: Amelie Delaunay <amelie.delaunay@foss.st.com>
Link:
https://lore.kernel.org/r/20211011094259.315023-2-amelie.delaunay@foss.st.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/dma/stm32-dma.c
patch
|
blob
|
history
diff --git
a/drivers/dma/stm32-dma.c
b/drivers/dma/stm32-dma.c
index 9063c727962ed5fca8d143fb9ec955f6f71a7ef7..a5ccf3fa95e0aae5261eac96cd602c696c1491c5 100644
(file)
--- a/
drivers/dma/stm32-dma.c
+++ b/
drivers/dma/stm32-dma.c
@@
-497,6
+497,7
@@
static int stm32_dma_terminate_all(struct dma_chan *c)
spin_lock_irqsave(&chan->vchan.lock, flags);
if (chan->desc) {
+ dma_cookie_complete(&chan->desc->vdesc.tx);
vchan_terminate_vdesc(&chan->desc->vdesc);
if (chan->busy)
stm32_dma_stop(chan);