[PATCH 15/16] spacemit: k1: Add support for mmc regulator initialization

Raymond Mao raymondmaoca at gmail.com
Wed Apr 22 16:31:11 CEST 2026


From: Raymond Mao <raymond.mao at riscstar.com>

Initialize the 1.8V supply for the MMC I/O domain to ensure proper
voltage configuration for MMC interfaces. This is required for
reliable operation of the MMC controller.

Signed-off-by: Raymond Mao <raymond.mao at riscstar.com>
---
 board/spacemit/k1/spl.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/board/spacemit/k1/spl.c b/board/spacemit/k1/spl.c
index 9b30bc9ea7e..2556dfe047a 100644
--- a/board/spacemit/k1/spl.c
+++ b/board/spacemit/k1/spl.c
@@ -196,6 +196,9 @@ static void set_vdd_mmc(void)
 	ret = regulator_get_by_platname("vdd_1v8_mmc", &dev);
 	if (ret)
 		panic("Fail to detect vdd_1v8_mmc (%d)\n", ret);
+	ret = regulator_set_value(dev, 1800000);
+	if (ret)
+		log_warning("Fail to set vdd_1v8_mmc as 1800000 (%d)\n", ret);
 	ret = regulator_set_enable(dev, true);
 	if (ret)
 		log_warning("Fail to enable vdd_1v8_mmc (%d)\n", ret);
-- 
2.25.1



More information about the U-Boot mailing list