[PATCH v1 2/2] board: starfive: visionfive2: Support VisionFive 2 Lite eMMC
Hal Feng
hal.feng at starfivetech.com
Thu Apr 2 09:00:41 CEST 2026
Add emmc detection to VisionFive 2 Lite DT selection and
fdtfile environment variable setting.
Signed-off-by: Hal Feng <hal.feng at starfivetech.com>
---
board/starfive/visionfive2/spl.c | 7 ++++++-
board/starfive/visionfive2/starfive_visionfive2.c | 6 +++++-
2 files changed, 11 insertions(+), 2 deletions(-)
diff --git a/board/starfive/visionfive2/spl.c b/board/starfive/visionfive2/spl.c
index e231467f2a1..1b4d623d002 100644
--- a/board/starfive/visionfive2/spl.c
+++ b/board/starfive/visionfive2/spl.c
@@ -144,7 +144,12 @@ int board_fit_config_name_match(const char *name)
!strncmp(get_product_id_from_eeprom(), "VF7110B", 7)) {
return 0;
} else if (!strcmp(name, "starfive/jh7110-starfive-visionfive-2-lite") &&
- !strncmp(get_product_id_from_eeprom(), "VF7110SL", 8)) {
+ !strncmp(get_product_id_from_eeprom(), "VF7110SL", 8) &&
+ !get_mmc_size_from_eeprom()) {
+ return 0;
+ } else if (!strcmp(name, "starfive/jh7110-starfive-visionfive-2-lite-emmc") &&
+ !strncmp(get_product_id_from_eeprom(), "VF7110SL", 8) &&
+ get_mmc_size_from_eeprom()) {
return 0;
}
diff --git a/board/starfive/visionfive2/starfive_visionfive2.c b/board/starfive/visionfive2/starfive_visionfive2.c
index 1a76f745ec8..97f40715f8f 100644
--- a/board/starfive/visionfive2/starfive_visionfive2.c
+++ b/board/starfive/visionfive2/starfive_visionfive2.c
@@ -72,7 +72,11 @@ static void set_fdtfile(void)
} else if (!strncmp(get_product_id_from_eeprom(), "VF7110B", 7)) {
fdtfile = "starfive/jh7110-starfive-visionfive-2-v1.3b.dtb";
} else if (!strncmp(get_product_id_from_eeprom(), "VF7110SL", 8)) {
- fdtfile = "starfive/jh7110-starfive-visionfive-2-lite.dtb";
+ if (get_mmc_size_from_eeprom()) {
+ fdtfile = "starfive/jh7110-starfive-visionfive-2-lite-emmc.dtb";
+ } else {
+ fdtfile = "starfive/jh7110-starfive-visionfive-2-lite.dtb";
+ }
} else {
log_err("Unknown product\n");
return;
--
2.43.2
More information about the U-Boot
mailing list