This is an automated email from the ASF dual-hosted git repository. GUIDINGLI pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/nuttx.git
commit 10ead674c76b7707966ea2110601a329c7fb1234 Author: raiden00pl <[email protected]> AuthorDate: Wed Nov 4 12:36:04 2026 +0100 arch/arm/stm32: Clean the GPDMA linked list items from the data cache. In circular mode the GPDMA fetches the linked list items from memory. With a write-back data cache the CPU writes may still be in the cache when the channel starts. Assisted-by: Claude:claude-fable-5-1 Signed-off-by: raiden00pl <[email protected]> --- arch/arm/src/common/stm32/stm32_dma_gpdma.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/arm/src/common/stm32/stm32_dma_gpdma.c b/arch/arm/src/common/stm32/stm32_dma_gpdma.c index 39699b5f4d4..7a03d82ecf0 100644 --- a/arch/arm/src/common/stm32/stm32_dma_gpdma.c +++ b/arch/arm/src/common/stm32/stm32_dma_gpdma.c @@ -34,6 +34,7 @@ #include <nuttx/irq.h> #include <nuttx/arch.h> +#include <nuttx/cache.h> #include <nuttx/signal.h> #include "arm_internal.h" @@ -461,6 +462,10 @@ static int gpdma_setup_circular(struct gpdma_ch_s *chan, lli[1].llr = (lli[0].llr & ~GPDMA_CXLLR_LA_MASK) | (((uint32_t)&lli[0]) & GPDMA_CXLLR_LA_MASK); + /* The GPDMA fetches the linked list items from memory */ + + up_clean_dcache((uintptr_t)&lli[0], (uintptr_t)&lli[2]); + gpdmach_putreg(chan, CH_CXSAR_OFFSET, lli[0].sar); gpdmach_putreg(chan, CH_CXDAR_OFFSET, lli[0].dar); gpdmach_putreg(chan, CH_CXTR1_OFFSET, lli[0].tr1);
