MLK-22851-1 mmc: fsl_esdhc: reduce unnecessary clock change
authorYe Li <ye.li@nxp.com>
Thu, 24 Oct 2019 02:27:48 +0000 (19:27 -0700)
committerYe Li <ye.li@nxp.com>
Mon, 28 Oct 2019 08:14:24 +0000 (01:14 -0700)
commit18d62cf12e4c736d1a7cf2c9e7404ba0cac270fa
treec93cca43c238a15cd2fdfc9d1df9f10ce0d8d6bd
parent4daafb3509b1143e96b6f66cfb12e71396b900bc
MLK-22851-1 mmc: fsl_esdhc: reduce unnecessary clock change

In mmc initial state, the mmc framework sets clock to 0, so the fsl_esdhc
driver converts to use min clock 400Khz. But the priv->clock is logged
400Khz not 0, and cause following calls to set_ios to set clock again.

Each set to clock has 10ms delay for stable, then the problem accumulates
some unnecessary delay.

Signed-off-by: Ye Li <ye.li@nxp.com>
(cherry picked from commit 151ab3bef2b1ec1c142c31048f3005ebce2a7a18)
drivers/mmc/fsl_esdhc.c