ARM: meson: odroid-go-ultra: setup PMIC regulators are board init
The Odroid Go Ultra has 2 chained PMICs RK818 and RK818, and needs
an adjustment on the BUCK and LDO values.
Add the initial regulators values in -u-boot.dtsi & run the initial
regulator setup in a new odroid-go-ultra board.
Proper OTG and BOOST regulators are still missing to have USB-A
host properly working.
Link: https://lore.kernel.org/r/20230210-u-boot-odroid-go-ultra-pmics-setup-v1-1-1f16d62b76af@linaro.org
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
diff --git a/board/amlogic/odroid-go-ultra/odroid-go-ultra.c b/board/amlogic/odroid-go-ultra/odroid-go-ultra.c
new file mode 100644
index 0000000..bbd23e2
--- /dev/null
+++ b/board/amlogic/odroid-go-ultra/odroid-go-ultra.c
@@ -0,0 +1,22 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2023 Neil Armstrong <neil.armstrong@linaro.org>
+ */
+
+#include <common.h>
+#include <asm/arch/boot.h>
+#include <power/regulator.h>
+
+int mmc_get_env_dev(void)
+{
+ if (meson_get_boot_device() == BOOT_DEVICE_EMMC)
+ return 1;
+ return 0;
+}
+
+int board_init(void)
+{
+ regulators_enable_boot_on(_DEBUG);
+
+ return 0;
+}