From b0868873db1d39f357b75c905ff6fd5e26e57dc9 Mon Sep 17 00:00:00 2001 From: Yifeng Zhao Date: Thu, 17 Jun 2021 11:13:21 +0800 Subject: [PATCH] mmc: sdhci-of-dwcmshc: rk3568: do not enable DLL while the clock rate less than 52mhz The DLL may not be able to lock while the clock rate less than 52mhz. Signed-off-by: Yifeng Zhao Change-Id: Ifacc3da516d78f5f242d8b03a60500a7dfe28993 --- drivers/mmc/host/sdhci-of-dwcmshc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mmc/host/sdhci-of-dwcmshc.c b/drivers/mmc/host/sdhci-of-dwcmshc.c index 18c3cf9723be..dd45dcecdac6 100644 --- a/drivers/mmc/host/sdhci-of-dwcmshc.c +++ b/drivers/mmc/host/sdhci-of-dwcmshc.c @@ -182,7 +182,7 @@ static void dwcmshc_rk_set_clock(struct sdhci_host *host, unsigned int clock) extra &= ~BIT(0); sdhci_writel(host, extra, DWCMSHC_HOST_CTRL3); - if (clock <= 400000) { + if (clock <= 52000000) { /* Disable DLL and reset both of sample and drive clock */ sdhci_writel(host, 0, DWCMSHC_EMMC_DLL_CTRL); sdhci_writel(host, 0, DWCMSHC_EMMC_DLL_RXCLK);