[PATCH 1/1] serial: move sbi_dbcn_available to .data section

Conor Dooley conor.dooley at microchip.com
Thu Mar 7 09:39:34 CET 2024


On Mon, Feb 26, 2024 at 05:32:26PM +0100, Heinrich Schuchardt wrote:
> U-Boot SPL loads the device-tree directly behind main U-Boot overlapping
> the .bss section. reserve_fdt() is called in board_init_f() to relocate the
> device-tree to a safe location.
> 
> Debug UARTs are enabled before board_init_f(). With sbi_dbcn_available in
> the .bss section the device-tree is corrupted when _debug_uart_init() is
> called in the SBI serial driver. Move the variable to the .data section.
> 
> Link: https://bugs.launchpad.net/ubuntu/+source/u-boot/+bug/2054091
> Fixes: dfe08374943c ("risc-v: implement DBCN based debug console")
> Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt at canonical.com>

This also appears to fix the inconsistent boot issues that I've been
seeing since I reported:
https://lore.kernel.org/u-boot/20240122-finicky-ancient-797ba048f927@spud/

Tested-by: Conor Dooley <conor.dooley at microchip.com>

Thanks,
Conor.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20240307/ced3425e/attachment.sig>


More information about the U-Boot mailing list