uboot-rockchip: fix nanopi-r2s failed to boot on some sd cards

Add regulator-boot-on parameters to vcc_sd.
Add startup-delay-us parameters to vcc_sdio.
This will improve the problem that in some SD cards are failing to boot up.

Signed-off-by: Yuan Tao <ty@wevs.org>
This commit is contained in:
Yuan Tao 2020-08-05 20:37:57 +08:00 committed by CN_SZTL
parent 67d112a619
commit 30a06b618f
No known key found for this signature in database
GPG Key ID: 6850B6345C862176

View File

@ -0,0 +1,48 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Yuan Tao <ty@wevs.org>
Date: Sun, 9 Aug 2020 09:02:55 +0800
Subject: [PATCH] rockchip: rk3328: fix nanopi-r2s failed to boot on some sd cards
Issues:
When booting on some SD cards an error message appears as:
"spl: mmc init failed with error: -95"
Solutions:
Add regulator-boot-on parameters to vcc_sd.
Add startup-delay-us parameters to vcc_sdio.
This will improve the problem that in some SD cards are failing to boot up.
Tested environment:
SD Card: Netac Extreme P500 Pro 32GB
Signed-off-by: Yuan Tao <ty@wevs.org>
---
--- a/arch/arm/dts/rk3328-nanopi-r2s.dts
+++ b/arch/arm/dts/rk3328-nanopi-r2s.dts
@@ -32,6 +32,7 @@
regulator-name = "vcc_sd";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
+ regulator-boot-on;
vin-supply = <&vcc_io>;
};
@@ -49,6 +50,7 @@
regulator-name = "vcc_sdio";
regulator-settling-time-us = <5000>;
regulator-type = "voltage";
+ startup-delay-us = <2000>;
vin-supply = <&vcc_io>;
};
--- a/configs/nanopi-r2s-rk3328_defconfig
+++ b/configs/nanopi-r2s-rk3328_defconfig
@@ -56,6 +56,7 @@ CONFIG_SPL_CLK=y
CONFIG_FASTBOOT_BUF_ADDR=0x800800
CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
CONFIG_ROCKCHIP_GPIO=y
+CONFIG_REGULATOR_GPIO=y
CONFIG_SYS_I2C_ROCKCHIP=y
CONFIG_MMC_DW=y
CONFIG_MMC_DW_ROCKCHIP=y