From: Patrice Chotard <patrice.chot...@st.com>

Add set_env_soc_name() call in board_late_init() to set environment
variable "soc_name" with the name of current STM32 SoC.

Signed-off-by: Christophe Priouzeau <christophe.priouz...@st.com>
Signed-off-by: Patrice Chotard <patrice.chot...@st.com>
---
 board/st/stm32f746-disco/stm32f746-disco.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/board/st/stm32f746-disco/stm32f746-disco.c 
b/board/st/stm32f746-disco/stm32f746-disco.c
index 8da70281f976..0ad03ce96d33 100644
--- a/board/st/stm32f746-disco/stm32f746-disco.c
+++ b/board/st/stm32f746-disco/stm32f746-disco.c
@@ -115,6 +115,8 @@ int board_late_init(void)
        struct gpio_desc gpio = {};
        int node;
 
+       set_env_soc_name(get_cpu_id());
+
        node = fdt_node_offset_by_compatible(gd->fdt_blob, 0, "st,led1");
        if (node < 0)
                return -1;
-- 
1.9.1

_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot

Reply via email to