Skip to content

Commit 383baf5

Browse files
Mrinmay Sarkarvinodkoul
authored andcommitted
dmaengine: dw-edma: Fix unmasking STOP and ABORT interrupts for HDMA
The current logic is enabling both STOP_INT_MASK and ABORT_INT_MASK bit. This is apparently masking those particular interrupts rather than unmasking the same. If the interrupts are masked, they would never get triggered. So fix the issue by unmasking the STOP and ABORT interrupts properly. Fixes: e74c395 ("dmaengine: dw-edma: Add support for native HDMA") cc: [email protected] Signed-off-by: Mrinmay Sarkar <[email protected]> Reviewed-by: Manivannan Sadhasivam <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Vinod Koul <[email protected]>
1 parent b53b831 commit 383baf5

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

drivers/dma/dw-edma/dw-hdma-v0-core.c

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -247,10 +247,11 @@ static void dw_hdma_v0_core_start(struct dw_edma_chunk *chunk, bool first)
247247
if (first) {
248248
/* Enable engine */
249249
SET_CH_32(dw, chan->dir, chan->id, ch_en, BIT(0));
250-
/* Interrupt enable&unmask - done, abort */
251-
tmp = GET_CH_32(dw, chan->dir, chan->id, int_setup) |
252-
HDMA_V0_STOP_INT_MASK | HDMA_V0_ABORT_INT_MASK |
253-
HDMA_V0_LOCAL_STOP_INT_EN | HDMA_V0_LOCAL_ABORT_INT_EN;
250+
/* Interrupt unmask - stop, abort */
251+
tmp = GET_CH_32(dw, chan->dir, chan->id, int_setup);
252+
tmp &= ~(HDMA_V0_STOP_INT_MASK | HDMA_V0_ABORT_INT_MASK);
253+
/* Interrupt enable - stop, abort */
254+
tmp |= HDMA_V0_LOCAL_STOP_INT_EN | HDMA_V0_LOCAL_ABORT_INT_EN;
254255
if (!(dw->chip->flags & DW_EDMA_CHIP_LOCAL))
255256
tmp |= HDMA_V0_REMOTE_STOP_INT_EN | HDMA_V0_REMOTE_ABORT_INT_EN;
256257
SET_CH_32(dw, chan->dir, chan->id, int_setup, tmp);

0 commit comments

Comments
 (0)