Skip to contentSkip to conversation

ti_omap3_common: Add CONFIG_SYS_NS16550_COMx entries

PATCH Superseded Adam Ford 2 participants 4 messages Mar 4, 2018 – Jul 23, 2018

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Adam Ford

author
#0 lore raw

PATCH 1/1 ti_omap3_common: Add CONFIG_SYS_NS16550_COMx entries

Several boards do not use the default UART3, so they do a check for ifdef CONFIG_SPL_BUILD and enable the pointer for CONFIG_SYS_NS16550_COMx to point to OMAP34XX_UARTx.

Let's consoldate this all into one place, and remove them from the individual boards.

include/configs/omap3_cairo.h +0 -12
index 57ac3ec..c387602 100644
@@ -196,18 +196,6 @@
 /* env defaults */
 #define CONFIG_BOOTFILE			"uImage"
 
-/* Override OMAP3 common serial console configuration from UART3
- * to UART2.
- *
- * Attention: for UART2, special MUX settings (MUX_DEFAULT(), MCBSP3)
- * are needed and peripheral clocks for UART2 must be enabled in
- * function per_clocks_enable().
- */
-#ifdef CONFIG_SPL_BUILD
-#undef CONFIG_SYS_NS16550_COM3
-#define CONFIG_SYS_NS16550_COM2		OMAP34XX_UART2
-#endif
-
 /* Provide the MACH_TYPE value the vendor kernel requires */
 #define CONFIG_MACH_TYPE	3063
 
include/configs/omap3_logic.h +0 -6
index c9a154c..9e8c6bf 100644
@@ -17,12 +17,6 @@
 
 #include <configs/ti_omap3_common.h>
 
-#ifdef CONFIG_SPL_BUILD
-/* select serial console configuration for SPL */
-#define CONFIG_SYS_NS16550_COM1                OMAP34XX_UART1
-#endif
-
-
 /*
  * We are only ever GP parts and will utilize all of the "downloaded image"
  * area in SRAM which starts at 0x40200000 and ends at 0x4020FFFF (64KB) in
include/configs/ti_omap3_common.h +2 -0
index df6bca6..6b5ef1d 100644
@@ -39,6 +39,8 @@
 
 /* Select serial console configuration */
 #ifdef CONFIG_SPL_BUILD
+#define CONFIG_SYS_NS16550_COM1		OMAP34XX_UART1
+#define CONFIG_SYS_NS16550_COM2		OMAP34XX_UART2
 #define CONFIG_SYS_NS16550_COM3		OMAP34XX_UART3
 #endif
 
Signature · 1 line
2.7.4
#1 lore raw

include/configs/omap3_cairo.h

Quoted 11 lines · Adam Ford

Several boards do not use the default UART3, so they do a check for ifdef CONFIG_SPL_BUILD and enable the pointer for CONFIG_SYS_NS16550_COMx to point to OMAP34XX_UARTx.

Let's consoldate this all into one place, and remove them from the individual boards.

include/configs/omap3_cairo.h +0 -0
index 57ac3ec..c387602 100644

Deferred because it relies on the CONFIG_SERIALn patch.

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180319/57af6f41/attachment.sig>
author
#2 lore raw
Quoted 10 lines · Tom Rini
Quoted 7 lines · Adam Ford

Several boards do not use the default UART3, so they do a check for ifdef CONFIG_SPL_BUILD and enable the pointer for CONFIG_SYS_NS16550_COMx to point to OMAP34XX_UARTx.

Let's consoldate this all into one place, and remove them from the individual boards.

Quoted 6 lines

include/configs/omap3_cairo.h

Quoted 4 lines
include/configs/omap3_cairo.h +0 -0
index 57ac3ec..c387602 100644

Deferred because it relies on the CONFIG_SERIALn patch.

Does it really depend on that patch? The intent behind it was to point all the NS16550_COMx to their respective OMAP34XX ports in the common file, so the individual boards don't need to manually set them. My understanding is that the serial port has an index which dictates which of the COMx will be used in SPL so having all COMx ports pointing to each of the OMAP34XX references shouldn't break anything.

adam

Quoted 3 lines

--
Tom

#3 lore raw
Quoted 18 lines · Adam Ford
Quoted 10 lines · Tom Rini
Quoted 7 lines · Adam Ford

Several boards do not use the default UART3, so they do a check for ifdef CONFIG_SPL_BUILD and enable the pointer for CONFIG_SYS_NS16550_COMx to point to OMAP34XX_UARTx.

Let's consoldate this all into one place, and remove them from the individual boards.

Quoted 6 lines

include/configs/omap3_cairo.h

Quoted 4 lines
include/configs/omap3_cairo.h +0 -0
index 57ac3ec..c387602 100644

Deferred because it relies on the CONFIG_SERIALn patch.

Quoted 6 lines

Does it really depend on that patch? The intent behind it was to point all the NS16550_COMx to their respective OMAP34XX ports in the common file, so the individual boards don't need to manually set them. My understanding is that the serial port has an index which dictates which of the COMx will be used in SPL so having all COMx ports pointing to each of the OMAP34XX references shouldn't break anything.

Context-wise, yes, it depended on that other series in order to apply. If you can re-spin it stand-alone that would be great, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180723/68e8c2e5/attachment.sig>