Turn on VCAM_AF regulator in bootloader
Turn on the power rail so we can set LED GPIO in u-boot
Change-Id: I53405b52b573e67a519c40a5b70e4aecacb6ce2c
diff --git a/plat/mediatek/mt8516/bl31_plat_setup.c b/plat/mediatek/mt8516/bl31_plat_setup.c
index 5396ec6..29d35f6 100644
--- a/plat/mediatek/mt8516/bl31_plat_setup.c
+++ b/plat/mediatek/mt8516/bl31_plat_setup.c
@@ -26,6 +26,9 @@
#define MT6392_DIGLDO_CON28 (0x0530)
#define MT6392_DIGLDO_CON7 (0x050A)
+#define MT6392_DIGLDO_CON31 (0x0536)
+#define MT6392_DIGLDO_CON32 (0x0538)
+
void plat_mt_gic_driver_init(void);
void plat_mt_gic_init(void);
@@ -153,6 +156,10 @@
pwrap_write(MT6392_DIGLDO_CON28, 0xE0);
pwrap_write(MT6392_DIGLDO_CON7, (1 << 15));
+ // Enable VCAM_AF regulator at 3.3V
+ pwrap_write(MT6392_DIGLDO_CON32, 0xE0);
+ pwrap_write(MT6392_DIGLDO_CON31, (1 << 15));
+
// plat_arm_gic_driver_init();
// plat_arm_gic_init();