EFM32: Add configuration option to use USARTs as SPI

This commit is contained in:
Gregory Nutt 2014-10-23 08:54:26 -06:00
parent 113483a177
commit eaa0b18c18
2 changed files with 12 additions and 12 deletions

View File

@ -103,7 +103,7 @@ ifneq ($(CONFIG_ARCH_IDLE_CUSTOM),y)
CHIP_CSRCS += efm32_idle.c CHIP_CSRCS += efm32_idle.c
endif endif
ifeq ($(CONFIG_EFM32_USART),y) ifeq ($(CONFIG_EFM32_USART_ISUART),y)
CHIP_CSRCS += efm32_serial.c CHIP_CSRCS += efm32_serial.c
else else
ifeq ($(CONFIG_EFM32_UART),y) ifeq ($(CONFIG_EFM32_UART),y)

View File

@ -66,10 +66,12 @@
# undef CONFIG_EFM32_LEUART1 # undef CONFIG_EFM32_LEUART1
#endif #endif
#ifndef CONFIG_EFM32_USART /* Is there a UART device? Or an SPI device? */
# undef CONFIG_EFM32_USART0
# undef CONFIG_EFM32_USART1 #ifndef CONFIG_EFM32_USART_ISUART
# undef CONFIG_EFM32_USART2 # undef CONFIG_EFM32_USART0_ISUART
# undef CONFIG_EFM32_USART1_ISUART
# undef CONFIG_EFM32_USART2_ISUART
#endif #endif
#ifndef CONFIG_EFM32_UART #ifndef CONFIG_EFM32_UART
@ -77,13 +79,6 @@
# undef CONFIG_EFM32_UART1 # undef CONFIG_EFM32_UART1
#endif #endif
#ifndef CONFIG_EFM32_LEUART
# undef CONFIG_EFM32_LEUART0
# undef CONFIG_EFM32_LEUART1
#endif
/* Is there a UART device? Or an SPI device? */
#ifndef CONFIG_EFM32_USART0 #ifndef CONFIG_EFM32_USART0
# undef CONFIG_EFM32_USART0_ISUART # undef CONFIG_EFM32_USART0_ISUART
# undef CONFIG_EFM32_USART0_ISSPI # undef CONFIG_EFM32_USART0_ISSPI
@ -117,6 +112,11 @@
/* Is there an LEUART device? */ /* Is there an LEUART device? */
#ifndef CONFIG_EFM32_LEUART
# undef CONFIG_EFM32_LEUART0
# undef CONFIG_EFM32_LEUART1
#endif
#undef HAVE_LEUART_DEVICE #undef HAVE_LEUART_DEVICE
#if defined(CONFIG_EFM32_LEUART0) || defined(CONFIG_EFM32_LEUART1) #if defined(CONFIG_EFM32_LEUART0) || defined(CONFIG_EFM32_LEUART1)
# define HAVE_LEUART_DEVICE 1 # define HAVE_LEUART_DEVICE 1