How to change U Boot console from UART0 to UART5 in beagle bone blue

I am currently working on configuring U-Boot on the Beagle Bone Blue, specifically aiming to change the U-Boot console from UART0 to UART5. I have adjusted the console setting in the /boot/uEnv.txt file to console = ttyS5,115200n8.

However, I’m encountering an issue where during the boot process, half of the messages are still being directed to UART0, and the remaining messages are appearing on UART5. My goal is to have all the booting messages consolidated and displayed exclusively on UART5.

I have reviewed the U-Boot environment variables, and they seem to be correctly set for UART5. I have also considered checking device tree overlays and bootloader configurations, but the issue persists.

If you have any insights or suggestions on how to ensure that all booting messages are directed to UART5, I would greatly appreciate your guidance. Additionally, if there are specific configurations or settings that I may have overlooked, please feel free to point them out.

Thank you for your time and assistance. I look forward to hearing from you.

Pretty sure you will need to re-compile u-boot the change the UART it uses.

can you please guide me about U-boot compilation, how can I compile the U-boot.