diff --git a/arch/arm/src/efm32/efm32_adc.c b/arch/arm/src/efm32/efm32_adc.c index 032f92a655..53cb731ad6 100644 --- a/arch/arm/src/efm32/efm32_adc.c +++ b/arch/arm/src/efm32/efm32_adc.c @@ -65,9 +65,9 @@ #include "efm32.h" #include "efm32_adc.h" -/* ADC "upper half" support must be enabled */ +/* ADC "lower half" support must be enabled */ -#ifdef CONFIG_ADC +#ifdef CONFIG_EFM32_ADC /* Some ADC peripheral must be enabled */ @@ -1316,4 +1316,4 @@ struct adc_dev_s *efm32_adcinitialize(int intf, const uint8_t *chanlist, int nch #endif /* CONFIG_EFM32_EFM32GG */ #endif /* CONFIG_EFM32_ADC1 */ -#endif /* CONFIG_ADC */ +#endif /* CONFIG_EFM32_ADC */ diff --git a/arch/arm/src/stm32/Make.defs b/arch/arm/src/stm32/Make.defs index 3d225f31ef..98c1bad646 100644 --- a/arch/arm/src/stm32/Make.defs +++ b/arch/arm/src/stm32/Make.defs @@ -203,7 +203,7 @@ CHIP_CSRCS += stm32_rtc_lowerhalf.c endif endif -ifeq ($(CONFIG_ADC),y) +ifeq ($(CONFIG_STM32_ADC),y) CHIP_CSRCS += stm32_adc.c endif diff --git a/arch/arm/src/stm32/stm32_adc.c b/arch/arm/src/stm32/stm32_adc.c index 4b81f63145..c24a98dbc7 100644 --- a/arch/arm/src/stm32/stm32_adc.c +++ b/arch/arm/src/stm32/stm32_adc.c @@ -69,7 +69,7 @@ /* ADC "upper half" support must be enabled */ -#ifdef CONFIG_ADC +#ifdef CONFIG_STM32_ADC /* Some ADC peripheral must be enabled */ @@ -3046,4 +3046,4 @@ struct adc_dev_s *stm32_adcinitialize(int intf, FAR const uint8_t *chanlist, #endif /* CONFIG_STM32_ADC1 || CONFIG_STM32_ADC2 || * CONFIG_STM32_ADC3 || CONFIG_STM32_ADC4 */ -#endif /* CONFIG_ADC */ +#endif /* CONFIG_STM32_ADC */ diff --git a/arch/arm/src/tiva/tiva_adc.h b/arch/arm/src/tiva/tiva_adc.h index b5ba304518..693252ad35 100644 --- a/arch/arm/src/tiva/tiva_adc.h +++ b/arch/arm/src/tiva/tiva_adc.h @@ -165,16 +165,11 @@ extern "C" #define EXTERN extern #endif -/**************************************************************************** - * Inline Functions - ****************************************************************************/ - /**************************************************************************** * Public Function Prototypes ****************************************************************************/ -/* Only allow access to upper level ADC drivers if they are enabled */ -#ifdef CONFIG_ADC +#ifdef CONFIG_TIVA_ADC /**************************************************************************** * Driver Function Prototypes @@ -228,7 +223,7 @@ void tiva_adc_lock(FAR struct tiva_adc_s *priv, int sse); void tiva_adc_unlock(FAR struct tiva_adc_s *priv, int sse); -#endif /* CONFIG_ADC */ +#endif /* CONFIG_TIVA_ADC */ /**************************************************************************** * Library Function Prototypes diff --git a/arch/arm/src/tiva/tiva_adclow.c b/arch/arm/src/tiva/tiva_adclow.c index e8a9d53d5c..7a0b5509ce 100644 --- a/arch/arm/src/tiva/tiva_adclow.c +++ b/arch/arm/src/tiva/tiva_adclow.c @@ -82,7 +82,7 @@ #include "chip/tiva_pinmap.h" #include "chip/tiva_syscontrol.h" -#if defined (CONFIG_TIVA_ADC) && defined (CONFIG_ADC) +#ifdef CONFIG_TIVA_ADC /**************************************************************************** * Pre-processor Definitions @@ -1086,4 +1086,4 @@ static void tiva_adc_dump_dev(void) } #endif -#endif /* CONFIG_TIVA_ADC && CONFIG_ADC */ +#endif /* CONFIG_TIVA_ADC */