[DEBUG] rk3399-nanopi-neo4: SPL SD init may report -5 due to SD power-on timing

Sune Brian briansune at gmail.com
Fri Oct 31 23:14:11 CET 2025


> Thank you Jonas ' feedback on dts.
> But sadly stall.

More info on this issue:

LDO node on dts:

vcc3v0_sd: regulator-vcc3v0-sd {
compatible = "regulator-fixed";
enable-active-high;
gpio = <&gpio0 RK_PA1 GPIO_ACTIVE_HIGH>;
pinctrl-names = "default";
pinctrl-0 = <&sdmmc0_pwr_h>;
regulator-always-on;
regulator-min-microvolt = <3000000>;
regulator-max-microvolt = <3000000>;
regulator-name = "vcc3v0_sd";
vin-supply = <&vcc3v3_sys>;
};

SD node on dts:

&sdmmc {
bus-width = <4>;
cap-sd-highspeed;
cap-mmc-highspeed;
cd-gpios = <&gpio0 RK_PA7 GPIO_ACTIVE_LOW>;
disable-wp;
pinctrl-names = "default";
pinctrl-0 = <&sdmmc_bus4 &sdmmc_clk &sdmmc_cmd &sdmmc0_det_l>;
sd-uhs-sdr104;
// vmmc-supply = <&vcc3v0_sd>;
vqmmc-supply = <&vcc_sdio>;
status = "okay";
};

Test Result:


U-Boot TPL 2026.01-rc1-00070-ge34d01d23e45-dirty (Nov 01 2025 - 06:07:29)
Channel 0: DDR3, 933MHz
BW=32 Col=10 Bk=8 CS0 Row=15 CS=1 Die BW=16 Size=1024MB
no stride
Trying to boot from BOOTROM
Returning to boot ROM...

U-Boot SPL 2026.01-rc1-00070-ge34d01d23e45-dirty (Nov 01 2025 - 06:07:29 +0800)
Trying to boot from MMC2
## Checking hash(es) for config config-1 ... OK
## Checking hash(es) for Image atf-1 ... sha256+ OK
## Checking hash(es) for Image u-boot ... sha256+ OK
## Checking hash(es) for Image fdt-1 ... sha256+ OK
## Checking hash(es) for Image atf-2 ... sha256+ OK
## Checking hash(es) for Image atf-3 ... sha256+ OK
## Checking hash(es) for Image atf-4 ... sha256+ OK
load_simple_fit: Skip load 'atf-5': image size is 0!
NOTICE:  BL31: v2.13.0(release):v2.13.0-1123-g6cec8315a
NOTICE:  BL31: Built : 00:43:13, Oct 31 2025


U-Boot 2026.01-rc1-00070-ge34d01d23e45-dirty (Nov 01 2025 - 06:07:29 +0800)

SoC: Rockchip rk3399
Reset cause: POR
Model: FriendlyARM NanoPi NEO4 2025/10 Build
DRAM:  1 GiB (total 1022 MiB)
PMIC:  RK808
Core:  305 devices, 31 uclasses, devicetree: separate
MMC:   mmc at fe310000: 3, mmc at fe320000: 1, mmc at fe330000: 0
Loading Environment from MMC... Reading from MMC(1)... OK
In:    serial,usbkbd
Out:   serial,vidconsole
Err:   serial,vidconsole
Model: FriendlyARM NanoPi NEO4 2025/10 Build
Net:   eth0: ethernet at fe300000

Hit any key to stop autoboot: 2

According to a simple comment on the SD node of
" vmmc-supply = <&vcc3v0_sd>;"

The boot is working properly.
Based on the above observation I can only narrow down
to LDO timing or power rail sanity issues.

Brian


More information about the U-Boot mailing list