diff options
author | Adrian Hunter <adrian.hunter@intel.com> | 2016-12-02 15:14:21 +0200 |
---|---|---|
committer | Ulf Hansson <ulf.hansson@linaro.org> | 2016-12-05 14:16:21 +0100 |
commit | 5ef5203b95c5090ba40e30ee8eedc5a937fc2898 (patch) | |
tree | 22717bcd921ab686ae87ed03c5d8764dd9854306 /drivers/mmc | |
parent | 61e53bd0047d58caee0c7170613045bf96de4458 (diff) | |
download | linux-5ef5203b95c5090ba40e30ee8eedc5a937fc2898.tar.gz linux-5ef5203b95c5090ba40e30ee8eedc5a937fc2898.tar.bz2 linux-5ef5203b95c5090ba40e30ee8eedc5a937fc2898.zip |
mmc: sdhci: Fix tuning reset after exhausting the maximum number of loops
If the driver has exhausted the maximum number of tuning loops, then fixed
sampling is used. To do that both SDHCI_CTRL_TUNED_CLK and
SDHCI_CTRL_EXEC_TUNING must be reset to 0, but only SDHCI_CTRL_TUNED_CLK
was being reset. Reset SDHCI_CTRL_EXEC_TUNING to 0 also.
Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/mmc')
-rw-r--r-- | drivers/mmc/host/sdhci.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c index 1d72a51287d4..ad2f2c6113e4 100644 --- a/drivers/mmc/host/sdhci.c +++ b/drivers/mmc/host/sdhci.c @@ -2134,6 +2134,7 @@ static int sdhci_execute_tuning(struct mmc_host *mmc, u32 opcode) */ if (tuning_loop_counter < 0) { ctrl &= ~SDHCI_CTRL_TUNED_CLK; + ctrl &= ~SDHCI_CTRL_EXEC_TUNING; sdhci_writew(host, ctrl, SDHCI_HOST_CONTROL2); } if (!(ctrl & SDHCI_CTRL_TUNED_CLK)) { |