stm32h7:DMA BDMA does not auto disabled on completion

This commit is contained in:
David Sidrane 2021-03-22 11:12:13 -07:00 committed by Xiang Xiao
parent 37300a43a5
commit 9800256507

View File

@ -1841,6 +1841,10 @@ static void stm32_bdma_setup(DMA_HANDLE handle, FAR stm32_dmacfg_t *cfg)
* for the EN bit to be cleared before starting any stream configuration." * for the EN bit to be cleared before starting any stream configuration."
*/ */
regval = dmachan_getreg(dmachan, STM32_BDMACH_CCR_OFFSET);
regval &= ~BDMA_CCR_EN;
dmachan_putreg(dmachan, STM32_BDMACH_CCR_OFFSET, regval);
while ((dmachan_getreg(dmachan, STM32_BDMACH_CCR_OFFSET) & while ((dmachan_getreg(dmachan, STM32_BDMACH_CCR_OFFSET) &
BDMA_CCR_EN) != 0); BDMA_CCR_EN) != 0);