diff --git a/tests/drivers/spi/spi_loopback/overlay-stm32-spi-dma.conf b/tests/drivers/spi/spi_loopback/overlay-stm32-spi-dma.conf new file mode 100644 index 00000000000..3ce3d8ee097 --- /dev/null +++ b/tests/drivers/spi/spi_loopback/overlay-stm32-spi-dma.conf @@ -0,0 +1,5 @@ +# enable DMA mode for SPI loopback test +CONFIG_SPI_LOOPBACK_DRV_NAME="SPI_1" +CONFIG_SPI_STM32_DMA=y +CONFIG_SPI_STM32_INTERRUPT=n +CONFIG_SPI_ASYNC=n diff --git a/tests/drivers/spi/spi_loopback/overlay-stm32-spi.conf b/tests/drivers/spi/spi_loopback/overlay-stm32-spi.conf new file mode 100644 index 00000000000..733137888e3 --- /dev/null +++ b/tests/drivers/spi/spi_loopback/overlay-stm32-spi.conf @@ -0,0 +1,2 @@ +# enable stm32 spi instance for loopback test +CONFIG_SPI_LOOPBACK_DRV_NAME="SPI_1" diff --git a/tests/drivers/spi/spi_loopback/testcase.yaml b/tests/drivers/spi/spi_loopback/testcase.yaml index 08841e4637e..6653d80acca 100644 --- a/tests/drivers/spi/spi_loopback/testcase.yaml +++ b/tests/drivers/spi/spi_loopback/testcase.yaml @@ -6,6 +6,7 @@ common: tests: drivers.spi.loopback: harness: ztest + filter: not CONFIG_SOC_FAMILY_STM32 harness_config: fixture: spi_loopback driver.spi.loopback.internal: @@ -17,3 +18,18 @@ tests: harness_config: fixture: spi_loopback platform_allow: frdm_k64f + drivers.stm32_spi.loopback: + harness: ztest + extra_args: OVERLAY_CONFIG="overlay-stm32-spi.conf" + harness_config: + fixture: spi_loopback + filter: CONFIG_SOC_FAMILY_STM32 + drivers.stm32_spi_dma.loopback: + tags: dma + harness: ztest + harness_config: + fixture: spi_loopback + extra_args: OVERLAY_CONFIG="overlay-stm32-spi-dma.conf" + filter: CONFIG_SOC_FAMILY_STM32 + platform_allow: nucleo_g474re nucleo_f207zg nucleo_f429zi nucleo_f746zg nucleo_wb55rg + nucleo_wl55jc nucleo_h743zi