Skip to content

Commit 3fafe7f

Browse files
FRASTMcarlescufi
authored andcommitted
drivers: dma: new dma peripheral driver for stm32u5
It includes the definition for the DMA peripheral of this type, present on stm32U5 devices. A particular DMA_STM32U5 config is selected for that purpose. The driver is derived from the existing dma_stm32.c The GPDMA is counting channels (0-15) ; stream offset is 0. Signed-off-by: Francois Ramu <[email protected]>
1 parent 77b3ab0 commit 3fafe7f

File tree

5 files changed

+756
-9
lines changed

5 files changed

+756
-9
lines changed

drivers/dma/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
zephyr_library()
44

55
zephyr_library_sources_ifdef(CONFIG_DMA_SAM_XDMAC dma_sam_xdmac.c)
6+
zephyr_library_sources_ifdef(CONFIG_DMA_STM32U5 dma_stm32u5.c)
67
zephyr_library_sources_ifdef(CONFIG_DMA_STM32 dma_stm32.c)
78
zephyr_library_sources_ifdef(CONFIG_DMA_STM32_V1 dma_stm32_v1.c)
89
zephyr_library_sources_ifdef(CONFIG_DMA_STM32_V2 dma_stm32_v2.c)

drivers/dma/Kconfig.stm32

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,24 @@ DT_COMPAT_ST_STM32_DMA_V1 := st,stm32-dma-v1
88
DT_COMPAT_ST_STM32_DMA_V2 := st,stm32-dma-v2
99
DT_COMPAT_ST_STM32_DMA_V2BIS := st,stm32-dma-v2bis
1010
DT_COMPAT_ST_STM32_DMAMUX := st,stm32-dmamux
11+
DT_COMPAT_ST_STM32U5_DMA := st,stm32u5-dma
1112

1213
config DMA_STM32
1314
bool "STM32 DMA driver"
1415
select USE_STM32_LL_DMA
1516
depends on SOC_FAMILY_STM32
17+
default y if !$(dt_compat_enabled,$(DT_COMPAT_ST_STM32U5_DMA))
1618
help
17-
DMA driver for STM32 series SoCs.
19+
Driver for STM32 DMA V1, V2 and V2bis types.
20+
21+
config DMA_STM32U5
22+
bool "STM32U5 serie DMA driver"
23+
select USE_STM32_LL_DMA
24+
depends on SOC_FAMILY_STM32
25+
default y if $(dt_compat_enabled,$(DT_COMPAT_ST_STM32U5_DMA))
26+
help
27+
Enable DMA support mainly for stm32U5 family.
28+
It differs from the DMA driver due to the GPDMA peripheral.
1829

1930
if DMA_STM32
2031

0 commit comments

Comments
 (0)