[PATCH] ARM: stm32: Increase USB power-good delay on DHSOM

Marek Vasut marex at denx.de
Sat Nov 13 03:24:44 CET 2021


The USB hub on STM32MP1 DHCOM boards needs to wait a bit longer until
the USB Vbus is stable. Increase the USB power-good delay to 1 s.

This adds default-undefined STM32MP_BOARD_EXTRA_ENV variable into
stm32mp15_common.h to reduce duplication in board-specific config
files adding custom environment.

Signed-off-by: Marek Vasut <marex at denx.de>
Cc: Patrice Chotard <patrice.chotard at foss.st.com>
Cc: Patrick Delaunay <patrick.delaunay at foss.st.com>
---
 include/configs/stm32mp15_common.h   | 3 ++-
 include/configs/stm32mp15_dh_dhsom.h | 3 +++
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/include/configs/stm32mp15_common.h b/include/configs/stm32mp15_common.h
index 4e2cabff2e7..be22d3ea7f1 100644
--- a/include/configs/stm32mp15_common.h
+++ b/include/configs/stm32mp15_common.h
@@ -169,7 +169,8 @@
 	STM32MP_BOOTCMD \
 	STM32MP_PARTS_DEFAULT \
 	BOOTENV \
-	STM32MP_EXTRA
+	STM32MP_EXTRA \
+	STM32MP_BOARD_EXTRA_ENV
 
 #endif /* ifndef CONFIG_SPL_BUILD */
 #endif /* ifdef CONFIG_DISTRO_DEFAULTS*/
diff --git a/include/configs/stm32mp15_dh_dhsom.h b/include/configs/stm32mp15_dh_dhsom.h
index c559cd72da7..bac9e8388a7 100644
--- a/include/configs/stm32mp15_dh_dhsom.h
+++ b/include/configs/stm32mp15_dh_dhsom.h
@@ -8,6 +8,9 @@
 #ifndef __CONFIG_STM32MP15_DH_DHSOM_H__
 #define __CONFIG_STM32MP15_DH_DHSOM_H__
 
+#define STM32MP_BOARD_EXTRA_ENV \
+	"usb_pgood_delay=1000\0"
+
 #include <configs/stm32mp15_common.h>
 
 #define CONFIG_SPL_TARGET		"u-boot.itb"
-- 
2.33.0



More information about the U-Boot mailing list