aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/platforms/STM32/adc_lld.h
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal/platforms/STM32/adc_lld.h')
-rw-r--r--os/hal/platforms/STM32/adc_lld.h10
1 files changed, 7 insertions, 3 deletions
diff --git a/os/hal/platforms/STM32/adc_lld.h b/os/hal/platforms/STM32/adc_lld.h
index 6f93170ed..3cc34735f 100644
--- a/os/hal/platforms/STM32/adc_lld.h
+++ b/os/hal/platforms/STM32/adc_lld.h
@@ -94,12 +94,12 @@
#endif
/**
- * @brief ADC1 DMA error hook.
+ * @brief ADC DMA error hook.
* @note The default action for DMA errors is a system halt because DMA
* error can only happen because programming errors.
*/
-#if !defined(STM32_ADC1_DMA_ERROR_HOOK) || defined(__DOXYGEN__)
-#define STM32_ADC1_DMA_ERROR_HOOK() chSysHalt()
+#if !defined(STM32_ADC_DMA_ERROR_HOOK) || defined(__DOXYGEN__)
+#define STM32_ADC_DMA_ERROR_HOOK(adcp) chSysHalt()
#endif
/*===========================================================================*/
@@ -114,6 +114,10 @@
#error "ADC driver activated but no ADC peripheral assigned"
#endif
+#if !defined(STM32_DMA_REQUIRED)
+#define STM32_DMA_REQUIRED
+#endif
+
/*===========================================================================*/
/* Driver data structures and types. */
/*===========================================================================*/