aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/ports/STM32/LLD/DMAv2/stm32_dma.c
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal/ports/STM32/LLD/DMAv2/stm32_dma.c')
-rw-r--r--os/hal/ports/STM32/LLD/DMAv2/stm32_dma.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/os/hal/ports/STM32/LLD/DMAv2/stm32_dma.c b/os/hal/ports/STM32/LLD/DMAv2/stm32_dma.c
index c048036a8..1a214fb70 100644
--- a/os/hal/ports/STM32/LLD/DMAv2/stm32_dma.c
+++ b/os/hal/ports/STM32/LLD/DMAv2/stm32_dma.c
@@ -507,6 +507,7 @@ const stm32_dma_stream_t *dmaStreamAllocI(uint32_t id,
startid = id;
endid = id;
}
+#if STM32_DMA_SUPPORTS_DMAMUX == TRUE
else if (id == STM32_DMA_STREAM_ID_ANY) {
startid = 0U;
endid = STM32_DMA_STREAMS - 1U;
@@ -519,6 +520,7 @@ const stm32_dma_stream_t *dmaStreamAllocI(uint32_t id,
startid = (STM32_DMA_STREAMS / 2U) - 1U;
endid = STM32_DMA_STREAMS - 1U;
}
+#endif
else {
osalDbgCheck(false);
}
@@ -531,7 +533,7 @@ const stm32_dma_stream_t *dmaStreamAllocI(uint32_t id,
/* Installs the DMA handler.*/
dma.streams[i].func = func;
dma.streams[i].param = param;
- dma.allocated_mask |= mask;
+ dma.allocated_mask |= mask;
/* Enabling DMA clocks required by the current streams set.*/
if ((STM32_DMA1_STREAMS_MASK & mask) != 0U) {