← index #6257PR #17578
Likely Duplicate · high · value 3.633
QUERY · ISSUE

STM32H7 SPI6 not working with DMA

openby rcordeauopened 2020-07-19updated 2026-01-14
port-stm32

Hi,
I was trying this out on a custom board as well as the Nucleo STM32H743SZI board, and while SPI3 works when sending multiple bytes (default behavior when sending more than 1 byte seems to be to use DMA per spi.c), when it comes to SPI6, it uses a different DMA engine (DMA2) and goes through a mux BDMA_REQUEST_SPI6_TX/RX. I keep getting a ETIMEDOUT error due to waiting for the interrupt to come back from the DMA transaction. Any advice, or could this be a bug?

Thanks,
Rob

CANDIDATE · PULL REQUEST

stm32: Change SPI IRQ priority.

mergedby yn386opened 2025-06-29updated 2025-07-08
port-stm32

Summary

On STM32H5/H7, SPI flash cannot use as storage device with DMA.
SPI interruption may not be genearated even if DMA transfer has been done.
This is due to lower priority of SPI interruption than DMA.

This PR changes SPI interrupt priority more higher than DMA's priority.

Testing

Tested:

  • NUCLEO-H563ZI with W25Q32BVSSIG
  • Custom STM32H723VG board with W25Q64JVSIQ

Trade-offs and Alternatives

There is no negative impact because only STM32H5/H7 HAL requires SPI IRQs to be enabled and handled.

Keyboard

j / / n
next pair
k / / p
previous pair
1 / / h
show query pane
2 / / l
show candidate pane
c
copy suggested comment
r
toggle reasoning
g i
go to index
?
show this help
esc
close overlays

press ? or esc to close

copied