aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/platforms/STM32/spi_lld.h
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal/platforms/STM32/spi_lld.h')
-rw-r--r--os/hal/platforms/STM32/spi_lld.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/os/hal/platforms/STM32/spi_lld.h b/os/hal/platforms/STM32/spi_lld.h
index c18c47853..8748962f2 100644
--- a/os/hal/platforms/STM32/spi_lld.h
+++ b/os/hal/platforms/STM32/spi_lld.h
@@ -30,6 +30,10 @@
#if CH_HAL_USE_SPI || defined(__DOXYGEN__)
/*===========================================================================*/
+/* Driver constants. */
+/*===========================================================================*/
+
+/*===========================================================================*/
/* Driver pre-compile time settings. */
/*===========================================================================*/
@@ -106,6 +110,14 @@
#endif
/*===========================================================================*/
+/* Derived constants and error checks. */
+/*===========================================================================*/
+
+#if SPI_USE_MUTUAL_EXCLUSION && !CH_USE_MUTEXES && !CH_USE_SEMAPHORES
+#error "SPI_USE_MUTUAL_EXCLUSION requires CH_USE_MUTEXES and/or CH_USE_SEMAPHORES"
+#endif
+
+/*===========================================================================*/
/* Driver data structures and types. */
/*===========================================================================*/