From 6e2b8344d60c0bb9ca7110ea533ffbb9361dde7e Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Wed, 17 May 2023 18:40:41 +0000 Subject: [PATCH] rockchip: rock-pi-4: Use SDMA to boost eMMC performance Enable the use of SDMA mode to boost eMMC performance on ROCK Pi 4. Also add missing flags to indicate the supported MMC modes. Using mmc read command to read 32 MiB data shows following improvement: => time mmc read 10000000 2000 10000 Before: time: 3.178 seconds After: time: 0.402 seconds This also enables CONFIG_SPL_FIT_SIGNATURE option to help discover any possible future issue with loading TF-A into DRAM/SRAM. Signed-off-by: Jonas Karlman Reviewed-by: Kever Yang --- arch/arm/dts/rk3399-rock-pi-4-u-boot.dtsi | 6 ++++++ configs/rock-pi-4-rk3399_defconfig | 2 ++ 2 files changed, 8 insertions(+) diff --git a/arch/arm/dts/rk3399-rock-pi-4-u-boot.dtsi b/arch/arm/dts/rk3399-rock-pi-4-u-boot.dtsi index c17e769f64..60122f3bcd 100644 --- a/arch/arm/dts/rk3399-rock-pi-4-u-boot.dtsi +++ b/arch/arm/dts/rk3399-rock-pi-4-u-boot.dtsi @@ -12,6 +12,12 @@ }; }; +&sdhci { + cap-mmc-highspeed; + mmc-ddr-1_8v; + mmc-hs200-1_8v; +}; + &vdd_log { regulator-init-microvolt = <950000>; }; diff --git a/configs/rock-pi-4-rk3399_defconfig b/configs/rock-pi-4-rk3399_defconfig index cd93093cd2..4b984adc6e 100644 --- a/configs/rock-pi-4-rk3399_defconfig +++ b/configs/rock-pi-4-rk3399_defconfig @@ -19,6 +19,7 @@ CONFIG_SYS_LOAD_ADDR=0x800800 CONFIG_PCI=y CONFIG_DEBUG_UART=y # CONFIG_ANDROID_BOOT_IMAGE is not set +CONFIG_SPL_FIT_SIGNATURE=y CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock-pi-4a.dtb" CONFIG_DISPLAY_BOARDINFO_LATE=y CONFIG_MISC_INIT_R=y @@ -56,6 +57,7 @@ CONFIG_ROCKCHIP_EFUSE=y CONFIG_MMC_DW=y CONFIG_MMC_DW_ROCKCHIP=y CONFIG_MMC_SDHCI=y +CONFIG_MMC_SDHCI_SDMA=y CONFIG_MMC_SDHCI_ROCKCHIP=y CONFIG_ETH_DESIGNWARE=y CONFIG_GMAC_ROCKCHIP=y