Change name IMX to IMX1 in configuration variable names to make room for i.MX6
This commit is contained in:
parent
0a9920a87a
commit
75973db9cc
@ -57,13 +57,13 @@ config ARCH_CHIP_EFM32
|
|||||||
---help---
|
---help---
|
||||||
Energy Micro EFM32 microcontrollers (ARM Cortex-M).
|
Energy Micro EFM32 microcontrollers (ARM Cortex-M).
|
||||||
|
|
||||||
config ARCH_CHIP_IMX
|
config ARCH_CHIP_IMX1
|
||||||
bool "Freescale iMX"
|
bool "Freescale iMX.1"
|
||||||
select ARCH_ARM920T
|
select ARCH_ARM920T
|
||||||
select ARCH_HAVE_HEAP2
|
select ARCH_HAVE_HEAP2
|
||||||
select ARCH_HAVE_LOWVECTORS
|
select ARCH_HAVE_LOWVECTORS
|
||||||
---help---
|
---help---
|
||||||
Freescale iMX architectures (ARM920T)
|
Freescale iMX.1 architectures (ARM920T)
|
||||||
|
|
||||||
config ARCH_CHIP_KINETIS
|
config ARCH_CHIP_KINETIS
|
||||||
bool "Freescale Kinetis"
|
bool "Freescale Kinetis"
|
||||||
@ -370,7 +370,7 @@ config ARCH_CHIP
|
|||||||
default "calypso" if ARCH_CHIP_CALYPSO
|
default "calypso" if ARCH_CHIP_CALYPSO
|
||||||
default "dm320" if ARCH_CHIP_DM320
|
default "dm320" if ARCH_CHIP_DM320
|
||||||
default "efm32" if ARCH_CHIP_EFM32
|
default "efm32" if ARCH_CHIP_EFM32
|
||||||
default "imx" if ARCH_CHIP_IMX
|
default "imx1" if ARCH_CHIP_IMX1
|
||||||
default "kinetis" if ARCH_CHIP_KINETIS
|
default "kinetis" if ARCH_CHIP_KINETIS
|
||||||
default "kl" if ARCH_CHIP_KL
|
default "kl" if ARCH_CHIP_KL
|
||||||
default "tiva" if ARCH_CHIP_LM || ARCH_CHIP_TIVA
|
default "tiva" if ARCH_CHIP_LM || ARCH_CHIP_TIVA
|
||||||
@ -554,8 +554,8 @@ endif
|
|||||||
if ARCH_CHIP_EFM32
|
if ARCH_CHIP_EFM32
|
||||||
source arch/arm/src/efm32/Kconfig
|
source arch/arm/src/efm32/Kconfig
|
||||||
endif
|
endif
|
||||||
if ARCH_CHIP_IMX
|
if ARCH_CHIP_IMX1
|
||||||
source arch/arm/src/imx/Kconfig
|
source arch/arm/src/imx1/Kconfig
|
||||||
endif
|
endif
|
||||||
if ARCH_CHIP_KINETIS
|
if ARCH_CHIP_KINETIS
|
||||||
source arch/arm/src/kinetis/Kconfig
|
source arch/arm/src/kinetis/Kconfig
|
||||||
|
@ -3,37 +3,33 @@
|
|||||||
# see the file kconfig-language.txt in the NuttX tools repository.
|
# see the file kconfig-language.txt in the NuttX tools repository.
|
||||||
#
|
#
|
||||||
|
|
||||||
if ARCH_CHIP_IMX
|
if ARCH_CHIP_IMX1
|
||||||
|
|
||||||
# choice "iMX Chip Selection"
|
# choice "iMX.1 Chip Selection"
|
||||||
|
|
||||||
config ARCH_CHIP_IMX1
|
menu "iMX.1 Peripheral Selection"
|
||||||
bool
|
|
||||||
default y
|
|
||||||
|
|
||||||
menu "iMX Peripheral Selection"
|
config IMX1_UART1
|
||||||
|
|
||||||
config IMX_UART1
|
|
||||||
bool "UART1"
|
bool "UART1"
|
||||||
default n
|
default n
|
||||||
select ARCH_HAVE_UART1
|
select ARCH_HAVE_UART1
|
||||||
|
|
||||||
config IMX_UART2
|
config IMX1_UART2
|
||||||
bool "UART2"
|
bool "UART2"
|
||||||
default n
|
default n
|
||||||
select ARCH_HAVE_UART2
|
select ARCH_HAVE_UART2
|
||||||
|
|
||||||
config IMX_UART3
|
config IMX1_UART3
|
||||||
bool "UART2"
|
bool "UART2"
|
||||||
default n
|
default n
|
||||||
select ARCH_HAVE_UART3
|
select ARCH_HAVE_UART3
|
||||||
|
|
||||||
config IMX_SPI1
|
config IMX1_SPI1
|
||||||
bool "SPI1"
|
bool "SPI1"
|
||||||
default n
|
default n
|
||||||
select SPI
|
select SPI
|
||||||
|
|
||||||
config IMX_SPI2
|
config IMX1_SPI2
|
||||||
bool "SPI2"
|
bool "SPI2"
|
||||||
default n
|
default n
|
||||||
select SPI
|
select SPI
|
||||||
@ -46,4 +42,4 @@ config RAM_NUTTXENTRY
|
|||||||
---help---
|
---help---
|
||||||
The virtual address of the NuttX entry point
|
The virtual address of the NuttX entry point
|
||||||
|
|
||||||
endif
|
endif # ARCH_CHIP_IMX1
|
||||||
|
@ -70,8 +70,8 @@
|
|||||||
|
|
||||||
/* The i.MXL chip has only two UARTs */
|
/* The i.MXL chip has only two UARTs */
|
||||||
|
|
||||||
#if defined(CONFIG_ARCH_CHIP_IMXL) && defined(CONFIG_IMX_UART3)
|
#if defined(CONFIG_ARCH_CHIP_IMXL) && defined(CONFIG_IMX1_UART3)
|
||||||
# undef CONFIG_IMX_UART3
|
# undef CONFIG_IMX1_UART3
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
@ -146,24 +146,24 @@ static const struct uart_ops_s g_uart_ops =
|
|||||||
|
|
||||||
/* I/O buffers */
|
/* I/O buffers */
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART1
|
#ifdef CONFIG_IMX1_UART1
|
||||||
static char g_uart1rxbuffer[CONFIG_UART1_RXBUFSIZE];
|
static char g_uart1rxbuffer[CONFIG_UART1_RXBUFSIZE];
|
||||||
static char g_uart1txbuffer[CONFIG_UART1_TXBUFSIZE];
|
static char g_uart1txbuffer[CONFIG_UART1_TXBUFSIZE];
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART2
|
#ifdef CONFIG_IMX1_UART2
|
||||||
static char g_uart2rxbuffer[CONFIG_UART2_RXBUFSIZE];
|
static char g_uart2rxbuffer[CONFIG_UART2_RXBUFSIZE];
|
||||||
static char g_uart2txbuffer[CONFIG_UART2_TXBUFSIZE];
|
static char g_uart2txbuffer[CONFIG_UART2_TXBUFSIZE];
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART3
|
#ifdef CONFIG_IMX1_UART3
|
||||||
static char g_uart3rxbuffer[CONFIG_UART2_RXBUFSIZE];
|
static char g_uart3rxbuffer[CONFIG_UART2_RXBUFSIZE];
|
||||||
static char g_uart3txbuffer[CONFIG_UART2_TXBUFSIZE];
|
static char g_uart3txbuffer[CONFIG_UART2_TXBUFSIZE];
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* This describes the state of the IMX uart1 port. */
|
/* This describes the state of the IMX uart1 port. */
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART1
|
#ifdef CONFIG_IMX1_UART1
|
||||||
static struct up_dev_s g_uart1priv =
|
static struct up_dev_s g_uart1priv =
|
||||||
{
|
{
|
||||||
.uartbase = IMX_UART1_VBASE,
|
.uartbase = IMX_UART1_VBASE,
|
||||||
@ -198,7 +198,7 @@ static uart_dev_t g_uart1port =
|
|||||||
|
|
||||||
/* This describes the state of the IMX uart2 port. */
|
/* This describes the state of the IMX uart2 port. */
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART2
|
#ifdef CONFIG_IMX1_UART2
|
||||||
static struct up_dev_s g_uart2priv =
|
static struct up_dev_s g_uart2priv =
|
||||||
{
|
{
|
||||||
.uartbase = IMX_UART2_VBASE,
|
.uartbase = IMX_UART2_VBASE,
|
||||||
@ -231,7 +231,7 @@ static uart_dev_t g_uart2port =
|
|||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART3
|
#ifdef CONFIG_IMX1_UART3
|
||||||
static struct up_dev_s g_uart3priv =
|
static struct up_dev_s g_uart3priv =
|
||||||
{
|
{
|
||||||
.uartbase = IMX_UART3_REGISTER_BASE,
|
.uartbase = IMX_UART3_REGISTER_BASE,
|
||||||
@ -266,19 +266,19 @@ static uart_dev_t g_uart3port =
|
|||||||
|
|
||||||
/* Now, which one with be tty0/console and which tty1 and tty2? */
|
/* Now, which one with be tty0/console and which tty1 and tty2? */
|
||||||
|
|
||||||
#if defined(CONFIG_UART1_SERIAL_CONSOLE) && defined(CONFIG_IMX_UART1)
|
#if defined(CONFIG_UART1_SERIAL_CONSOLE) && defined(CONFIG_IMX1_UART1)
|
||||||
# define CONSOLE_DEV g_uart1port /* UART1 is /dev/console */
|
# define CONSOLE_DEV g_uart1port /* UART1 is /dev/console */
|
||||||
# undef CONFIG_UART2_SERIAL_CONSOLE
|
# undef CONFIG_UART2_SERIAL_CONSOLE
|
||||||
# undef CONFIG_UART3_SERIAL_CONSOLE
|
# undef CONFIG_UART3_SERIAL_CONSOLE
|
||||||
# define TTYS0_DEV g_uart1port /* UART1 is /dev/ttyS0 */
|
# define TTYS0_DEV g_uart1port /* UART1 is /dev/ttyS0 */
|
||||||
# if defined(CONFIG_IMX_UART2)
|
# if defined(CONFIG_IMX1_UART2)
|
||||||
# define TTYS1_DEV g_uart2port /* UART2 is /dev/ttyS1 */
|
# define TTYS1_DEV g_uart2port /* UART2 is /dev/ttyS1 */
|
||||||
# if defined(CONFIG_IMX_UART3)
|
# if defined(CONFIG_IMX1_UART3)
|
||||||
# define TTYS2_DEV g_uart3port /* UART3 is /dev/ttyS2 */
|
# define TTYS2_DEV g_uart3port /* UART3 is /dev/ttyS2 */
|
||||||
# else
|
# else
|
||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# endif
|
# endif
|
||||||
# elif defined(CONFIG_IMX_UART3)
|
# elif defined(CONFIG_IMX1_UART3)
|
||||||
# define TTYS1_DEV g_uart3port /* UART3 is /dev/ttyS1 */
|
# define TTYS1_DEV g_uart3port /* UART3 is /dev/ttyS1 */
|
||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# else
|
# else
|
||||||
@ -286,38 +286,38 @@ static uart_dev_t g_uart3port =
|
|||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
#elif defined(CONFIG_UART2_SERIAL_CONSOLE) && defined(CONFIG_IMX_UART2)
|
#elif defined(CONFIG_UART2_SERIAL_CONSOLE) && defined(CONFIG_IMX1_UART2)
|
||||||
# define CONSOLE_DEV g_uart2port /* UART2 is /dev/console */
|
# define CONSOLE_DEV g_uart2port /* UART2 is /dev/console */
|
||||||
# undef CONFIG_UART1_SERIAL_CONSOLE
|
# undef CONFIG_UART1_SERIAL_CONSOLE
|
||||||
# undef CONFIG_UART3_SERIAL_CONSOLE
|
# undef CONFIG_UART3_SERIAL_CONSOLE
|
||||||
# define TTYS0_DEV g_uart2port /* UART2 is /dev/ttyS0 */
|
# define TTYS0_DEV g_uart2port /* UART2 is /dev/ttyS0 */
|
||||||
# if defined(CONFIG_IMX_UART1)
|
# if defined(CONFIG_IMX1_UART1)
|
||||||
# define TTYS1_DEV g_uart1port /* UART1 is /dev/ttyS1 */
|
# define TTYS1_DEV g_uart1port /* UART1 is /dev/ttyS1 */
|
||||||
# if defined(CONFIG_IMX_UART3)
|
# if defined(CONFIG_IMX1_UART3)
|
||||||
# define TTYS2_DEV g_uart3port /* UART3 is /dev/ttyS2 */
|
# define TTYS2_DEV g_uart3port /* UART3 is /dev/ttyS2 */
|
||||||
# else
|
# else
|
||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# endif
|
# endif
|
||||||
# elif defined(CONFIG_IMX_UART3)
|
# elif defined(CONFIG_IMX1_UART3)
|
||||||
# define TTYS1_DEV g_uart3port /* UART3 is /dev/ttyS1 */
|
# define TTYS1_DEV g_uart3port /* UART3 is /dev/ttyS1 */
|
||||||
# else
|
# else
|
||||||
# undef TTYS1_DEV /* No /dev/ttyS1 */
|
# undef TTYS1_DEV /* No /dev/ttyS1 */
|
||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
#elif defined(CONFIG_UART3_SERIAL_CONSOLE) && defined(CONFIG_IMX_UART3)
|
#elif defined(CONFIG_UART3_SERIAL_CONSOLE) && defined(CONFIG_IMX1_UART3)
|
||||||
# define CONSOLE_DEV g_uart3port /* UART3 is /dev/console */
|
# define CONSOLE_DEV g_uart3port /* UART3 is /dev/console */
|
||||||
# undef CONFIG_UART1_SERIAL_CONSOLE
|
# undef CONFIG_UART1_SERIAL_CONSOLE
|
||||||
# undef CONFIG_UART2_SERIAL_CONSOLE
|
# undef CONFIG_UART2_SERIAL_CONSOLE
|
||||||
# define TTYS0_DEV g_uart3port /* UART3 is /dev/ttyS0 */
|
# define TTYS0_DEV g_uart3port /* UART3 is /dev/ttyS0 */
|
||||||
# if defined(CONFIG_IMX_UART1)
|
# if defined(CONFIG_IMX1_UART1)
|
||||||
# define TTYS1_DEV g_uart1port /* UART1 is /dev/ttyS1 */
|
# define TTYS1_DEV g_uart1port /* UART1 is /dev/ttyS1 */
|
||||||
# if defined(CONFIG_IMX_UART2)
|
# if defined(CONFIG_IMX1_UART2)
|
||||||
# define TTYS2_DEV g_uart2port /* UART2 is /dev/ttyS2 */
|
# define TTYS2_DEV g_uart2port /* UART2 is /dev/ttyS2 */
|
||||||
# else
|
# else
|
||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# endif
|
# endif
|
||||||
# elif defined(CONFIG_IMX_UART2)
|
# elif defined(CONFIG_IMX1_UART2)
|
||||||
# define TTYS1_DEV g_uart2port /* UART2 is /dev/ttyS1 */
|
# define TTYS1_DEV g_uart2port /* UART2 is /dev/ttyS1 */
|
||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# else
|
# else
|
||||||
@ -331,16 +331,16 @@ static uart_dev_t g_uart3port =
|
|||||||
# undef CONFIG_UART2_SERIAL_CONSOLE
|
# undef CONFIG_UART2_SERIAL_CONSOLE
|
||||||
# undef CONFIG_UART3_SERIAL_CONSOLE
|
# undef CONFIG_UART3_SERIAL_CONSOLE
|
||||||
|
|
||||||
# if defined(CONFIG_IMX_UART1)
|
# if defined(CONFIG_IMX1_UART1)
|
||||||
# define TTYS0_DEV g_uart1port /* UART1 is /dev/ttyS0 */
|
# define TTYS0_DEV g_uart1port /* UART1 is /dev/ttyS0 */
|
||||||
# if defined(CONFIG_IMX_UART2)
|
# if defined(CONFIG_IMX1_UART2)
|
||||||
# define TTYS1_DEV g_uart2port /* UART2 is /dev/ttyS1 */
|
# define TTYS1_DEV g_uart2port /* UART2 is /dev/ttyS1 */
|
||||||
# if defined(CONFIG_IMX_UART3)
|
# if defined(CONFIG_IMX1_UART3)
|
||||||
# define TTYS2_DEV g_uart3port /* UART3 is /dev/ttyS2 */
|
# define TTYS2_DEV g_uart3port /* UART3 is /dev/ttyS2 */
|
||||||
# else
|
# else
|
||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# endif
|
# endif
|
||||||
# elif defined(CONFIG_IMX_UART3)
|
# elif defined(CONFIG_IMX1_UART3)
|
||||||
# define TTYS1_DEV g_uart3port /* UART3 is /dev/ttyS1 */
|
# define TTYS1_DEV g_uart3port /* UART3 is /dev/ttyS1 */
|
||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# else
|
# else
|
||||||
@ -348,16 +348,16 @@ static uart_dev_t g_uart3port =
|
|||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
# elif defined(CONFIG_IMX_UART2)
|
# elif defined(CONFIG_IMX1_UART2)
|
||||||
# define TTYS0_DEV g_uart2port /* UART2 is /dev/ttyS0 */
|
# define TTYS0_DEV g_uart2port /* UART2 is /dev/ttyS0 */
|
||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
# if defined(CONFIG_IMX_UART3)
|
# if defined(CONFIG_IMX1_UART3)
|
||||||
# define TTYS1_DEV g_uart2port /* UART2 is /dev/ttyS1 */
|
# define TTYS1_DEV g_uart2port /* UART2 is /dev/ttyS1 */
|
||||||
# else
|
# else
|
||||||
# undef TTYS1_DEV /* No /dev/ttyS1 */
|
# undef TTYS1_DEV /* No /dev/ttyS1 */
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
# elif defined(CONFIG_IMX_UART3)
|
# elif defined(CONFIG_IMX1_UART3)
|
||||||
# define TTYS0_DEV g_uart3port /* UART3 is /dev/ttyS0 */
|
# define TTYS0_DEV g_uart3port /* UART3 is /dev/ttyS0 */
|
||||||
# undef TTYS1_DEV /* No /dev/ttyS1 */
|
# undef TTYS1_DEV /* No /dev/ttyS1 */
|
||||||
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
# undef TTYS2_DEV /* No /dev/ttyS2 */
|
||||||
@ -767,7 +767,7 @@ static inline struct uart_dev_s *up_mapirq(int irq)
|
|||||||
|
|
||||||
switch (irq)
|
switch (irq)
|
||||||
{
|
{
|
||||||
#ifdef CONFIG_IMX_UART1
|
#ifdef CONFIG_IMX1_UART1
|
||||||
#if defined(CONFIG_ARCH_CHIP_IMX1) || defined(CONFIG_ARCH_CHIP_IMXL)
|
#if defined(CONFIG_ARCH_CHIP_IMX1) || defined(CONFIG_ARCH_CHIP_IMXL)
|
||||||
case IMX_IRQ_UART1RX:
|
case IMX_IRQ_UART1RX:
|
||||||
case IMX_IRQ_UART1TX:
|
case IMX_IRQ_UART1TX:
|
||||||
@ -778,7 +778,7 @@ static inline struct uart_dev_s *up_mapirq(int irq)
|
|||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART2
|
#ifdef CONFIG_IMX1_UART2
|
||||||
#if defined(CONFIG_ARCH_CHIP_IMX1) || defined(CONFIG_ARCH_CHIP_IMXL)
|
#if defined(CONFIG_ARCH_CHIP_IMX1) || defined(CONFIG_ARCH_CHIP_IMXL)
|
||||||
case IMX_IRQ_UART2RX:
|
case IMX_IRQ_UART2RX:
|
||||||
case IMX_IRQ_UART2TX:
|
case IMX_IRQ_UART2TX:
|
||||||
@ -789,7 +789,7 @@ static inline struct uart_dev_s *up_mapirq(int irq)
|
|||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART3
|
#ifdef CONFIG_IMX1_UART3
|
||||||
#if defined(CONFIG_ARCH_CHIP_IMX1) || defined(CONFIG_ARCH_CHIP_IMXL)
|
#if defined(CONFIG_ARCH_CHIP_IMX1) || defined(CONFIG_ARCH_CHIP_IMXL)
|
||||||
case IMX_IRQ_UART3RX:
|
case IMX_IRQ_UART3RX:
|
||||||
case IMX_IRQ_UART3TX:
|
case IMX_IRQ_UART3TX:
|
||||||
@ -1074,7 +1074,7 @@ void up_earlyserialinit(void)
|
|||||||
{
|
{
|
||||||
/* Configure and disable the UART1 */
|
/* Configure and disable the UART1 */
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART1
|
#ifdef CONFIG_IMX1_UART1
|
||||||
up_serialout(&g_uart1priv, UART_UCR1, 0);
|
up_serialout(&g_uart1priv, UART_UCR1, 0);
|
||||||
up_serialout(&g_uart1priv, UART_UCR2, 0);
|
up_serialout(&g_uart1priv, UART_UCR2, 0);
|
||||||
|
|
||||||
@ -1088,7 +1088,7 @@ void up_earlyserialinit(void)
|
|||||||
|
|
||||||
/* Configure and disable the UART2 */
|
/* Configure and disable the UART2 */
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART2
|
#ifdef CONFIG_IMX1_UART2
|
||||||
up_serialout(&g_uart2priv, UART_UCR1, 0);
|
up_serialout(&g_uart2priv, UART_UCR1, 0);
|
||||||
up_serialout(&g_uart2priv, UART_UCR2, 0);
|
up_serialout(&g_uart2priv, UART_UCR2, 0);
|
||||||
|
|
||||||
@ -1104,7 +1104,7 @@ void up_earlyserialinit(void)
|
|||||||
|
|
||||||
/* Configure and disable the UART3 */
|
/* Configure and disable the UART3 */
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_UART3
|
#ifdef CONFIG_IMX1_UART3
|
||||||
up_serialout(&g_uart3priv, UART_UCR1, 0);
|
up_serialout(&g_uart3priv, UART_UCR1, 0);
|
||||||
up_serialout(&g_uart3priv, UART_UCR2, 0);
|
up_serialout(&g_uart3priv, UART_UCR2, 0);
|
||||||
|
|
||||||
|
@ -65,16 +65,16 @@
|
|||||||
|
|
||||||
/* The i.MX1/L supports 2 SPI interfaces. Which have been enabled? */
|
/* The i.MX1/L supports 2 SPI interfaces. Which have been enabled? */
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_SPI1
|
#ifdef CONFIG_IMX1_SPI1
|
||||||
# define SPI1_NDX 0 /* Index to SPI1 in g_spidev[] */
|
# define SPI1_NDX 0 /* Index to SPI1 in g_spidev[] */
|
||||||
# ifdef CONFIG_IMX_SPI2
|
# ifdef CONFIG_IMX1_SPI2
|
||||||
# define SPI2_NDX 1 /* Index to SPI2 in g_spidev[] */
|
# define SPI2_NDX 1 /* Index to SPI2 in g_spidev[] */
|
||||||
# define NSPIS 2 /* Two SPI interfaces: SPI1 & SPI2 */
|
# define NSPIS 2 /* Two SPI interfaces: SPI1 & SPI2 */
|
||||||
# else
|
# else
|
||||||
# define NSPIS 1 /* One SPI interface: SPI1 */
|
# define NSPIS 1 /* One SPI interface: SPI1 */
|
||||||
# endif
|
# endif
|
||||||
#else
|
#else
|
||||||
# ifdef CONFIG_IMX_SPI2
|
# ifdef CONFIG_IMX1_SPI2
|
||||||
# define SPI2_NDX 0 /* Index to SPI2 in g_spidev[] */
|
# define SPI2_NDX 0 /* Index to SPI2 in g_spidev[] */
|
||||||
# define NSPIS 1 /* One SPI interface: SPI2 */
|
# define NSPIS 1 /* One SPI interface: SPI2 */
|
||||||
# else
|
# else
|
||||||
@ -215,7 +215,7 @@ static const struct spi_ops_s g_spiops =
|
|||||||
|
|
||||||
static struct imx_spidev_s g_spidev[] =
|
static struct imx_spidev_s g_spidev[] =
|
||||||
{
|
{
|
||||||
#ifdef CONFIG_IMX_SPI1
|
#ifdef CONFIG_IMX1_SPI1
|
||||||
{
|
{
|
||||||
.ops = &g_spiops,
|
.ops = &g_spiops,
|
||||||
.base = IMX_CSPI1_VBASE,
|
.base = IMX_CSPI1_VBASE,
|
||||||
@ -224,7 +224,7 @@ static struct imx_spidev_s g_spidev[] =
|
|||||||
#endif
|
#endif
|
||||||
},
|
},
|
||||||
#endif
|
#endif
|
||||||
#ifdef CONFIG_IMX_SPI2
|
#ifdef CONFIG_IMX1_SPI2
|
||||||
{
|
{
|
||||||
.ops = &g_spiops,
|
.ops = &g_spiops,
|
||||||
.base = IMX_CSPI2_VBASE,
|
.base = IMX_CSPI2_VBASE,
|
||||||
@ -617,11 +617,11 @@ static inline struct imx_spidev_s *spi_mapirq(int irq)
|
|||||||
{
|
{
|
||||||
switch (irq)
|
switch (irq)
|
||||||
{
|
{
|
||||||
#ifdef CONFIG_IMX_SPI1
|
#ifdef CONFIG_IMX1_SPI1
|
||||||
case IMX_IRQ_CSPI1:
|
case IMX_IRQ_CSPI1:
|
||||||
return &g_spidev[SPI1_NDX];
|
return &g_spidev[SPI1_NDX];
|
||||||
#endif
|
#endif
|
||||||
#ifdef CONFIG_IMX_SPI2
|
#ifdef CONFIG_IMX1_SPI2
|
||||||
case IMX_IRQ_CSPI2:
|
case IMX_IRQ_CSPI2:
|
||||||
return &g_spidev[SPI2_NDX];
|
return &g_spidev[SPI2_NDX];
|
||||||
#endif
|
#endif
|
||||||
@ -1040,7 +1040,7 @@ FAR struct spi_dev_s *imx_spibus_initialize(int port)
|
|||||||
|
|
||||||
switch (port)
|
switch (port)
|
||||||
{
|
{
|
||||||
#ifdef CONFIG_IMX_SPI1
|
#ifdef CONFIG_IMX1_SPI1
|
||||||
case 1:
|
case 1:
|
||||||
/* Select SPI1 */
|
/* Select SPI1 */
|
||||||
|
|
||||||
@ -1055,9 +1055,9 @@ FAR struct spi_dev_s *imx_spibus_initialize(int port)
|
|||||||
imxgpio_configpfinput(GPIOC, 16); /* Port C, pin 16: MISO */
|
imxgpio_configpfinput(GPIOC, 16); /* Port C, pin 16: MISO */
|
||||||
imxgpio_configpfoutput(GPIOC, 17); /* Port C, pin 17: MOSI */
|
imxgpio_configpfoutput(GPIOC, 17); /* Port C, pin 17: MOSI */
|
||||||
break;
|
break;
|
||||||
#endif /* CONFIG_IMX_SPI1 */
|
#endif /* CONFIG_IMX1_SPI1 */
|
||||||
|
|
||||||
#ifdef CONFIG_IMX_SPI2
|
#ifdef CONFIG_IMX1_SPI2
|
||||||
case 2:
|
case 2:
|
||||||
/* Select SPI2 */
|
/* Select SPI2 */
|
||||||
|
|
||||||
@ -1107,7 +1107,7 @@ FAR struct spi_dev_s *imx_spibus_initialize(int port)
|
|||||||
imxgpio_configoutput(GPIOD, 10);
|
imxgpio_configoutput(GPIOD, 10);
|
||||||
#endif
|
#endif
|
||||||
break;
|
break;
|
||||||
#endif /* CONFIG_IMX_SPI2 */
|
#endif /* CONFIG_IMX1_SPI2 */
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return NULL;
|
return NULL;
|
||||||
|
Loading…
Reference in New Issue
Block a user