[PATCH 0/3] rockchip: rk35xx: Fix writing to eMMC

Writing to eMMC using DDR52 mode does not work reliably or at all on RK356x and RK3588 boards.
This series fixes this issue by changing RK356x and RK3588 boards to prefer use of the more reliably HS200 mode.
This series depend on the series "rockchip: rk35xx: Sync device tree with linux v6.8-rc1" [1].
[1] https://patchwork.ozlabs.org/cover/1891669/
Jonas Karlman (3): rockchip: rk35xx: Remove use of eMMC DDR52 mode rockchip: rk356x: Enable eMMC HS200 mode rockchip: rk3588: Enable eMMC HS200 mode
arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi | 1 - arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi | 1 - arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi | 1 - arch/arm/dts/rk3566-soquartz-u-boot.dtsi | 1 - arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi | 1 - arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi | 1 - arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi | 1 - arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi | 1 - arch/arm/dts/rk3568-rock-3a-u-boot.dtsi | 1 - arch/arm/dts/rk3588-rock-5b-u-boot.dtsi | 1 - arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi | 1 - arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi | 1 - configs/anbernic-rgxx3-rk3566_defconfig | 2 ++ configs/bpi-r2-pro-rk3568_defconfig | 2 ++ configs/evb-rk3568_defconfig | 2 ++ configs/evb-rk3588_defconfig | 2 ++ configs/lubancat-2-rk3568_defconfig | 2 ++ configs/nanopc-t6-rk3588_defconfig | 2 ++ configs/neu6a-io-rk3588_defconfig | 2 ++ configs/neu6b-io-rk3588_defconfig | 2 ++ configs/odroid-m1-rk3568_defconfig | 2 ++ configs/orangepi-5-plus-rk3588_defconfig | 2 ++ configs/quartz64-a-rk3566_defconfig | 2 ++ configs/quartz64-b-rk3566_defconfig | 2 ++ configs/quartzpro64-rk3588_defconfig | 2 ++ configs/radxa-cm3-io-rk3566_defconfig | 2 ++ configs/rock-3a-rk3568_defconfig | 2 ++ configs/rock5a-rk3588s_defconfig | 2 ++ configs/rock5b-rk3588_defconfig | 2 ++ configs/soquartz-blade-rk3566_defconfig | 2 ++ configs/soquartz-cm4-rk3566_defconfig | 2 ++ configs/soquartz-model-a-rk3566_defconfig | 2 ++ configs/turing-rk1-rk3588_defconfig | 2 ++ 33 files changed, 42 insertions(+), 12 deletions(-)

Writing to eMMC using DDR52 mode does not work reliably or at all on RK356x and RK3588 boards.
Fix this by removing the mmc-ddr-1_8v prop from sdhci nodes.
Signed-off-by: Jonas Karlman jonas@kwiboo.se --- arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi | 1 - arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi | 1 - arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi | 1 - arch/arm/dts/rk3566-soquartz-u-boot.dtsi | 1 - arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi | 1 - arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi | 1 - arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi | 1 - arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi | 1 - arch/arm/dts/rk3568-rock-3a-u-boot.dtsi | 1 - arch/arm/dts/rk3588-rock-5b-u-boot.dtsi | 1 - arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi | 1 - arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi | 1 - 12 files changed, 12 deletions(-)
diff --git a/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi b/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi index 11976fd3a6e0..930d660868bb 100644 --- a/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi +++ b/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; pinctrl-names = "default"; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>; }; diff --git a/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi b/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi index 8de9d1535efb..c235b4357f7d 100644 --- a/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi +++ b/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi @@ -4,7 +4,6 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; pinctrl-names = "default"; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>; }; diff --git a/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi b/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi index 158f652cb3b1..e0e501deccfe 100644 --- a/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi +++ b/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi @@ -7,5 +7,4 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; }; diff --git a/arch/arm/dts/rk3566-soquartz-u-boot.dtsi b/arch/arm/dts/rk3566-soquartz-u-boot.dtsi index f65f4067f3e9..5e46a2422d60 100644 --- a/arch/arm/dts/rk3566-soquartz-u-boot.dtsi +++ b/arch/arm/dts/rk3566-soquartz-u-boot.dtsi @@ -4,7 +4,6 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; pinctrl-names = "default"; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>; }; diff --git a/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi b/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi index a44ac35bdacd..1597473017ed 100644 --- a/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi +++ b/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>; diff --git a/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi b/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi index 62f572c4cf9f..64c43374c042 100644 --- a/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi +++ b/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi @@ -14,7 +14,6 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe; diff --git a/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi b/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi index ecba91aa30f5..1fc71faa9e07 100644 --- a/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi +++ b/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe; diff --git a/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi b/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi index caf524443079..74755a44eaee 100644 --- a/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi +++ b/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi @@ -16,7 +16,6 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe; diff --git a/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi b/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi index 46ebb77283f1..5b823fcca5fb 100644 --- a/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi +++ b/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi @@ -20,7 +20,6 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe; diff --git a/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi b/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi index e99e60185ebe..9ee9dd051e32 100644 --- a/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi +++ b/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi @@ -31,7 +31,6 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; mmc-hs200-1_8v; };
diff --git a/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi b/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi index 471508a9ed74..ca2a684f3541 100644 --- a/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi +++ b/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; mmc-hs200-1_8v; };
diff --git a/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi b/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi index 9a6a353088df..efba0c359ba5 100644 --- a/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi +++ b/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi @@ -7,6 +7,5 @@
&sdhci { cap-mmc-highspeed; - mmc-ddr-1_8v; mmc-hs200-1_8v; };

Hi Jonas,
On 1/27/24 01:26, Jonas Karlman wrote:
Writing to eMMC using DDR52 mode does not work reliably or at all on RK356x and RK3588 boards.
This is related to the old issue I encountered last year with mmc write?
Thanks, Eugen
Fix this by removing the mmc-ddr-1_8v prop from sdhci nodes.
Signed-off-by: Jonas Karlman jonas@kwiboo.se
arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi | 1 - arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi | 1 - arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi | 1 - arch/arm/dts/rk3566-soquartz-u-boot.dtsi | 1 - arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi | 1 - arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi | 1 - arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi | 1 - arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi | 1 - arch/arm/dts/rk3568-rock-3a-u-boot.dtsi | 1 - arch/arm/dts/rk3588-rock-5b-u-boot.dtsi | 1 - arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi | 1 - arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi | 1 - 12 files changed, 12 deletions(-)
diff --git a/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi b/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi index 11976fd3a6e0..930d660868bb 100644 --- a/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi +++ b/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; pinctrl-names = "default"; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>;
}; diff --git a/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi b/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi index 8de9d1535efb..c235b4357f7d 100644 --- a/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi +++ b/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi @@ -4,7 +4,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; pinctrl-names = "default"; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>;
}; diff --git a/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi b/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi index 158f652cb3b1..e0e501deccfe 100644 --- a/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi +++ b/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi @@ -7,5 +7,4 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v;
}; diff --git a/arch/arm/dts/rk3566-soquartz-u-boot.dtsi b/arch/arm/dts/rk3566-soquartz-u-boot.dtsi index f65f4067f3e9..5e46a2422d60 100644 --- a/arch/arm/dts/rk3566-soquartz-u-boot.dtsi +++ b/arch/arm/dts/rk3566-soquartz-u-boot.dtsi @@ -4,7 +4,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; pinctrl-names = "default"; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>;
}; diff --git a/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi b/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi index a44ac35bdacd..1597473017ed 100644 --- a/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi +++ b/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>;
diff --git a/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi b/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi index 62f572c4cf9f..64c43374c042 100644 --- a/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi +++ b/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi @@ -14,7 +14,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe;
diff --git a/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi b/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi index ecba91aa30f5..1fc71faa9e07 100644 --- a/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi +++ b/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe;
diff --git a/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi b/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi index caf524443079..74755a44eaee 100644 --- a/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi +++ b/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi @@ -16,7 +16,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe;
diff --git a/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi b/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi index 46ebb77283f1..5b823fcca5fb 100644 --- a/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi +++ b/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi @@ -20,7 +20,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe;
diff --git a/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi b/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi index e99e60185ebe..9ee9dd051e32 100644 --- a/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi +++ b/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi @@ -31,7 +31,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v;
};
diff --git a/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi b/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi index 471508a9ed74..ca2a684f3541 100644 --- a/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi +++ b/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v;
};
diff --git a/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi b/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi index 9a6a353088df..efba0c359ba5 100644 --- a/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi +++ b/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi @@ -7,6 +7,5 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v;
};

Hi Eugen,
On 2024-01-27 04:48, Eugen Hristev wrote:
Hi Jonas,
On 1/27/24 01:26, Jonas Karlman wrote:
Writing to eMMC using DDR52 mode does not work reliably or at all on RK356x and RK3588 boards.
This is related to the old issue I encountered last year with mmc write?
Yes, I think it is.
I did some testing on RK3566/RK3568/RK3588S/RK3588 boards with different eMMC modules with following result:
Read seem to work with all enabled modes: RK3566: MMC legacy, MMC High Speed (26MHz), MMC High Speed (52MHz), MMC DDR52 (52MHz) and HS200 (200MHz) RK3568/RK3588S/RK3588: all above + HS400 (200MHz) and HS400ES (200MHz)
However, write had issues with some of the modes: MMC DDR52 (52MHz): all RK35xx HS400/HS400ES: only on RK3568 after changing hs400_txclk_tapnum to 8
HS200 seem to be the most stable write speed that worked on all SoCs.
So, dropping MMC DDR52 (52MHz) and enable use of HS200 (200MHz) seem to be the best option to get speedy and working read and write eMMC.
Regards, Jonas
Thanks, Eugen
Fix this by removing the mmc-ddr-1_8v prop from sdhci nodes.
Signed-off-by: Jonas Karlman jonas@kwiboo.se
arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi | 1 - arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi | 1 - arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi | 1 - arch/arm/dts/rk3566-soquartz-u-boot.dtsi | 1 - arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi | 1 - arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi | 1 - arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi | 1 - arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi | 1 - arch/arm/dts/rk3568-rock-3a-u-boot.dtsi | 1 - arch/arm/dts/rk3588-rock-5b-u-boot.dtsi | 1 - arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi | 1 - arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi | 1 - 12 files changed, 12 deletions(-)
[snip]

Hi Jonas,
On 1/27/24 12:15, Jonas Karlman wrote:
Hi Eugen,
On 2024-01-27 04:48, Eugen Hristev wrote:
Hi Jonas,
On 1/27/24 01:26, Jonas Karlman wrote:
Writing to eMMC using DDR52 mode does not work reliably or at all on RK356x and RK3588 boards.
This is related to the old issue I encountered last year with mmc write?
Yes, I think it is.
I did some testing on RK3566/RK3568/RK3588S/RK3588 boards with different eMMC modules with following result:
Read seem to work with all enabled modes: RK3566: MMC legacy, MMC High Speed (26MHz), MMC High Speed (52MHz), MMC DDR52 (52MHz) and HS200 (200MHz) RK3568/RK3588S/RK3588: all above + HS400 (200MHz) and HS400ES (200MHz)
However, write had issues with some of the modes: MMC DDR52 (52MHz): all RK35xx HS400/HS400ES: only on RK3568 after changing hs400_txclk_tapnum to 8
HS200 seem to be the most stable write speed that worked on all SoCs.
So, dropping MMC DDR52 (52MHz) and enable use of HS200 (200MHz) seem to be the best option to get speedy and working read and write eMMC.
1) we have this enabled on RK3588 Jaguar in upstream Linux... I may have improperly tested it then, would you mind sharing how you tested this mode on RK3588 so I can reproduce this and fix it on our product if we're impacted? I assume because we have HS200/HS400/HS400-ES enabled, DDR52 would never be used? (our eMMC is soldered and support the former modes).
2) Why are we not enabling HS400/HS400-ES for RK3588 boards? You seem to be saying there are issues with HS400/HS400-ES on RK3568 but you didn't mention the status for RK3588. Did I misunderstand the last sentence? Can you please rephrase in that case?
Cheers, Quentin

Hi Quentin,
On 2024-02-01 11:18, Quentin Schulz wrote:
Hi Jonas,
On 1/27/24 12:15, Jonas Karlman wrote:
Hi Eugen,
On 2024-01-27 04:48, Eugen Hristev wrote:
Hi Jonas,
On 1/27/24 01:26, Jonas Karlman wrote:
Writing to eMMC using DDR52 mode does not work reliably or at all on RK356x and RK3588 boards.
This is related to the old issue I encountered last year with mmc write?
Yes, I think it is.
I did some testing on RK3566/RK3568/RK3588S/RK3588 boards with different eMMC modules with following result:
Read seem to work with all enabled modes: RK3566: MMC legacy, MMC High Speed (26MHz), MMC High Speed (52MHz), MMC DDR52 (52MHz) and HS200 (200MHz) RK3568/RK3588S/RK3588: all above + HS400 (200MHz) and HS400ES (200MHz)
However, write had issues with some of the modes: MMC DDR52 (52MHz): all RK35xx HS400/HS400ES: only on RK3568 after changing hs400_txclk_tapnum to 8
HS200 seem to be the most stable write speed that worked on all SoCs.
So, dropping MMC DDR52 (52MHz) and enable use of HS200 (200MHz) seem to be the best option to get speedy and working read and write eMMC.
- we have this enabled on RK3588 Jaguar in upstream Linux... I may have
improperly tested it then, would you mind sharing how you tested this mode on RK3588 so I can reproduce this and fix it on our product if we're impacted? I assume because we have HS200/HS400/HS400-ES enabled, DDR52 would never be used? (our eMMC is soldered and support the former modes).
My main mode of testing eMMC in U-Boot has been to enable following Kconfig options,
CONFIG_MMC_HS200_SUPPORT=y CONFIG_MMC_HS400_SUPPORT=y CONFIG_MMC_HS400_ES_SUPPORT=y CONFIG_MMC_SPEED_MODE_SET=y
and from U-Boot cli run following,
=> mmc rescan <mode> && mmc info && mmc read 10000000 2000 10000 => mmc rescan <mode> && mmc info && mmc write 20000000 4000 10000
for each of the modes below.
0 = MMC legacy 1 = MMC High Speed (26MHz) 3 = MMC High Speed (52MHz) 4 = MMC DDR52 (52MHz) 10 = HS200 (200MHz) 11 = HS400 (200MHz) 12 = HS400ES (200MHz)
on different boards and different eMMC modules.
Using some modes the read or write return ERROR instead of OK. When ERROR was reported a rescan or board reset was needed to test next mode.
Please also note that I have only tested in U-Boot, not in linux.
- Why are we not enabling HS400/HS400-ES for RK3588 boards? You seem to
be saying there are issues with HS400/HS400-ES on RK3568 but you didn't mention the status for RK3588. Did I misunderstand the last sentence? Can you please rephrase in that case?
I can see now that my wording was very confusing.
Write for HS400/HS400ES mode only worked on RK3568 after modification to the driver, on RK3588 write always returned error for me.
So on RK3568 HS400 modes could be made work, on remaining SoCs there was issues.
Regards, Jonas
Cheers, Quentin

Hi Jonas,
On 2/1/24 11:51, Jonas Karlman wrote:
Hi Quentin,
On 2024-02-01 11:18, Quentin Schulz wrote:
Hi Jonas,
On 1/27/24 12:15, Jonas Karlman wrote:
Hi Eugen,
On 2024-01-27 04:48, Eugen Hristev wrote:
Hi Jonas,
On 1/27/24 01:26, Jonas Karlman wrote:
Writing to eMMC using DDR52 mode does not work reliably or at all on RK356x and RK3588 boards.
This is related to the old issue I encountered last year with mmc write?
Yes, I think it is.
I did some testing on RK3566/RK3568/RK3588S/RK3588 boards with different eMMC modules with following result:
Read seem to work with all enabled modes: RK3566: MMC legacy, MMC High Speed (26MHz), MMC High Speed (52MHz), MMC DDR52 (52MHz) and HS200 (200MHz) RK3568/RK3588S/RK3588: all above + HS400 (200MHz) and HS400ES (200MHz)
However, write had issues with some of the modes: MMC DDR52 (52MHz): all RK35xx HS400/HS400ES: only on RK3568 after changing hs400_txclk_tapnum to 8
HS200 seem to be the most stable write speed that worked on all SoCs.
So, dropping MMC DDR52 (52MHz) and enable use of HS200 (200MHz) seem to be the best option to get speedy and working read and write eMMC.
- we have this enabled on RK3588 Jaguar in upstream Linux... I may have
improperly tested it then, would you mind sharing how you tested this mode on RK3588 so I can reproduce this and fix it on our product if we're impacted? I assume because we have HS200/HS400/HS400-ES enabled, DDR52 would never be used? (our eMMC is soldered and support the former modes).
My main mode of testing eMMC in U-Boot has been to enable following Kconfig options,
CONFIG_MMC_HS200_SUPPORT=y CONFIG_MMC_HS400_SUPPORT=y CONFIG_MMC_HS400_ES_SUPPORT=y CONFIG_MMC_SPEED_MODE_SET=y
and from U-Boot cli run following,
=> mmc rescan <mode> && mmc info && mmc read 10000000 2000 10000 => mmc rescan <mode> && mmc info && mmc write 20000000 4000 10000
for each of the modes below.
0 = MMC legacy 1 = MMC High Speed (26MHz) 3 = MMC High Speed (52MHz) 4 = MMC DDR52 (52MHz) 10 = HS200 (200MHz) 11 = HS400 (200MHz) 12 = HS400ES (200MHz)
on different boards and different eMMC modules.
Using some modes the read or write return ERROR instead of OK. When ERROR was reported a rescan or board reset was needed to test next mode.
Please also note that I have only tested in U-Boot, not in linux.
Thanks for the tips on how to test these.
I have run the following commands on an RK3588 Jaguar (master branch + your v6.8-rc1 DTS sync patch series + Jaguar patch series):
=> for j in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19; do for i in 0 1 3 4 10 11 12; do mmc rescan $i && mmc read 10000000 2000 100000; if test $? -ne 0; then echo $i FAILED; fi; done; done
Which is 20 iterations of an mmc read at each of the 7 supported modes. The result is: 1 fail in HS200, 2 fails in HS400, the rest passes just fine.
=> for j in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19; do for i in 0 1 3 4 10 11 12; do mmc rescan $i && mmc write 20000000 4000 100000; if test $? -ne 0; then echo $i FAILED; fi; done; done
Which is 20 iterations of an mmc write at each of the 7 supported modes. The result is: 20 fails in DDR52, 2 fails in HS200, the rest passes just fine.
So it seems DDR52, HS200 and HS400 aren't stable on my board, but HS400ES somehow is (which is enabled in our defconfig).
I'll check if there's an easier way to test the Linux kernel than rebooting with a newer DTB between every try.
Cheers, Quentin
- Why are we not enabling HS400/HS400-ES for RK3588 boards? You seem to
be saying there are issues with HS400/HS400-ES on RK3568 but you didn't mention the status for RK3588. Did I misunderstand the last sentence? Can you please rephrase in that case?
I can see now that my wording was very confusing.
Write for HS400/HS400ES mode only worked on RK3568 after modification to the driver, on RK3588 write always returned error for me.
So on RK3568 HS400 modes could be made work, on remaining SoCs there was issues.
Regards, Jonas
Cheers, Quentin

Hi Quentin,
On 2024-02-01 13:40, Quentin Schulz wrote:
Hi Jonas,
On 2/1/24 11:51, Jonas Karlman wrote:
Hi Quentin,
On 2024-02-01 11:18, Quentin Schulz wrote:
Hi Jonas,
On 1/27/24 12:15, Jonas Karlman wrote:
Hi Eugen,
On 2024-01-27 04:48, Eugen Hristev wrote:
Hi Jonas,
On 1/27/24 01:26, Jonas Karlman wrote:
Writing to eMMC using DDR52 mode does not work reliably or at all on RK356x and RK3588 boards.
This is related to the old issue I encountered last year with mmc write?
Yes, I think it is.
I did some testing on RK3566/RK3568/RK3588S/RK3588 boards with different eMMC modules with following result:
Read seem to work with all enabled modes: RK3566: MMC legacy, MMC High Speed (26MHz), MMC High Speed (52MHz), MMC DDR52 (52MHz) and HS200 (200MHz) RK3568/RK3588S/RK3588: all above + HS400 (200MHz) and HS400ES (200MHz)
However, write had issues with some of the modes: MMC DDR52 (52MHz): all RK35xx HS400/HS400ES: only on RK3568 after changing hs400_txclk_tapnum to 8
HS200 seem to be the most stable write speed that worked on all SoCs.
So, dropping MMC DDR52 (52MHz) and enable use of HS200 (200MHz) seem to be the best option to get speedy and working read and write eMMC.
- we have this enabled on RK3588 Jaguar in upstream Linux... I may have
improperly tested it then, would you mind sharing how you tested this mode on RK3588 so I can reproduce this and fix it on our product if we're impacted? I assume because we have HS200/HS400/HS400-ES enabled, DDR52 would never be used? (our eMMC is soldered and support the former modes).
My main mode of testing eMMC in U-Boot has been to enable following Kconfig options,
CONFIG_MMC_HS200_SUPPORT=y CONFIG_MMC_HS400_SUPPORT=y CONFIG_MMC_HS400_ES_SUPPORT=y CONFIG_MMC_SPEED_MODE_SET=y
and from U-Boot cli run following,
=> mmc rescan <mode> && mmc info && mmc read 10000000 2000 10000 => mmc rescan <mode> && mmc info && mmc write 20000000 4000 10000
for each of the modes below.
0 = MMC legacy 1 = MMC High Speed (26MHz) 3 = MMC High Speed (52MHz) 4 = MMC DDR52 (52MHz) 10 = HS200 (200MHz) 11 = HS400 (200MHz) 12 = HS400ES (200MHz)
on different boards and different eMMC modules.
Using some modes the read or write return ERROR instead of OK. When ERROR was reported a rescan or board reset was needed to test next mode.
Please also note that I have only tested in U-Boot, not in linux.
Thanks for the tips on how to test these.
I have run the following commands on an RK3588 Jaguar (master branch + your v6.8-rc1 DTS sync patch series + Jaguar patch series):
=> for j in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19; do for i in 0 1 3 4 10 11 12; do mmc rescan $i && mmc read 10000000 2000 100000; if test $? -ne 0; then echo $i FAILED; fi; done; done
Which is 20 iterations of an mmc read at each of the 7 supported modes. The result is: 1 fail in HS200, 2 fails in HS400, the rest passes just fine.
I am wondering if your HS200 fails could be because MMC DDR52 (52MHz) was being tested prior to the HS200 mode.
What happens if you exclude the mmc-ddr-1_8v prop and mode 4 in your test loops?
I did some quick re-test on a ROCK 5A (rk3588s) and ROCK 5B (rk3588) with DDR52 removed and could only see very few read fails with HS400.
=> for j in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19; do for i in 0 1 3 4 10 11 12; do mmc rescan $i && mmc write 20000000 4000 100000; if test $? -ne 0; then echo $i FAILED; fi; done; done
Which is 20 iterations of an mmc write at each of the 7 supported modes. The result is: 20 fails in DDR52, 2 fails in HS200, the rest passes just fine.
So it seems DDR52, HS200 and HS400 aren't stable on my board, but HS400ES somehow is (which is enabled in our defconfig).
Please re-test with DDR52 mode skipped and see if you get any other result for HS200 mode.
And you are correct, HR400ES seem to also be working fine on my RK3588 boards. I can see now that on my old testing commit [1] I only mention and drop the hs400 mode and not the hs400es mode for rk3588. Could also be the change to emmc_data_strobe pinctrl that got synced from linux v6.7 that help improve HR400ES mode results.
From a very quick re-test on two boards with two different emmc modules
I could only see a few "Select HS400 failed -70" lines being reported when testing read and/or write using your test loops (with a few modes skipped and smaller amount of data to read/write). Remaining modes seem to be working okay.
[1] https://github.com/Kwiboo/u-boot-rockchip/commit/cb1521aea8dee730bddcc5772af... [2] https://lore.kernel.org/all/20231205202900.4617-2-CFSworks@gmail.com/
Regards, Jonas
I'll check if there's an easier way to test the Linux kernel than rebooting with a newer DTB between every try.
Cheers, Quentin
- Why are we not enabling HS400/HS400-ES for RK3588 boards? You seem to
be saying there are issues with HS400/HS400-ES on RK3568 but you didn't mention the status for RK3588. Did I misunderstand the last sentence? Can you please rephrase in that case?
I can see now that my wording was very confusing.
Write for HS400/HS400ES mode only worked on RK3568 after modification to the driver, on RK3588 write always returned error for me.
So on RK3568 HS400 modes could be made work, on remaining SoCs there was issues.
Regards, Jonas
Cheers, Quentin

Hi Jonas,
On 2/1/24 21:06, Jonas Karlman wrote:
Hi Quentin,
On 2024-02-01 13:40, Quentin Schulz wrote:
Hi Jonas,
On 2/1/24 11:51, Jonas Karlman wrote:
Hi Quentin,
On 2024-02-01 11:18, Quentin Schulz wrote:
Hi Jonas,
On 1/27/24 12:15, Jonas Karlman wrote:
Hi Eugen,
On 2024-01-27 04:48, Eugen Hristev wrote:
Hi Jonas,
On 1/27/24 01:26, Jonas Karlman wrote: > Writing to eMMC using DDR52 mode does not work reliably or at all on > RK356x and RK3588 boards. >
This is related to the old issue I encountered last year with mmc write?
Yes, I think it is.
I did some testing on RK3566/RK3568/RK3588S/RK3588 boards with different eMMC modules with following result:
Read seem to work with all enabled modes: RK3566: MMC legacy, MMC High Speed (26MHz), MMC High Speed (52MHz), MMC DDR52 (52MHz) and HS200 (200MHz) RK3568/RK3588S/RK3588: all above + HS400 (200MHz) and HS400ES (200MHz)
However, write had issues with some of the modes: MMC DDR52 (52MHz): all RK35xx HS400/HS400ES: only on RK3568 after changing hs400_txclk_tapnum to 8
HS200 seem to be the most stable write speed that worked on all SoCs.
So, dropping MMC DDR52 (52MHz) and enable use of HS200 (200MHz) seem to be the best option to get speedy and working read and write eMMC.
- we have this enabled on RK3588 Jaguar in upstream Linux... I may have
improperly tested it then, would you mind sharing how you tested this mode on RK3588 so I can reproduce this and fix it on our product if we're impacted? I assume because we have HS200/HS400/HS400-ES enabled, DDR52 would never be used? (our eMMC is soldered and support the former modes).
My main mode of testing eMMC in U-Boot has been to enable following Kconfig options,
CONFIG_MMC_HS200_SUPPORT=y CONFIG_MMC_HS400_SUPPORT=y CONFIG_MMC_HS400_ES_SUPPORT=y CONFIG_MMC_SPEED_MODE_SET=y
and from U-Boot cli run following,
=> mmc rescan <mode> && mmc info && mmc read 10000000 2000 10000 => mmc rescan <mode> && mmc info && mmc write 20000000 4000 10000
for each of the modes below.
0 = MMC legacy 1 = MMC High Speed (26MHz) 3 = MMC High Speed (52MHz) 4 = MMC DDR52 (52MHz) 10 = HS200 (200MHz) 11 = HS400 (200MHz) 12 = HS400ES (200MHz)
on different boards and different eMMC modules.
Using some modes the read or write return ERROR instead of OK. When ERROR was reported a rescan or board reset was needed to test next mode.
Please also note that I have only tested in U-Boot, not in linux.
Thanks for the tips on how to test these.
I have run the following commands on an RK3588 Jaguar (master branch + your v6.8-rc1 DTS sync patch series + Jaguar patch series):
=> for j in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19; do for i in 0 1 3 4 10 11 12; do mmc rescan $i && mmc read 10000000 2000 100000; if test $? -ne 0; then echo $i FAILED; fi; done; done
Which is 20 iterations of an mmc read at each of the 7 supported modes. The result is: 1 fail in HS200, 2 fails in HS400, the rest passes just fine.
I am wondering if your HS200 fails could be because MMC DDR52 (52MHz) was being tested prior to the HS200 mode.
What happens if you exclude the mmc-ddr-1_8v prop and mode 4 in your test loops?
I did some quick re-test on a ROCK 5A (rk3588s) and ROCK 5B (rk3588) with DDR52 removed and could only see very few read fails with HS400.
OK so I did something completely different instead. rescan in one mode, do a read, power cycle, rescan in another mode, do a read, power cycle, etc....
All tests passed.
Then...
=> for j in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19; do for i in 0 1 3 4 10 11 12; do mmc rescan $i && mmc write 20000000 4000 100000; if test $? -ne 0; then echo $i FAILED; fi; done; done
Which is 20 iterations of an mmc write at each of the 7 supported modes. The result is: 20 fails in DDR52, 2 fails in HS200, the rest passes just fine.
So it seems DDR52, HS200 and HS400 aren't stable on my board, but HS400ES somehow is (which is enabled in our defconfig).
I did the same for the write:
rescan in one mode, do a write, power cycle, rescan in another mode, do a write, power cycle, etc....
And this brought surprising results:
EVERYTHING except HS200, HS400 and HS400ES failed. Like not even a block was written.
Now, that was not really what I remember happening yesterday. So it seems that the modes before HS200 may rely somehow on previous rescans/reads.
So I tested this theory by just running a single mmc read of one block after doing a rescan and before doing a write. This didn't help.
Now, I forced a HS400ES read before doing writes at modes below HS200 (excluded) and they didn't work. However, once I did a single block read in HS400 instead of HS400ES, the writes in those same modes started to work (except DDR52).
They also worked when doing a single block read in HS200.
For all those tests, I still had mmc-ddr-1_8v in my DT.
So, I would say everything that isn't HS200+ is broken on RK3588? Did the modes below DDR52 work for you?
Cheers, Quentin
Please re-test with DDR52 mode skipped and see if you get any other result for HS200 mode.
And you are correct, HR400ES seem to also be working fine on my RK3588 boards. I can see now that on my old testing commit [1] I only mention and drop the hs400 mode and not the hs400es mode for rk3588. Could also be the change to emmc_data_strobe pinctrl that got synced from linux v6.7 that help improve HR400ES mode results.
From a very quick re-test on two boards with two different emmc modules I could only see a few "Select HS400 failed -70" lines being reported when testing read and/or write using your test loops (with a few modes skipped and smaller amount of data to read/write). Remaining modes seem to be working okay.
[1] https://github.com/Kwiboo/u-boot-rockchip/commit/cb1521aea8dee730bddcc5772af... [2] https://lore.kernel.org/all/20231205202900.4617-2-CFSworks@gmail.com/
Regards, Jonas
I'll check if there's an easier way to test the Linux kernel than rebooting with a newer DTB between every try.
Cheers, Quentin
- Why are we not enabling HS400/HS400-ES for RK3588 boards? You seem to
be saying there are issues with HS400/HS400-ES on RK3568 but you didn't mention the status for RK3588. Did I misunderstand the last sentence? Can you please rephrase in that case?
I can see now that my wording was very confusing.
Write for HS400/HS400ES mode only worked on RK3568 after modification to the driver, on RK3588 write always returned error for me.
So on RK3568 HS400 modes could be made work, on remaining SoCs there was issues.
Regards, Jonas
Cheers, Quentin

Hi Jonas,
On 2/2/24 12:10, Quentin Schulz wrote:
Hi Jonas,
On 2/1/24 21:06, Jonas Karlman wrote:
Hi Quentin,
On 2024-02-01 13:40, Quentin Schulz wrote:
Hi Jonas,
On 2/1/24 11:51, Jonas Karlman wrote:
Hi Quentin,
On 2024-02-01 11:18, Quentin Schulz wrote:
Hi Jonas,
On 1/27/24 12:15, Jonas Karlman wrote:
Hi Eugen,
On 2024-01-27 04:48, Eugen Hristev wrote: > Hi Jonas, > > > On 1/27/24 01:26, Jonas Karlman wrote: >> Writing to eMMC using DDR52 mode does not work reliably or at >> all on >> RK356x and RK3588 boards. >> > > > This is related to the old issue I encountered last year with mmc > write?
Yes, I think it is.
I did some testing on RK3566/RK3568/RK3588S/RK3588 boards with different eMMC modules with following result:
Read seem to work with all enabled modes: RK3566: MMC legacy, MMC High Speed (26MHz), MMC High Speed (52MHz), MMC DDR52 (52MHz) and HS200 (200MHz) RK3568/RK3588S/RK3588: all above + HS400 (200MHz) and HS400ES (200MHz)
However, write had issues with some of the modes: MMC DDR52 (52MHz): all RK35xx HS400/HS400ES: only on RK3568 after changing hs400_txclk_tapnum to 8
HS200 seem to be the most stable write speed that worked on all SoCs.
So, dropping MMC DDR52 (52MHz) and enable use of HS200 (200MHz) seem to be the best option to get speedy and working read and write eMMC.
- we have this enabled on RK3588 Jaguar in upstream Linux... I may
have improperly tested it then, would you mind sharing how you tested this mode on RK3588 so I can reproduce this and fix it on our product if we're impacted? I assume because we have HS200/HS400/HS400-ES enabled, DDR52 would never be used? (our eMMC is soldered and support the former modes).
OK so just tested this in Linux kernel 5.10 from Rockchip and v6.6.7 with some patches for rk3588 (and the jaguar dts). I ran the following tests:
$ fio --filename=/dev/mmcblk0 --rw=read --direct=1 --name=fioBench --bs=1M --ioengine=libaio --cmdprio_percentage=100 --output-format=json --allow_file_create=0 --time_based=1 --runtime=60 --ioscheduler=none
$ fio --filename=/dev/mmcblk0 --rw=write --direct=1 --name=fioBench --bs=1M --ioengine=libaio --cmdprio_percentage=100 --output-format=json --allow_file_create=0 --time_based=1 --runtime=60 --ioscheduler=none;
It worked in HS200, HS400, HS400ES without any issue. It worked in high-speed.
It was a bit "difficult" to get the kernel to switch to DDR52 because even with the property gone from the DTB it would detect the card as HS200. I had to comment out https://elixir.bootlin.com/linux/latest/source/drivers/mmc/host/sdhci.c#L455... to force it into DDR52 (or what I assume to be DDR52 :) the kernel prints: "mmc0: new DDR MMC card at address 0001" ). It failed reads in that mode so didn't even test writes, but not sure if it's a fair test with the aforementioned line commented out. I see it's also there in the SDHCI implementation in U-Boot, so maybe it's just that mmc rescan 4 doesn't actually make much sense to test since I would assume it would just detect it as HS200 even without the DT property? (or maybe something really is missing there in the SDHCI logic?).
I couldn't quickly find out how to put the eMMC into non high-speed mode so gave up on that.
Cheers, Quentin

On 2024-02-02 13:44, Quentin Schulz wrote:
OK so just tested this in Linux kernel 5.10 from Rockchip and v6.6.7 with some patches for rk3588 (and the jaguar dts). I ran the following tests:
$ fio --filename=/dev/mmcblk0 --rw=read --direct=1 --name=fioBench --bs=1M --ioengine=libaio --cmdprio_percentage=100 --output-format=json --allow_file_create=0 --time_based=1 --runtime=60 --ioscheduler=none
$ fio --filename=/dev/mmcblk0 --rw=write --direct=1 --name=fioBench --bs=1M --ioengine=libaio --cmdprio_percentage=100 --output-format=json --allow_file_create=0 --time_based=1 --runtime=60 --ioscheduler=none;
It worked in HS200, HS400, HS400ES without any issue. It worked in high-speed.
It was a bit "difficult" to get the kernel to switch to DDR52 because even with the property gone from the DTB it would detect the card as HS200. I had to comment out https://elixir.bootlin.com/linux/latest/source/drivers/mmc/host/sdhci.c#L455... to force it into DDR52 (or what I assume to be DDR52 :) the kernel prints: "mmc0: new DDR MMC card at address 0001" ).
As a note, the mode selection has been buggy like that for a while. Fixing that in the kernel drivers is already on my TODO list.
It failed reads in that mode so didn't even test writes, but not sure if it's a fair test with the aforementioned line commented out. I see it's also there in the SDHCI implementation in U-Boot, so maybe it's just that mmc rescan 4 doesn't actually make much sense to test since I would assume it would just detect it as HS200 even without the DT property? (or maybe something really is missing there in the SDHCI logic?).
I couldn't quickly find out how to put the eMMC into non high-speed mode so gave up on that.

Hi Quentin,
On 2024-02-02 12:10, Quentin Schulz wrote:
Hi Jonas,
On 2/1/24 21:06, Jonas Karlman wrote:
Hi Quentin,
On 2024-02-01 13:40, Quentin Schulz wrote:
Hi Jonas,
On 2/1/24 11:51, Jonas Karlman wrote:
Hi Quentin,
On 2024-02-01 11:18, Quentin Schulz wrote:
Hi Jonas,
On 1/27/24 12:15, Jonas Karlman wrote:
Hi Eugen,
On 2024-01-27 04:48, Eugen Hristev wrote: > Hi Jonas, > > > On 1/27/24 01:26, Jonas Karlman wrote: >> Writing to eMMC using DDR52 mode does not work reliably or at all on >> RK356x and RK3588 boards. >> > > > This is related to the old issue I encountered last year with mmc write?
Yes, I think it is.
I did some testing on RK3566/RK3568/RK3588S/RK3588 boards with different eMMC modules with following result:
Read seem to work with all enabled modes: RK3566: MMC legacy, MMC High Speed (26MHz), MMC High Speed (52MHz), MMC DDR52 (52MHz) and HS200 (200MHz) RK3568/RK3588S/RK3588: all above + HS400 (200MHz) and HS400ES (200MHz)
However, write had issues with some of the modes: MMC DDR52 (52MHz): all RK35xx HS400/HS400ES: only on RK3568 after changing hs400_txclk_tapnum to 8
HS200 seem to be the most stable write speed that worked on all SoCs.
So, dropping MMC DDR52 (52MHz) and enable use of HS200 (200MHz) seem to be the best option to get speedy and working read and write eMMC.
- we have this enabled on RK3588 Jaguar in upstream Linux... I may have
improperly tested it then, would you mind sharing how you tested this mode on RK3588 so I can reproduce this and fix it on our product if we're impacted? I assume because we have HS200/HS400/HS400-ES enabled, DDR52 would never be used? (our eMMC is soldered and support the former modes).
My main mode of testing eMMC in U-Boot has been to enable following Kconfig options,
CONFIG_MMC_HS200_SUPPORT=y CONFIG_MMC_HS400_SUPPORT=y CONFIG_MMC_HS400_ES_SUPPORT=y CONFIG_MMC_SPEED_MODE_SET=y
and from U-Boot cli run following,
=> mmc rescan <mode> && mmc info && mmc read 10000000 2000 10000 => mmc rescan <mode> && mmc info && mmc write 20000000 4000 10000
for each of the modes below.
0 = MMC legacy 1 = MMC High Speed (26MHz) 3 = MMC High Speed (52MHz) 4 = MMC DDR52 (52MHz) 10 = HS200 (200MHz) 11 = HS400 (200MHz) 12 = HS400ES (200MHz)
on different boards and different eMMC modules.
Using some modes the read or write return ERROR instead of OK. When ERROR was reported a rescan or board reset was needed to test next mode.
Please also note that I have only tested in U-Boot, not in linux.
Thanks for the tips on how to test these.
I have run the following commands on an RK3588 Jaguar (master branch + your v6.8-rc1 DTS sync patch series + Jaguar patch series):
=> for j in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19; do for i in 0 1 3 4 10 11 12; do mmc rescan $i && mmc read 10000000 2000 100000; if test $? -ne 0; then echo $i FAILED; fi; done; done
Which is 20 iterations of an mmc read at each of the 7 supported modes. The result is: 1 fail in HS200, 2 fails in HS400, the rest passes just fine.
I am wondering if your HS200 fails could be because MMC DDR52 (52MHz) was being tested prior to the HS200 mode.
What happens if you exclude the mmc-ddr-1_8v prop and mode 4 in your test loops?
I did some quick re-test on a ROCK 5A (rk3588s) and ROCK 5B (rk3588) with DDR52 removed and could only see very few read fails with HS400.
OK so I did something completely different instead. rescan in one mode, do a read, power cycle, rescan in another mode, do a read, power cycle, etc....
All tests passed.
Then...
=> for j in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19; do for i in 0 1 3 4 10 11 12; do mmc rescan $i && mmc write 20000000 4000 100000; if test $? -ne 0; then echo $i FAILED; fi; done; done
Which is 20 iterations of an mmc write at each of the 7 supported modes. The result is: 20 fails in DDR52, 2 fails in HS200, the rest passes just fine.
So it seems DDR52, HS200 and HS400 aren't stable on my board, but HS400ES somehow is (which is enabled in our defconfig).
I did the same for the write:
rescan in one mode, do a write, power cycle, rescan in another mode, do a write, power cycle, etc....
And this brought surprising results:
EVERYTHING except HS200, HS400 and HS400ES failed. Like not even a block was written.
I now vaguely remember something similar from when I tested back in November, however during re-testing before posting this series I only tested without a full power reset between different modes :-)
Now, that was not really what I remember happening yesterday. So it seems that the modes before HS200 may rely somehow on previous rescans/reads.
So I tested this theory by just running a single mmc read of one block after doing a rescan and before doing a write. This didn't help.
Now, I forced a HS400ES read before doing writes at modes below HS200 (excluded) and they didn't work. However, once I did a single block read in HS400 instead of HS400ES, the writes in those same modes started to work (except DDR52).
They also worked when doing a single block read in HS200.
Thanks for testing this more thoroughly!
For all those tests, I still had mmc-ddr-1_8v in my DT.
So, I would say everything that isn't HS200+ is broken on RK3588? Did the modes below DDR52 work for you?
I re-tested booting of a SD-card on RK3588 and found out following:
- Write in DDR52 mode never works, hence this patch - Read works in all modes directly after a power reset
- First write in modes that isn't HS200+ fails => mmc rescan 0 && mmc write 2000000 4000 1 # ERROR
- Second+ write in same mode that just failed works => mmc write 2000000 4000 1 # OK
- After a rescan to HS200 mode (probably any HS200+) first write in modes that isn't HS200+ no longer fails until power reset => mmc rescan 10 && mmc rescan 0 && mmc write 2000000 4000 1 # OK
- When rockchip_sdhci_execute_tuning() is empty, changing to HS200 mode no longer "fixes" the write for slower modes => mmc rescan 10 && mmc rescan 0 && mmc write 2000000 4000 1 # ERROR
- Trying to execute tuning for modes slower then HS200 fails as expected
So based on testing I would say that any mode that isn't HS200+ is only semi-broken because writing seem to start working after a second try. And after tuning has been executed in HS200+ any other mode seem to work.
Maybe we should enable the HS200 options for ROCKCHIP_RK3588 by default instead of explicitly enabling it in defconfig for boards that have MMC_SDHCI_ROCKCHIP enabled?
--- a/drivers/mmc/Kconfig +++ b/drivers/mmc/Kconfig @@ -665,6 +665,8 @@ config MMC_SDHCI_ROCKCHIP depends on ARCH_ROCKCHIP depends on DM_MMC && BLK depends on MMC_SDHCI + imply MMC_HS200_SUPPORT if ROCKCHIP_RK3588 + imply SPL_MMC_HS200_SUPPORT if ROCKCHIP_RK3588 help Support for Arasan SDHCI host controller on Rockchip ARM SoCs platform
Regards, Jonas
Cheers, Quentin
Please re-test with DDR52 mode skipped and see if you get any other result for HS200 mode.
And you are correct, HR400ES seem to also be working fine on my RK3588 boards. I can see now that on my old testing commit [1] I only mention and drop the hs400 mode and not the hs400es mode for rk3588. Could also be the change to emmc_data_strobe pinctrl that got synced from linux v6.7 that help improve HR400ES mode results.
From a very quick re-test on two boards with two different emmc modules I could only see a few "Select HS400 failed -70" lines being reported when testing read and/or write using your test loops (with a few modes skipped and smaller amount of data to read/write). Remaining modes seem to be working okay.
[1] https://github.com/Kwiboo/u-boot-rockchip/commit/cb1521aea8dee730bddcc5772af... [2] https://lore.kernel.org/all/20231205202900.4617-2-CFSworks@gmail.com/
Regards, Jonas
I'll check if there's an easier way to test the Linux kernel than rebooting with a newer DTB between every try.
Cheers, Quentin
- Why are we not enabling HS400/HS400-ES for RK3588 boards? You seem to
be saying there are issues with HS400/HS400-ES on RK3568 but you didn't mention the status for RK3588. Did I misunderstand the last sentence? Can you please rephrase in that case?
I can see now that my wording was very confusing.
Write for HS400/HS400ES mode only worked on RK3568 after modification to the driver, on RK3588 write always returned error for me.
So on RK3568 HS400 modes could be made work, on remaining SoCs there was issues.
Regards, Jonas
Cheers, Quentin

On 2024/1/27 07:26, Jonas Karlman wrote:
Writing to eMMC using DDR52 mode does not work reliably or at all on RK356x and RK3588 boards.
Fix this by removing the mmc-ddr-1_8v prop from sdhci nodes.
Signed-off-by: Jonas Karlman jonas@kwiboo.se
Reviewed-by: Kever Yang kever.yang@rock-chips.com
Thanks, - Kever
arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi | 1 - arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi | 1 - arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi | 1 - arch/arm/dts/rk3566-soquartz-u-boot.dtsi | 1 - arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi | 1 - arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi | 1 - arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi | 1 - arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi | 1 - arch/arm/dts/rk3568-rock-3a-u-boot.dtsi | 1 - arch/arm/dts/rk3588-rock-5b-u-boot.dtsi | 1 - arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi | 1 - arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi | 1 - 12 files changed, 12 deletions(-)
diff --git a/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi b/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi index 11976fd3a6e0..930d660868bb 100644 --- a/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi +++ b/arch/arm/dts/rk3566-quartz64-a-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; pinctrl-names = "default"; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>; };
diff --git a/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi b/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi index 8de9d1535efb..c235b4357f7d 100644 --- a/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi +++ b/arch/arm/dts/rk3566-quartz64-b-u-boot.dtsi @@ -4,7 +4,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; pinctrl-names = "default"; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>; };
diff --git a/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi b/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi index 158f652cb3b1..e0e501deccfe 100644 --- a/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi +++ b/arch/arm/dts/rk3566-radxa-cm3-io-u-boot.dtsi @@ -7,5 +7,4 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; };
diff --git a/arch/arm/dts/rk3566-soquartz-u-boot.dtsi b/arch/arm/dts/rk3566-soquartz-u-boot.dtsi index f65f4067f3e9..5e46a2422d60 100644 --- a/arch/arm/dts/rk3566-soquartz-u-boot.dtsi +++ b/arch/arm/dts/rk3566-soquartz-u-boot.dtsi @@ -4,7 +4,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; pinctrl-names = "default"; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>; };
diff --git a/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi b/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi index a44ac35bdacd..1597473017ed 100644 --- a/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi +++ b/arch/arm/dts/rk3568-lubancat-2-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe; pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>;
diff --git a/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi b/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi index 62f572c4cf9f..64c43374c042 100644 --- a/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi +++ b/arch/arm/dts/rk3568-nanopi-r5s-u-boot.dtsi @@ -14,7 +14,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe;
diff --git a/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi b/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi index ecba91aa30f5..1fc71faa9e07 100644 --- a/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi +++ b/arch/arm/dts/rk3568-odroid-m1-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe;
diff --git a/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi b/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi index caf524443079..74755a44eaee 100644 --- a/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi +++ b/arch/arm/dts/rk3568-radxa-e25-u-boot.dtsi @@ -16,7 +16,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe;
diff --git a/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi b/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi index 46ebb77283f1..5b823fcca5fb 100644 --- a/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi +++ b/arch/arm/dts/rk3568-rock-3a-u-boot.dtsi @@ -20,7 +20,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; mmc-hs400-1_8v; mmc-hs400-enhanced-strobe;
diff --git a/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi b/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi index e99e60185ebe..9ee9dd051e32 100644 --- a/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi +++ b/arch/arm/dts/rk3588-rock-5b-u-boot.dtsi @@ -31,7 +31,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; };
diff --git a/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi b/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi index 471508a9ed74..ca2a684f3541 100644 --- a/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi +++ b/arch/arm/dts/rk3588-turing-rk1-u-boot.dtsi @@ -8,7 +8,6 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; };
diff --git a/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi b/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi index 9a6a353088df..efba0c359ba5 100644 --- a/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi +++ b/arch/arm/dts/rk3588s-rock-5a-u-boot.dtsi @@ -7,6 +7,5 @@
&sdhci { cap-mmc-highspeed;
- mmc-ddr-1_8v; mmc-hs200-1_8v; };

Writing to eMMC using HS200 mode work more reliably then other modes on RK356x boards.
Enable MMC_HS200_SUPPORT Kconfig option to prefer use of HS200 mode.
Signed-off-by: Jonas Karlman jonas@kwiboo.se --- configs/anbernic-rgxx3-rk3566_defconfig | 2 ++ configs/bpi-r2-pro-rk3568_defconfig | 2 ++ configs/evb-rk3568_defconfig | 2 ++ configs/lubancat-2-rk3568_defconfig | 2 ++ configs/odroid-m1-rk3568_defconfig | 2 ++ configs/quartz64-a-rk3566_defconfig | 2 ++ configs/quartz64-b-rk3566_defconfig | 2 ++ configs/radxa-cm3-io-rk3566_defconfig | 2 ++ configs/rock-3a-rk3568_defconfig | 2 ++ configs/soquartz-blade-rk3566_defconfig | 2 ++ configs/soquartz-cm4-rk3566_defconfig | 2 ++ configs/soquartz-model-a-rk3566_defconfig | 2 ++ 12 files changed, 24 insertions(+)
diff --git a/configs/anbernic-rgxx3-rk3566_defconfig b/configs/anbernic-rgxx3-rk3566_defconfig index ed6643d9d4fa..295c0bd3fc61 100644 --- a/configs/anbernic-rgxx3-rk3566_defconfig +++ b/configs/anbernic-rgxx3-rk3566_defconfig @@ -61,6 +61,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/bpi-r2-pro-rk3568_defconfig b/configs/bpi-r2-pro-rk3568_defconfig index e6e0e6fc6fa6..c9e1cd2c2c85 100644 --- a/configs/bpi-r2-pro-rk3568_defconfig +++ b/configs/bpi-r2-pro-rk3568_defconfig @@ -60,6 +60,8 @@ CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y CONFIG_SUPPORT_EMMC_BOOT=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/evb-rk3568_defconfig b/configs/evb-rk3568_defconfig index cb9b87ff12cb..19eab9bf00ac 100644 --- a/configs/evb-rk3568_defconfig +++ b/configs/evb-rk3568_defconfig @@ -54,6 +54,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/lubancat-2-rk3568_defconfig b/configs/lubancat-2-rk3568_defconfig index 80ae6ec3a2e9..c06a447fda26 100644 --- a/configs/lubancat-2-rk3568_defconfig +++ b/configs/lubancat-2-rk3568_defconfig @@ -55,6 +55,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/odroid-m1-rk3568_defconfig b/configs/odroid-m1-rk3568_defconfig index 3130e341e776..7fed6e7da597 100644 --- a/configs/odroid-m1-rk3568_defconfig +++ b/configs/odroid-m1-rk3568_defconfig @@ -72,6 +72,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/quartz64-a-rk3566_defconfig b/configs/quartz64-a-rk3566_defconfig index ade08867f60f..fd6b0e528834 100644 --- a/configs/quartz64-a-rk3566_defconfig +++ b/configs/quartz64-a-rk3566_defconfig @@ -71,6 +71,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/quartz64-b-rk3566_defconfig b/configs/quartz64-b-rk3566_defconfig index 8d01db54407d..ec7a677fd3d3 100644 --- a/configs/quartz64-b-rk3566_defconfig +++ b/configs/quartz64-b-rk3566_defconfig @@ -69,6 +69,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/radxa-cm3-io-rk3566_defconfig b/configs/radxa-cm3-io-rk3566_defconfig index 4b606dcb8e94..10626acfdea2 100644 --- a/configs/radxa-cm3-io-rk3566_defconfig +++ b/configs/radxa-cm3-io-rk3566_defconfig @@ -55,6 +55,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/rock-3a-rk3568_defconfig b/configs/rock-3a-rk3568_defconfig index 18372a570eb7..2b944163f5a9 100644 --- a/configs/rock-3a-rk3568_defconfig +++ b/configs/rock-3a-rk3568_defconfig @@ -68,6 +68,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/soquartz-blade-rk3566_defconfig b/configs/soquartz-blade-rk3566_defconfig index 9693cc2f9eb9..af04dccf4923 100644 --- a/configs/soquartz-blade-rk3566_defconfig +++ b/configs/soquartz-blade-rk3566_defconfig @@ -62,6 +62,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/soquartz-cm4-rk3566_defconfig b/configs/soquartz-cm4-rk3566_defconfig index 9c6b12d23028..e669ca14c1cc 100644 --- a/configs/soquartz-cm4-rk3566_defconfig +++ b/configs/soquartz-cm4-rk3566_defconfig @@ -62,6 +62,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/soquartz-model-a-rk3566_defconfig b/configs/soquartz-model-a-rk3566_defconfig index fd72d78a47a8..3beeab1dbba8 100644 --- a/configs/soquartz-model-a-rk3566_defconfig +++ b/configs/soquartz-model-a-rk3566_defconfig @@ -63,6 +63,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y

On 2024/1/27 07:26, Jonas Karlman wrote:
Writing to eMMC using HS200 mode work more reliably then other modes on RK356x boards.
Enable MMC_HS200_SUPPORT Kconfig option to prefer use of HS200 mode.
Signed-off-by: Jonas Karlman jonas@kwiboo.se
Reviewed-by: Kever Yang kever.yang@rock-chips.com
Thanks, - Kever
configs/anbernic-rgxx3-rk3566_defconfig | 2 ++ configs/bpi-r2-pro-rk3568_defconfig | 2 ++ configs/evb-rk3568_defconfig | 2 ++ configs/lubancat-2-rk3568_defconfig | 2 ++ configs/odroid-m1-rk3568_defconfig | 2 ++ configs/quartz64-a-rk3566_defconfig | 2 ++ configs/quartz64-b-rk3566_defconfig | 2 ++ configs/radxa-cm3-io-rk3566_defconfig | 2 ++ configs/rock-3a-rk3568_defconfig | 2 ++ configs/soquartz-blade-rk3566_defconfig | 2 ++ configs/soquartz-cm4-rk3566_defconfig | 2 ++ configs/soquartz-model-a-rk3566_defconfig | 2 ++ 12 files changed, 24 insertions(+)
diff --git a/configs/anbernic-rgxx3-rk3566_defconfig b/configs/anbernic-rgxx3-rk3566_defconfig index ed6643d9d4fa..295c0bd3fc61 100644 --- a/configs/anbernic-rgxx3-rk3566_defconfig +++ b/configs/anbernic-rgxx3-rk3566_defconfig @@ -61,6 +61,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/bpi-r2-pro-rk3568_defconfig b/configs/bpi-r2-pro-rk3568_defconfig index e6e0e6fc6fa6..c9e1cd2c2c85 100644 --- a/configs/bpi-r2-pro-rk3568_defconfig +++ b/configs/bpi-r2-pro-rk3568_defconfig @@ -60,6 +60,8 @@ CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y CONFIG_SUPPORT_EMMC_BOOT=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/evb-rk3568_defconfig b/configs/evb-rk3568_defconfig index cb9b87ff12cb..19eab9bf00ac 100644 --- a/configs/evb-rk3568_defconfig +++ b/configs/evb-rk3568_defconfig @@ -54,6 +54,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/lubancat-2-rk3568_defconfig b/configs/lubancat-2-rk3568_defconfig index 80ae6ec3a2e9..c06a447fda26 100644 --- a/configs/lubancat-2-rk3568_defconfig +++ b/configs/lubancat-2-rk3568_defconfig @@ -55,6 +55,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/odroid-m1-rk3568_defconfig b/configs/odroid-m1-rk3568_defconfig index 3130e341e776..7fed6e7da597 100644 --- a/configs/odroid-m1-rk3568_defconfig +++ b/configs/odroid-m1-rk3568_defconfig @@ -72,6 +72,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/quartz64-a-rk3566_defconfig b/configs/quartz64-a-rk3566_defconfig index ade08867f60f..fd6b0e528834 100644 --- a/configs/quartz64-a-rk3566_defconfig +++ b/configs/quartz64-a-rk3566_defconfig @@ -71,6 +71,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/quartz64-b-rk3566_defconfig b/configs/quartz64-b-rk3566_defconfig index 8d01db54407d..ec7a677fd3d3 100644 --- a/configs/quartz64-b-rk3566_defconfig +++ b/configs/quartz64-b-rk3566_defconfig @@ -69,6 +69,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/radxa-cm3-io-rk3566_defconfig b/configs/radxa-cm3-io-rk3566_defconfig index 4b606dcb8e94..10626acfdea2 100644 --- a/configs/radxa-cm3-io-rk3566_defconfig +++ b/configs/radxa-cm3-io-rk3566_defconfig @@ -55,6 +55,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/rock-3a-rk3568_defconfig b/configs/rock-3a-rk3568_defconfig index 18372a570eb7..2b944163f5a9 100644 --- a/configs/rock-3a-rk3568_defconfig +++ b/configs/rock-3a-rk3568_defconfig @@ -68,6 +68,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/soquartz-blade-rk3566_defconfig b/configs/soquartz-blade-rk3566_defconfig index 9693cc2f9eb9..af04dccf4923 100644 --- a/configs/soquartz-blade-rk3566_defconfig +++ b/configs/soquartz-blade-rk3566_defconfig @@ -62,6 +62,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/soquartz-cm4-rk3566_defconfig b/configs/soquartz-cm4-rk3566_defconfig index 9c6b12d23028..e669ca14c1cc 100644 --- a/configs/soquartz-cm4-rk3566_defconfig +++ b/configs/soquartz-cm4-rk3566_defconfig @@ -62,6 +62,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/soquartz-model-a-rk3566_defconfig b/configs/soquartz-model-a-rk3566_defconfig index fd72d78a47a8..3beeab1dbba8 100644 --- a/configs/soquartz-model-a-rk3566_defconfig +++ b/configs/soquartz-model-a-rk3566_defconfig @@ -63,6 +63,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y

On Sat, Jan 27, 2024 at 10:32 AM Jonas Karlman jonas@kwiboo.se wrote:
Writing to eMMC using HS200 mode work more reliably then other modes on RK356x boards.
Enable MMC_HS200_SUPPORT Kconfig option to prefer use of HS200 mode.
Signed-off-by: Jonas Karlman jonas@kwiboo.se
Reviewed-by: Weizhao Ouyang o451686892@gmail.com
BR, Weizhao
configs/anbernic-rgxx3-rk3566_defconfig | 2 ++ configs/bpi-r2-pro-rk3568_defconfig | 2 ++ configs/evb-rk3568_defconfig | 2 ++ configs/lubancat-2-rk3568_defconfig | 2 ++ configs/odroid-m1-rk3568_defconfig | 2 ++ configs/quartz64-a-rk3566_defconfig | 2 ++ configs/quartz64-b-rk3566_defconfig | 2 ++ configs/radxa-cm3-io-rk3566_defconfig | 2 ++ configs/rock-3a-rk3568_defconfig | 2 ++ configs/soquartz-blade-rk3566_defconfig | 2 ++ configs/soquartz-cm4-rk3566_defconfig | 2 ++ configs/soquartz-model-a-rk3566_defconfig | 2 ++ 12 files changed, 24 insertions(+)
diff --git a/configs/anbernic-rgxx3-rk3566_defconfig b/configs/anbernic-rgxx3-rk3566_defconfig index ed6643d9d4fa..295c0bd3fc61 100644 --- a/configs/anbernic-rgxx3-rk3566_defconfig +++ b/configs/anbernic-rgxx3-rk3566_defconfig @@ -61,6 +61,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/bpi-r2-pro-rk3568_defconfig b/configs/bpi-r2-pro-rk3568_defconfig index e6e0e6fc6fa6..c9e1cd2c2c85 100644 --- a/configs/bpi-r2-pro-rk3568_defconfig +++ b/configs/bpi-r2-pro-rk3568_defconfig @@ -60,6 +60,8 @@ CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y CONFIG_SUPPORT_EMMC_BOOT=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/evb-rk3568_defconfig b/configs/evb-rk3568_defconfig index cb9b87ff12cb..19eab9bf00ac 100644 --- a/configs/evb-rk3568_defconfig +++ b/configs/evb-rk3568_defconfig @@ -54,6 +54,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/lubancat-2-rk3568_defconfig b/configs/lubancat-2-rk3568_defconfig index 80ae6ec3a2e9..c06a447fda26 100644 --- a/configs/lubancat-2-rk3568_defconfig +++ b/configs/lubancat-2-rk3568_defconfig @@ -55,6 +55,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/odroid-m1-rk3568_defconfig b/configs/odroid-m1-rk3568_defconfig index 3130e341e776..7fed6e7da597 100644 --- a/configs/odroid-m1-rk3568_defconfig +++ b/configs/odroid-m1-rk3568_defconfig @@ -72,6 +72,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/quartz64-a-rk3566_defconfig b/configs/quartz64-a-rk3566_defconfig index ade08867f60f..fd6b0e528834 100644 --- a/configs/quartz64-a-rk3566_defconfig +++ b/configs/quartz64-a-rk3566_defconfig @@ -71,6 +71,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/quartz64-b-rk3566_defconfig b/configs/quartz64-b-rk3566_defconfig index 8d01db54407d..ec7a677fd3d3 100644 --- a/configs/quartz64-b-rk3566_defconfig +++ b/configs/quartz64-b-rk3566_defconfig @@ -69,6 +69,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/radxa-cm3-io-rk3566_defconfig b/configs/radxa-cm3-io-rk3566_defconfig index 4b606dcb8e94..10626acfdea2 100644 --- a/configs/radxa-cm3-io-rk3566_defconfig +++ b/configs/radxa-cm3-io-rk3566_defconfig @@ -55,6 +55,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/rock-3a-rk3568_defconfig b/configs/rock-3a-rk3568_defconfig index 18372a570eb7..2b944163f5a9 100644 --- a/configs/rock-3a-rk3568_defconfig +++ b/configs/rock-3a-rk3568_defconfig @@ -68,6 +68,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/soquartz-blade-rk3566_defconfig b/configs/soquartz-blade-rk3566_defconfig index 9693cc2f9eb9..af04dccf4923 100644 --- a/configs/soquartz-blade-rk3566_defconfig +++ b/configs/soquartz-blade-rk3566_defconfig @@ -62,6 +62,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/soquartz-cm4-rk3566_defconfig b/configs/soquartz-cm4-rk3566_defconfig index 9c6b12d23028..e669ca14c1cc 100644 --- a/configs/soquartz-cm4-rk3566_defconfig +++ b/configs/soquartz-cm4-rk3566_defconfig @@ -62,6 +62,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/soquartz-model-a-rk3566_defconfig b/configs/soquartz-model-a-rk3566_defconfig index fd72d78a47a8..3beeab1dbba8 100644 --- a/configs/soquartz-model-a-rk3566_defconfig +++ b/configs/soquartz-model-a-rk3566_defconfig @@ -63,6 +63,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y -- 2.43.0

Writing to eMMC using HS200 mode work more reliably then other modes on RK3588 boards.
Enable MMC_HS200_SUPPORT Kconfig option to prefer use of HS200 mode.
Signed-off-by: Jonas Karlman jonas@kwiboo.se --- configs/evb-rk3588_defconfig | 2 ++ configs/nanopc-t6-rk3588_defconfig | 2 ++ configs/neu6a-io-rk3588_defconfig | 2 ++ configs/neu6b-io-rk3588_defconfig | 2 ++ configs/orangepi-5-plus-rk3588_defconfig | 2 ++ configs/quartzpro64-rk3588_defconfig | 2 ++ configs/rock5a-rk3588s_defconfig | 2 ++ configs/rock5b-rk3588_defconfig | 2 ++ configs/turing-rk1-rk3588_defconfig | 2 ++ 9 files changed, 18 insertions(+)
diff --git a/configs/evb-rk3588_defconfig b/configs/evb-rk3588_defconfig index 0b7b4f2f627a..2dfdc71259f7 100644 --- a/configs/evb-rk3588_defconfig +++ b/configs/evb-rk3588_defconfig @@ -53,6 +53,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/nanopc-t6-rk3588_defconfig b/configs/nanopc-t6-rk3588_defconfig index 760993220929..26dcf3aae21c 100644 --- a/configs/nanopc-t6-rk3588_defconfig +++ b/configs/nanopc-t6-rk3588_defconfig @@ -66,6 +66,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/neu6a-io-rk3588_defconfig b/configs/neu6a-io-rk3588_defconfig index d5301c630b2a..a6549420c01e 100644 --- a/configs/neu6a-io-rk3588_defconfig +++ b/configs/neu6a-io-rk3588_defconfig @@ -48,6 +48,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/neu6b-io-rk3588_defconfig b/configs/neu6b-io-rk3588_defconfig index b13c9b5db1b0..b5739de147d8 100644 --- a/configs/neu6b-io-rk3588_defconfig +++ b/configs/neu6b-io-rk3588_defconfig @@ -48,6 +48,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/orangepi-5-plus-rk3588_defconfig b/configs/orangepi-5-plus-rk3588_defconfig index a58f96d57798..e5325158d2af 100644 --- a/configs/orangepi-5-plus-rk3588_defconfig +++ b/configs/orangepi-5-plus-rk3588_defconfig @@ -69,6 +69,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/quartzpro64-rk3588_defconfig b/configs/quartzpro64-rk3588_defconfig index 85af4c4ff955..fd8304debdbb 100644 --- a/configs/quartzpro64-rk3588_defconfig +++ b/configs/quartzpro64-rk3588_defconfig @@ -53,6 +53,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/rock5a-rk3588s_defconfig b/configs/rock5a-rk3588s_defconfig index efa7bcbdcda6..10d6f6580490 100644 --- a/configs/rock5a-rk3588s_defconfig +++ b/configs/rock5a-rk3588s_defconfig @@ -56,6 +56,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/rock5b-rk3588_defconfig b/configs/rock5b-rk3588_defconfig index a0678ff1290c..76f57340df5a 100644 --- a/configs/rock5b-rk3588_defconfig +++ b/configs/rock5b-rk3588_defconfig @@ -71,6 +71,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/turing-rk1-rk3588_defconfig b/configs/turing-rk1-rk3588_defconfig index 289f2da775c5..0d6c34d468e3 100644 --- a/configs/turing-rk1-rk3588_defconfig +++ b/configs/turing-rk1-rk3588_defconfig @@ -75,6 +75,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y

On 2024/1/27 07:26, Jonas Karlman wrote:
Writing to eMMC using HS200 mode work more reliably then other modes on RK3588 boards.
Enable MMC_HS200_SUPPORT Kconfig option to prefer use of HS200 mode.
Signed-off-by: Jonas Karlman jonas@kwiboo.se
Reviewed-by: Kever Yang kever.yang@rock-chips.com
Thanks, - Kever
configs/evb-rk3588_defconfig | 2 ++ configs/nanopc-t6-rk3588_defconfig | 2 ++ configs/neu6a-io-rk3588_defconfig | 2 ++ configs/neu6b-io-rk3588_defconfig | 2 ++ configs/orangepi-5-plus-rk3588_defconfig | 2 ++ configs/quartzpro64-rk3588_defconfig | 2 ++ configs/rock5a-rk3588s_defconfig | 2 ++ configs/rock5b-rk3588_defconfig | 2 ++ configs/turing-rk1-rk3588_defconfig | 2 ++ 9 files changed, 18 insertions(+)
diff --git a/configs/evb-rk3588_defconfig b/configs/evb-rk3588_defconfig index 0b7b4f2f627a..2dfdc71259f7 100644 --- a/configs/evb-rk3588_defconfig +++ b/configs/evb-rk3588_defconfig @@ -53,6 +53,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/nanopc-t6-rk3588_defconfig b/configs/nanopc-t6-rk3588_defconfig index 760993220929..26dcf3aae21c 100644 --- a/configs/nanopc-t6-rk3588_defconfig +++ b/configs/nanopc-t6-rk3588_defconfig @@ -66,6 +66,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/neu6a-io-rk3588_defconfig b/configs/neu6a-io-rk3588_defconfig index d5301c630b2a..a6549420c01e 100644 --- a/configs/neu6a-io-rk3588_defconfig +++ b/configs/neu6a-io-rk3588_defconfig @@ -48,6 +48,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/neu6b-io-rk3588_defconfig b/configs/neu6b-io-rk3588_defconfig index b13c9b5db1b0..b5739de147d8 100644 --- a/configs/neu6b-io-rk3588_defconfig +++ b/configs/neu6b-io-rk3588_defconfig @@ -48,6 +48,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/orangepi-5-plus-rk3588_defconfig b/configs/orangepi-5-plus-rk3588_defconfig index a58f96d57798..e5325158d2af 100644 --- a/configs/orangepi-5-plus-rk3588_defconfig +++ b/configs/orangepi-5-plus-rk3588_defconfig @@ -69,6 +69,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/quartzpro64-rk3588_defconfig b/configs/quartzpro64-rk3588_defconfig index 85af4c4ff955..fd8304debdbb 100644 --- a/configs/quartzpro64-rk3588_defconfig +++ b/configs/quartzpro64-rk3588_defconfig @@ -53,6 +53,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/rock5a-rk3588s_defconfig b/configs/rock5a-rk3588s_defconfig index efa7bcbdcda6..10d6f6580490 100644 --- a/configs/rock5a-rk3588s_defconfig +++ b/configs/rock5a-rk3588s_defconfig @@ -56,6 +56,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/rock5b-rk3588_defconfig b/configs/rock5b-rk3588_defconfig index a0678ff1290c..76f57340df5a 100644 --- a/configs/rock5b-rk3588_defconfig +++ b/configs/rock5b-rk3588_defconfig @@ -71,6 +71,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/turing-rk1-rk3588_defconfig b/configs/turing-rk1-rk3588_defconfig index 289f2da775c5..0d6c34d468e3 100644 --- a/configs/turing-rk1-rk3588_defconfig +++ b/configs/turing-rk1-rk3588_defconfig @@ -75,6 +75,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y

On Sat, Jan 27, 2024 at 7:27 AM Jonas Karlman jonas@kwiboo.se wrote:
Writing to eMMC using HS200 mode work more reliably then other modes on RK3588 boards.
Enable MMC_HS200_SUPPORT Kconfig option to prefer use of HS200 mode.
Signed-off-by: Jonas Karlman jonas@kwiboo.se
Reviewed-by: Weizhao Ouyang o451686892@gmail.com
BR, Weizhao
configs/evb-rk3588_defconfig | 2 ++ configs/nanopc-t6-rk3588_defconfig | 2 ++ configs/neu6a-io-rk3588_defconfig | 2 ++ configs/neu6b-io-rk3588_defconfig | 2 ++ configs/orangepi-5-plus-rk3588_defconfig | 2 ++ configs/quartzpro64-rk3588_defconfig | 2 ++ configs/rock5a-rk3588s_defconfig | 2 ++ configs/rock5b-rk3588_defconfig | 2 ++ configs/turing-rk1-rk3588_defconfig | 2 ++ 9 files changed, 18 insertions(+)
diff --git a/configs/evb-rk3588_defconfig b/configs/evb-rk3588_defconfig index 0b7b4f2f627a..2dfdc71259f7 100644 --- a/configs/evb-rk3588_defconfig +++ b/configs/evb-rk3588_defconfig @@ -53,6 +53,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/nanopc-t6-rk3588_defconfig b/configs/nanopc-t6-rk3588_defconfig index 760993220929..26dcf3aae21c 100644 --- a/configs/nanopc-t6-rk3588_defconfig +++ b/configs/nanopc-t6-rk3588_defconfig @@ -66,6 +66,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/neu6a-io-rk3588_defconfig b/configs/neu6a-io-rk3588_defconfig index d5301c630b2a..a6549420c01e 100644 --- a/configs/neu6a-io-rk3588_defconfig +++ b/configs/neu6a-io-rk3588_defconfig @@ -48,6 +48,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/neu6b-io-rk3588_defconfig b/configs/neu6b-io-rk3588_defconfig index b13c9b5db1b0..b5739de147d8 100644 --- a/configs/neu6b-io-rk3588_defconfig +++ b/configs/neu6b-io-rk3588_defconfig @@ -48,6 +48,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/orangepi-5-plus-rk3588_defconfig b/configs/orangepi-5-plus-rk3588_defconfig index a58f96d57798..e5325158d2af 100644 --- a/configs/orangepi-5-plus-rk3588_defconfig +++ b/configs/orangepi-5-plus-rk3588_defconfig @@ -69,6 +69,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/quartzpro64-rk3588_defconfig b/configs/quartzpro64-rk3588_defconfig index 85af4c4ff955..fd8304debdbb 100644 --- a/configs/quartzpro64-rk3588_defconfig +++ b/configs/quartzpro64-rk3588_defconfig @@ -53,6 +53,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/rock5a-rk3588s_defconfig b/configs/rock5a-rk3588s_defconfig index efa7bcbdcda6..10d6f6580490 100644 --- a/configs/rock5a-rk3588s_defconfig +++ b/configs/rock5a-rk3588s_defconfig @@ -56,6 +56,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/rock5b-rk3588_defconfig b/configs/rock5b-rk3588_defconfig index a0678ff1290c..76f57340df5a 100644 --- a/configs/rock5b-rk3588_defconfig +++ b/configs/rock5b-rk3588_defconfig @@ -71,6 +71,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y diff --git a/configs/turing-rk1-rk3588_defconfig b/configs/turing-rk1-rk3588_defconfig index 289f2da775c5..0d6c34d468e3 100644 --- a/configs/turing-rk1-rk3588_defconfig +++ b/configs/turing-rk1-rk3588_defconfig @@ -75,6 +75,8 @@ CONFIG_ROCKCHIP_GPIO=y CONFIG_SYS_I2C_ROCKCHIP=y CONFIG_MISC=y CONFIG_SUPPORT_EMMC_RPMB=y +CONFIG_MMC_HS200_SUPPORT=y +CONFIG_SPL_MMC_HS200_SUPPORT=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y -- 2.43.0
participants (6)
-
Dragan Simic
-
Eugen Hristev
-
Jonas Karlman
-
Kever Yang
-
Quentin Schulz
-
Weizhao Ouyang