From 806c4dd31532708d30dd82a5173232dccc73c81b Mon Sep 17 00:00:00 2001 From: Patrick Delaunay Date: Fri, 15 Apr 2022 14:31:54 +0200 Subject: configs: stm32mp1: set the console variable for extlinux.conf Set the environment variable "console", used in extlinux.conf file when it is generated by YOCTO distribution with: UBOOT_EXTLINUX_CONSOLE ??= "console=${console},${baudrate}" With these 2 variables, U-Boot give dynamically the used console and baudrate in the Linux kernel bootargs. For the STMicroelectronics boards, the used console is ttySTM0. Signed-off-by: Patrick Delaunay Reviewed-by: Patrice Chotard Signed-off-by: Patrice Chotard --- include/configs/stm32mp15_st_common.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include') diff --git a/include/configs/stm32mp15_st_common.h b/include/configs/stm32mp15_st_common.h index 10248bffc14..e8dad004c61 100644 --- a/include/configs/stm32mp15_st_common.h +++ b/include/configs/stm32mp15_st_common.h @@ -8,6 +8,9 @@ #ifndef __CONFIG_STM32MP15_ST_COMMON_H__ #define __CONFIG_STM32MP15_ST_COMMON_H__ +#define STM32MP_BOARD_EXTRA_ENV \ + "console=ttySTM0\0" + #include #ifdef CONFIG_EXTRA_ENV_SETTINGS -- cgit v1.2.3 From 5367b67be4a3d26197fe5bf7baef2bf125997047 Mon Sep 17 00:00:00 2001 From: Patrick Delaunay Date: Fri, 15 Apr 2022 14:31:55 +0200 Subject: configs: stm32mp1: Add support for baudrates higher than 115200 for st-link On STMicroelectronics boards, the UART can reliably go up to 2000000 bauds when connected to the on-board ST-LINK-V2 for STM32MP15 Unfortunately U-Boot will fall back to 115200 unless higher rates are declared via CONFIG_SYS_BAUDRATE_TABLE. This patch add the support of higher baudrates on STMicroelectronics boards with ST-LINK. Cc: Alexandru Gagniuc Signed-off-by: Patrick Delaunay Reviewed-by: Patrice Chotard Signed-off-by: Patrice Chotard --- include/configs/stm32mp15_st_common.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include') diff --git a/include/configs/stm32mp15_st_common.h b/include/configs/stm32mp15_st_common.h index e8dad004c61..3c0ffb8f56f 100644 --- a/include/configs/stm32mp15_st_common.h +++ b/include/configs/stm32mp15_st_common.h @@ -13,6 +13,11 @@ #include +/* uart with on-board st-link */ +#define CONFIG_SYS_BAUDRATE_TABLE { 9600, 19200, 38400, 57600, 115200, \ + 230400, 460800, 921600, \ + 1000000, 2000000 } + #ifdef CONFIG_EXTRA_ENV_SETTINGS /* * default bootcmd for stm32mp1 STMicroelectronics boards: -- cgit v1.2.3 From 480995b76b0ee61e473596e629dbc8ec754b0f84 Mon Sep 17 00:00:00 2001 From: Patrice Chotard Date: Wed, 27 Apr 2022 13:53:50 +0200 Subject: configs: stm32f746-disco: Concatenate spl and u-boot binaries This allows to concatenate spl and u-boot binaries together. Previously, both binaries has to be flashed separately at the correct offset (spl at offset 0 and u-boot at offset 0x8000). With this patch, only one binary is generated (u-boot-with-spl.bin) and has to be copied in flash at offset 0 using openocd for example or simply copied in exported mass storage. Signed-off-by: Patrice Chotard Reviewed-by: Patrick Delaunay --- include/configs/stm32f746-disco.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/configs/stm32f746-disco.h b/include/configs/stm32f746-disco.h index 8ad4bb99c83..b93acdcc1ff 100644 --- a/include/configs/stm32f746-disco.h +++ b/include/configs/stm32f746-disco.h @@ -49,6 +49,7 @@ #define CONFIG_SYS_UBOOT_START 0x080083FD #define CONFIG_SYS_UBOOT_BASE (CONFIG_SYS_FLASH_BASE + \ CONFIG_SYS_SPL_LEN) +#define CONFIG_SPL_PAD_TO 0x8000 /* DT blob (fdt) address */ #define CONFIG_SYS_FDT_BASE (CONFIG_SYS_FLASH_BASE + \ -- cgit v1.2.3 From 7aa4b4523f7c56b1b6407cbfb6ab3706f98e11c7 Mon Sep 17 00:00:00 2001 From: Patrice Chotard Date: Wed, 27 Apr 2022 13:53:58 +0200 Subject: configs: stm32f746-disco: use CONFIG_DEFAULT_DEVICE_TREE as fdtfile As stm32f46-disco, stm32f769-disco and stm32746g-eval are very similar except their respective device tree file. These 3 boards uses the same TARGET_STM32F746_DISCO flag (so same include/configs/stm32f746-disco.h and same board file board/st/stm32f746-disco/stm32f746-disco.c) To be able to compile these 3 boards, replace the hard-coded device-tree name in include/configs/stm32f746-disco.h by CONFIG_DEFAULT_DEVICE_TREE which is set in each board defconfig file with the correct value. Signed-off-by: Patrice Chotard Reviewed-by: Patrick Delaunay --- include/configs/stm32f746-disco.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/configs/stm32f746-disco.h b/include/configs/stm32f746-disco.h index b93acdcc1ff..cc3d4b4449d 100644 --- a/include/configs/stm32f746-disco.h +++ b/include/configs/stm32f746-disco.h @@ -34,7 +34,7 @@ #include #define CONFIG_EXTRA_ENV_SETTINGS \ "kernel_addr_r=0xC0008000\0" \ - "fdtfile=stm32f746-disco.dtb\0" \ + "fdtfile="CONFIG_DEFAULT_DEVICE_TREE".dtb\0" \ "fdt_addr_r=0xC0408000\0" \ "scriptaddr=0xC0418000\0" \ "pxefile_addr_r=0xC0428000\0" \ -- cgit v1.2.3