Skip to content

SPI DMA with SPI FLASH not working for STM32H7XX #83124

@bhardadinesh-eaton

Description

@bhardadinesh-eaton

Describe the bug
SPI DMA with serial flash not working for STM32H7XX due to cache memory validation which got added in this PR,
#57786

To Reproduce

Steps to reproduce the behavior:

  1. We have tested this example with some modification for NUCLEO STM32H743ZI with Click 11 ( External Flash - https://www.mikroe.com/flash-11-click) for this https://github.com/zephyrproject-rtos/zephyr/tree/v3.6.0/samples/drivers/spi_flash
  2. I will attached the modified code soon.
  3. In Project Config ( Prj.conf ), If we disable this CONFIG_SPI_STM32_DMA=n, SPI Flash is working.
  4. In Project Config ( Prj.conf ), If we enable this CONFIG_SPI_STM32_DMA=y, SPI Flash is not working.
  5. If we keep CONFIG_SPI_STM32_DMA=y and comment this code at line number 959 to 964, it is working
    image
  6. By further debugging, It is failing buf_within_nocache memory validation.
    image

Expected behavior
It should work with buf_within_nocache along with SPI DMA

Logs and console output
Not working Logs :
image

Working Logs after commenting below code :
image

Environment (please complete the following information):

  • OS: Windows
  • Toolchain : Zephyr SDK, ...
  • Commit SHA or Version used : Zephyr v3.6.0

cc : @darshanmirajkar-eaton

Metadata

Metadata

Assignees

Labels

StaleWaiting for responseWaiting for author's responsebugThe issue is a bug, or the PR is fixing a bugplatform: STM32ST Micro STM32priority: lowLow impact/importance bug

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions