From 30a06b618fbdd03fa0ebe48b22812e445ca625f1 Mon Sep 17 00:00:00 2001 From: Yuan Tao Date: Wed, 5 Aug 2020 20:37:57 +0800 Subject: [PATCH] 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 --- ...fix-nanopi-r2s-failed-to-boot-on-som.patch | 48 +++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 package/boot/uboot-rockchip/patches/101-rockchip-rk3328-fix-nanopi-r2s-failed-to-boot-on-som.patch diff --git a/package/boot/uboot-rockchip/patches/101-rockchip-rk3328-fix-nanopi-r2s-failed-to-boot-on-som.patch b/package/boot/uboot-rockchip/patches/101-rockchip-rk3328-fix-nanopi-r2s-failed-to-boot-on-som.patch new file mode 100644 index 0000000000..cfba764055 --- /dev/null +++ b/package/boot/uboot-rockchip/patches/101-rockchip-rk3328-fix-nanopi-r2s-failed-to-boot-on-som.patch @@ -0,0 +1,48 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Yuan Tao +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 +--- + +--- 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