drivers: dma: stm32 dma of type V1 with mux
This is the configuration of the stm32h723 where the dma1 & dma2 of type V1 with a MUX. Even if DMA is of type V1, the 'feature' does not exist with DMAMUX Signed-off-by: Francois Ramu <francois.ramu@st.com>
This commit is contained in:
parent
dba4e63c41
commit
c4161024c4
2 changed files with 12 additions and 2 deletions
|
@ -48,6 +48,9 @@ struct dma_stm32_config {
|
|||
/* from DTS the dma stream id is in range 1..<dma-requests> */
|
||||
/* so decrease to set range from 0 from now on */
|
||||
#define STREAM_OFFSET 1
|
||||
#elif defined(CONFIG_DMA_STM32_V1) && defined(CONFIG_DMAMUX_STM32)
|
||||
/* typically on the stm32H7 serie, DMA V1 with mux */
|
||||
#define STREAM_OFFSET 1
|
||||
#else
|
||||
/* from DTS the dma stream id is in range 0..<dma-requests>-1 */
|
||||
#define STREAM_OFFSET 0
|
||||
|
|
|
@ -19,12 +19,19 @@
|
|||
#define STM32_DMA_SLOT(id, dir, slot) DT_INST_DMAS_CELL_BY_NAME(id, dir, slot)
|
||||
#endif
|
||||
|
||||
#define STM32_DMA_CHANNEL_CONFIG(id, dir) \
|
||||
DT_INST_DMAS_CELL_BY_NAME(id, dir, channel_config)
|
||||
#if DT_HAS_COMPAT_STATUS_OKAY(st_stm32_dma_v2) || \
|
||||
DT_HAS_COMPAT_STATUS_OKAY(st_stm32_dma_v2bis) || \
|
||||
DT_HAS_COMPAT_STATUS_OKAY(st_stm32_dmamux)
|
||||
#define STM32_DMA_FEATURES(id, dir) 0
|
||||
#else
|
||||
#define STM32_DMA_FEATURES(id, dir) \
|
||||
DT_INST_DMAS_CELL_BY_NAME(id, dir, features)
|
||||
#endif
|
||||
|
||||
#define STM32_DMA_CTLR(id, dir) \
|
||||
DT_INST_DMAS_CTLR_BY_NAME(id, dir)
|
||||
#define STM32_DMA_CHANNEL_CONFIG(id, dir) \
|
||||
DT_INST_DMAS_CELL_BY_NAME(id, dir, channel_config)
|
||||
|
||||
/* macros for channel-config */
|
||||
/* direction defined on bits 6-7 */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue