From 63208908ac657ae823b4072fcc4cd255ef8c82a2 Mon Sep 17 00:00:00 2001 From: Jukka Laitinen Date: Fri, 25 Sep 2026 13:43:09 +0300 Subject: [PATCH] arch/arm/imxrt: Allow serial console in uarts 9-12 iMXRT118x may have up to 12 uarts. Allow setting the console also on those. Signed-off-by: Jukka Laitinen --- arch/arm/src/imxrt/imxrt_config.h | 90 ++++++++++++++++++++++++++++++- 1 file changed, 89 insertions(+), 1 deletion(-) diff --git a/arch/arm/src/imxrt/imxrt_config.h b/arch/arm/src/imxrt/imxrt_config.h index a96670f1c99..864070860ba 100644 --- a/arch/arm/src/imxrt/imxrt_config.h +++ b/arch/arm/src/imxrt/imxrt_config.h @@ -97,7 +97,7 @@ #endif /* Is there a serial console? There should be at most one defined. - * It could be on any LPUARTn, n=1,2,3,4,5,6,7,8 + * It could be on any LPUARTn, n=1,2,...,12 */ #undef HAVE_LPUART_CONSOLE @@ -110,6 +110,10 @@ # undef CONFIG_LPUART6_SERIAL_CONSOLE # undef CONFIG_LPUART7_SERIAL_CONSOLE # undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE # define HAVE_LPUART_CONSOLE 1 #elif defined(CONFIG_LPUART2_SERIAL_CONSOLE) && defined(HAVE_LPUART2) # undef CONFIG_LPUART1_SERIAL_CONSOLE @@ -119,6 +123,10 @@ # undef CONFIG_LPUART6_SERIAL_CONSOLE # undef CONFIG_LPUART7_SERIAL_CONSOLE # undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE # define HAVE_LPUART_CONSOLE 1 #elif defined(CONFIG_LPUART3_SERIAL_CONSOLE) && defined(HAVE_LPUART3) # undef CONFIG_LPUART1_SERIAL_CONSOLE @@ -128,6 +136,10 @@ # undef CONFIG_LPUART6_SERIAL_CONSOLE # undef CONFIG_LPUART7_SERIAL_CONSOLE # undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE # define HAVE_LPUART_CONSOLE 1 #elif defined(CONFIG_LPUART4_SERIAL_CONSOLE) && defined(HAVE_LPUART4) # undef CONFIG_LPUART1_SERIAL_CONSOLE @@ -137,6 +149,10 @@ # undef CONFIG_LPUART6_SERIAL_CONSOLE # undef CONFIG_LPUART7_SERIAL_CONSOLE # undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE # define HAVE_LPUART_CONSOLE 1 #elif defined(CONFIG_LPUART5_SERIAL_CONSOLE) && defined(HAVE_LPUART5) # undef CONFIG_LPUART1_SERIAL_CONSOLE @@ -146,6 +162,10 @@ # undef CONFIG_LPUART6_SERIAL_CONSOLE # undef CONFIG_LPUART7_SERIAL_CONSOLE # undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE # define HAVE_LPUART_CONSOLE 1 #elif defined(CONFIG_LPUART6_SERIAL_CONSOLE) && defined(HAVE_LPUART6) # undef CONFIG_LPUART1_SERIAL_CONSOLE @@ -155,6 +175,10 @@ # undef CONFIG_LPUART5_SERIAL_CONSOLE # undef CONFIG_LPUART7_SERIAL_CONSOLE # undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE # define HAVE_LPUART_CONSOLE 1 #elif defined(CONFIG_LPUART7_SERIAL_CONSOLE) && defined(HAVE_LPUART7) # undef CONFIG_LPUART1_SERIAL_CONSOLE @@ -164,6 +188,10 @@ # undef CONFIG_LPUART5_SERIAL_CONSOLE # undef CONFIG_LPUART6_SERIAL_CONSOLE # undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE # define HAVE_LPUART_CONSOLE 1 #elif defined(CONFIG_LPUART8_SERIAL_CONSOLE) && defined(HAVE_LPUART8) # undef CONFIG_LPUART1_SERIAL_CONSOLE @@ -173,6 +201,62 @@ # undef CONFIG_LPUART5_SERIAL_CONSOLE # undef CONFIG_LPUART6_SERIAL_CONSOLE # undef CONFIG_LPUART7_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE +# define HAVE_LPUART_CONSOLE 1 +#elif defined(CONFIG_LPUART9_SERIAL_CONSOLE) && defined(HAVE_LPUART9) +# undef CONFIG_LPUART1_SERIAL_CONSOLE +# undef CONFIG_LPUART2_SERIAL_CONSOLE +# undef CONFIG_LPUART3_SERIAL_CONSOLE +# undef CONFIG_LPUART4_SERIAL_CONSOLE +# undef CONFIG_LPUART5_SERIAL_CONSOLE +# undef CONFIG_LPUART6_SERIAL_CONSOLE +# undef CONFIG_LPUART7_SERIAL_CONSOLE +# undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE +# define HAVE_LPUART_CONSOLE 1 +#elif defined(CONFIG_LPUART10_SERIAL_CONSOLE) && defined(HAVE_LPUART10) +# undef CONFIG_LPUART1_SERIAL_CONSOLE +# undef CONFIG_LPUART2_SERIAL_CONSOLE +# undef CONFIG_LPUART3_SERIAL_CONSOLE +# undef CONFIG_LPUART4_SERIAL_CONSOLE +# undef CONFIG_LPUART5_SERIAL_CONSOLE +# undef CONFIG_LPUART6_SERIAL_CONSOLE +# undef CONFIG_LPUART7_SERIAL_CONSOLE +# undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE +# define HAVE_LPUART_CONSOLE 1 +#elif defined(CONFIG_LPUART11_SERIAL_CONSOLE) && defined(HAVE_LPUART11) +# undef CONFIG_LPUART1_SERIAL_CONSOLE +# undef CONFIG_LPUART2_SERIAL_CONSOLE +# undef CONFIG_LPUART3_SERIAL_CONSOLE +# undef CONFIG_LPUART4_SERIAL_CONSOLE +# undef CONFIG_LPUART5_SERIAL_CONSOLE +# undef CONFIG_LPUART6_SERIAL_CONSOLE +# undef CONFIG_LPUART7_SERIAL_CONSOLE +# undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE +# define HAVE_LPUART_CONSOLE 1 +#elif defined(CONFIG_LPUART12_SERIAL_CONSOLE) && defined(HAVE_LPUART12) +# undef CONFIG_LPUART1_SERIAL_CONSOLE +# undef CONFIG_LPUART2_SERIAL_CONSOLE +# undef CONFIG_LPUART3_SERIAL_CONSOLE +# undef CONFIG_LPUART4_SERIAL_CONSOLE +# undef CONFIG_LPUART5_SERIAL_CONSOLE +# undef CONFIG_LPUART6_SERIAL_CONSOLE +# undef CONFIG_LPUART7_SERIAL_CONSOLE +# undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE # define HAVE_LPUART_CONSOLE 1 #else # ifdef CONFIG_DEV_CONSOLE @@ -186,6 +270,10 @@ # undef CONFIG_LPUART6_SERIAL_CONSOLE # undef CONFIG_LPUART7_SERIAL_CONSOLE # undef CONFIG_LPUART8_SERIAL_CONSOLE +# undef CONFIG_LPUART9_SERIAL_CONSOLE +# undef CONFIG_LPUART10_SERIAL_CONSOLE +# undef CONFIG_LPUART11_SERIAL_CONSOLE +# undef CONFIG_LPUART12_SERIAL_CONSOLE #endif /* Check LPUART flow control (Not yet supported) */