From ebd2416f9d5d76b793ffcdbf56c47fce815b021a Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Sun, 9 Apr 2017 11:47:57 -0600 Subject: [PATCH] stm32 COMP: Logic in stm32_comp.h must be configured on CONFIG_STM32_COMP or otherwise it causes an error via #error on every platform without COMP support. --- arch/arm/src/stm32/stm32_comp.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/src/stm32/stm32_comp.h b/arch/arm/src/stm32/stm32_comp.h index 16a0ad69713..ab28cac186a 100644 --- a/arch/arm/src/stm32/stm32_comp.h +++ b/arch/arm/src/stm32/stm32_comp.h @@ -44,6 +44,8 @@ #include "chip.h" +#ifdef CONFIG_STM32_COMP + #if defined(CONFIG_STM32_STM32F30XX) # error "COMP support for STM32F30XX not implemented yet" #elif defined(CONFIG_STM32_STM32F33XX) @@ -211,4 +213,5 @@ FAR struct comp_dev_s* stm32_compinitialize(int intf); #endif #endif /* __ASSEMBLY__ */ +#endif /* CONFIG_STM23_COMP */ #endif /* __ARCH_ARM_SRC_STM32_STM32_COMP_H */