Skip to content

Commit b3072be

Browse files
miquelraynalvinodkoul
authored andcommitted
dmaengine: xilinx: xdma: Better handling of the busy variable
The driver internal scatter-gather logic is: * set busy to true * start transfer <irq> * set busy to false * trigger next transfer if any * set busy to true </irq> Setting busy to false in cyclic transfers does not make any sense and is conceptually wrong. In order to ease the integration of additional callbacks let's move this change to the scatter-gather path. Signed-off-by: Miquel Raynal <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Vinod Koul <[email protected]>
1 parent 58b61fc commit b3072be

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/dma/xilinx/xdma.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -745,7 +745,6 @@ static irqreturn_t xdma_channel_isr(int irq, void *dev_id)
745745
if (!vd)
746746
goto out;
747747

748-
xchan->busy = false;
749748
desc = to_xdma_desc(vd);
750749
xdev = xchan->xdev_hdl;
751750

@@ -766,6 +765,7 @@ static irqreturn_t xdma_channel_isr(int irq, void *dev_id)
766765

767766
vchan_cyclic_callback(vd);
768767
} else {
768+
xchan->busy = false;
769769
desc->completed_desc_num += complete_desc_num;
770770

771771
/* if all data blocks are transferred, remove and complete the request */

0 commit comments

Comments
 (0)