memc: stm32_xspi_psram: Fix compilation issues for STM32H5 series#99194
memc: stm32_xspi_psram: Fix compilation issues for STM32H5 series#99194tpambor wants to merge 3 commits intozephyrproject-rtos:mainfrom
Conversation
erwango
left a comment
There was a problem hiding this comment.
Thanks. Btw, it is rather more adding driver support to H5 than fixing a mere bug. Also, it would be nice to be sure there is a configuration in tree allowing to build it. Can it be enabled on a board ? If not, would you mind providing a configuration in tests/drivers/build_all
JarmouniA
left a comment
There was a problem hiding this comment.
H5 has an OctoSPI controller (that's XSPI (JESD251C) standard compliant, which is not the same as having an XSPI controller like the N6 for ex.), that's why many things aren't available in the HAL.
To me, this driver should be checking the compatible of the parent of its device node, and decide what to use based on that.
@JarmouniA Regarding XSPI Manager and related features, I followed how it is done for the flash side in zephyr/drivers/flash/flash_stm32_xspi.c Lines 2522 to 2526 in 2a9f214 With respect to 16-bit IO support, this could be handled differently. Currently, this driver only handles AP PSRAMs (
@erwango I am not aware of a board with STM32H5 and PSRAM in-tree, so I will add it to |
etienne-lms
left a comment
There was a problem hiding this comment.
For consistency in commit message header lines, prefer
drivers: memc: stm32xspi_psram: ...
… chip The STM32H5 series has only a single XSPI interface and does not support the XSPI manager or the related `MaxTran` parameter. Configure these only if they are supported by the chip. Signed-off-by: Tim Pambor <tim.pambor@codewrights.de>
…chip XSPI on STM32H5 series does not support 16-bit mode. Guard relevant code behind preprocessor checks to avoid compilation issues. Signed-off-by: Tim Pambor <tim.pambor@codewrights.de>
Add a new build test for the stm32-xspi-psram peripheral for the stm32h573i_dk and stm32h7s78_dk boards. Signed-off-by: Tim Pambor <tim.pambor@codewrights.de>
59ffb33 to
9c624d0
Compare
|
Long term solution on this is to make use of upcoming MSPI API, which splits device and controllers implementations. See |
Thanks for pointing this out. I wasn’t aware of that PR. The MSPI API approach definitely seems like the right direction. I will look into utilizing it to add support for additional PSRAMs. |
|
#96670 has now been merged. |



The STM32H5 series has only a single XSPI interface and does not support the XSPI manager, the related
MaxTranparameter and 16-bit IO. Configure these only if they are supported by the chip.Fixes #99191