Trouble Switching "BB-X15" SPL/U-boot Console from UART3 to UART10

Hi,

On the BeagleBone-X15/572xEVM, I’m attempting to switch both the SPL and U-boot console ports from UART3 to UART10, but thus far no luck. Per the 5728 DS, UART3 and UART10 can each be tied to the same pad depending on the mux mode. I’m Baselined on SPL/u-boot version 2017.01-00302-gafb742e.

The console is still accessible, but “coninfo” returns base address for UART3 (serial@48020000 00000003 IO stdin stdout stderr). After changing the pad io conf and attempting to disable UART3, it still looks like the console is on UART 3! Also UART 10 is on a different L4 I.C., L4_WKUP than the other UARTS, L4_PER… Not sure if this matters.

Thus far, implemented the following changes. What am I missing or what is a good source of documentation to help me better understand what I’m missing? Thanks in advance !!

=> …/board/ti/am57xx/mux_data.h - changed the muxmode for signals UART2_CTSN, UART2_RTSN both to M4 for UART 10 txd/rxd).

=> …/board/ti/am57xx/Kconfig:
Changed CONS_INDEX range FROM 1…6 TO 1…10
Changed CONS_INDEX default FROM 3 TO 10
Added #define CONFIG_SYS_NS16550_COM10 UART10_BASE

=> …spl/u-boot.cfg:
now indicates … CONFIG_CONS_INDEX 10

=> …/arch/arm/include/asm/arch-omap5/omap.h: #define UART10_BASE (OMAP54XX_L4_WKUP_BASE + 0x2b000) … ditto for …/asm/arch/omap.h

=> …/include/configs/am57xx_evm.h:
Changed CONSOLEDEV FROM ttyO2 TO ttyO9

=> To structure, prcm_regs, added the element, u32 cm_wkupaon_uart10_clkctrl ,

=> To …/omap5/prcm-regs.c, added the following to initializer for dra7xx_prcm
/* l4 wkup regs */
.cm_wkupaon_uart10_clkctrl = 0x4ae07880.

=> …arch/arm/mach-omap2/Clocks-common.c:: setup_clocks_for_console()
Added

clrsetbits_le32((*prcm)->cm_wkupaon_uart10_clkctrl,

MODULE_CLKCTRL_MODULEMODE_MASK,

MODULE_CLKCTRL_MODULEMODE_SW_EXPLICIT_EN <<

MODULE_CLKCTRL_MODULEMODE_SHIFT);

==> …/arch/arm/mach-omap2/omap5/hw_data.c:: enable_basic_clocks()

In clk_modules_explicit_en_essential[]= {

Replaced the entry

(*prcm)->cm_l4per_uart3_clkctrl

with

(*prcm)->cm_wkupaon_uart10_clkctrl

==> …/arch/arm/dts/am57xx-beagle-x15-common.dtsi

Commented out:

&uart3 {

status = “okay”;

interrupts-extended = <&crossbar_mpu GIC_SPI 69 IRQ_TYPE_LEVEL_HIGH>,

<&dra7_pmx_core 0x3f8>;

};

==> …/arch/arm/dts/am57xx-evm-reva3.dts

Added:

&uart10 {

status = “okay”;

interrupts-extended = <&crossbar_mpu GIC_SPI 69 IRQ_TYPE_LEVEL_HIGH>,

<&dra7_pmx_core 0x3f8>;

};

I’m not sure yet if u-boot also reads the device tree to determine what peripherals to enable…

Thanks!!

Hi,

have you ever managed to get UART10 running from uboot / SPL? I’m also trying to switch from UART3 to UART10. While it works fine after kernel got started it does not from uboot…

BR,

Mica