]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
arm: mach-k3: am6_init: Initialize AVS class 0
authorKeerthy <j-keerthy@ti.com>
Thu, 24 Oct 2019 09:30:52 +0000 (15:00 +0530)
committerTom Rini <trini@konsulko.com>
Thu, 7 Nov 2019 23:39:17 +0000 (18:39 -0500)
Initialize AVS class 0 so that mpu voltage rail is
programmed to the AVS class 0 compensated value.

Signed-off-by: Keerthy <j-keerthy@ti.com>
arch/arm/mach-k3/am6_init.c

index 0b564f7bd16647134a9e84be1044c9fa2e887b1f..99edcd9a247640e84e40ad0a621026e221bba5bb 100644 (file)
@@ -116,6 +116,13 @@ void board_init_f(ulong dummy)
        /* Perform EEPROM-based board detection */
        do_board_detect();
 
+#if defined(CONFIG_CPU_V7R) && defined(CONFIG_K3_AVS0)
+       ret = uclass_get_device_by_driver(UCLASS_MISC, DM_GET_DRIVER(k3_avs),
+                                         &dev);
+       if (ret)
+               printf("AVS init failed: %d\n", ret);
+#endif
+
 #ifdef CONFIG_K3_AM654_DDRSS
        ret = uclass_get_device(UCLASS_RAM, 0, &dev);
        if (ret)