This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit af4d65416a06774dcd3a15f16222934e7636cf5d
Author: raiden00pl <raide...@railab.me>
AuthorDate: Wed Jul 20 16:41:02 2022 +0200

    stm32f0l0g0/stm32_spi.c: add missing SPI mode config and fix ifdef
---
 arch/arm/src/stm32f0l0g0/stm32_spi.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/arch/arm/src/stm32f0l0g0/stm32_spi.c 
b/arch/arm/src/stm32f0l0g0/stm32_spi.c
index ccf2fe0a88..a814dbc3c6 100644
--- a/arch/arm/src/stm32f0l0g0/stm32_spi.c
+++ b/arch/arm/src/stm32f0l0g0/stm32_spi.c
@@ -325,6 +325,7 @@ static struct stm32_spidev_s g_spi1dev =
 #ifdef CONFIG_PM
   .pm_cb.prepare = spi_pm_prepare,
 #endif
+  .config   = CONFIG_STM32F0L0G0_SPI1_COMMTYPE,
 };
 #endif
 
@@ -378,6 +379,7 @@ static struct stm32_spidev_s g_spi2dev =
 #ifdef CONFIG_PM
   .pm_cb.prepare = spi_pm_prepare,
 #endif
+  .config   = CONFIG_STM32F0L0G0_SPI2_COMMTYPE,
 };
 #endif
 
@@ -1979,7 +1981,7 @@ struct spi_dev_s *stm32_spibus_initialize(int bus)
       goto errout;
     }
 
-#ifdef CONFIG_STM32L4_SPI_DMA
+#ifdef CONFIG_STM32F0L0G0_SPI_DMA
   /* SPI DMA supported only for full-duplex mode */
 
   if (priv->rxch && priv->txch && priv->config != FULL_DUPLEX)

Reply via email to