[U-Boot] [PATCH 25/33] mmc: sdhci: update host->clock after clock setting

Ziyuan Xu xzy.xu at rock-chips.com
Mon May 15 06:07:19 UTC 2017


Overwrite host->clock after clock setting to avoid repetitive reset
clock.

Signed-off-by: Ziyuan Xu <xzy.xu at rock-chips.com>
---

 drivers/mmc/sdhci.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/mmc/sdhci.c b/drivers/mmc/sdhci.c
index 48bac04..ad86278 100644
--- a/drivers/mmc/sdhci.c
+++ b/drivers/mmc/sdhci.c
@@ -390,6 +390,9 @@ static int sdhci_set_clock(struct mmc *mmc, unsigned int clock)
 
 	clk |= SDHCI_CLOCK_CARD_EN;
 	sdhci_writew(host, clk, SDHCI_CLOCK_CONTROL);
+
+	host->clock = clock;
+
 	return 0;
 }
 
-- 
2.7.4




More information about the U-Boot mailing list