]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
board: stm32mp1: Force pinctrl driver probe in board_init()
authorPatrice Chotard <patrice.chotard@st.com>
Mon, 11 Mar 2019 10:13:17 +0000 (11:13 +0100)
committerPatrick Delaunay <patrick.delaunay@st.com>
Fri, 12 Apr 2019 14:09:13 +0000 (16:09 +0200)
In order to insure that hog GPIOs are configured early during
the boot process, force all pinctrl driver probing in board_init().

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
board/st/stm32mp1/stm32mp1.c

index ff7790e310d7b44f4a39f54ddc5eb86637ee1797..24d299ac33bddf7803ce129e23d12aee85793dc0 100644 (file)
@@ -543,9 +543,18 @@ static void sysconf_init(void)
 /* board dependent setup after realloc */
 int board_init(void)
 {
+       struct udevice *dev;
+
        /* address of boot parameters */
        gd->bd->bi_boot_params = STM32_DDR_BASE + 0x100;
 
+       /* probe all PINCTRL for hog */
+       for (uclass_first_device(UCLASS_PINCTRL, &dev);
+            dev;
+            uclass_next_device(&dev)) {
+               pr_debug("probe pincontrol = %s\n", dev->name);
+       }
+
        board_key_check();
 
        sysconf_init();