diff options
author | Todd Poynor <toddpoynor@google.com> | 2011-12-27 08:48:46 -0500 |
---|---|---|
committer | Chris Ball <cjb@laptop.org> | 2012-01-11 23:58:47 -0500 |
commit | 30832ab56c80d96cfaf5a786524f0d8c57fadfa1 (patch) | |
tree | 4afa0434624ca794611d61d17892770f9e41644e /drivers/mmc/host/sdhci.c | |
parent | e2a0a5829c4069ee4a0f28c7301187ffaba91a46 (diff) |
mmc: sdhci: Always pass clock request value zero to set_clock host op
To allow the set_clock host op to disable the SDCLK source when not
needed, always call the host op when the requested clock speed is
zero. Do this even if host->clock already equals zero, because
the SDHCI driver may set that value (without calling the host op)
to force an update at the next (non-zero-speed) call.
Signed-off-by: Todd Poynor <toddpoynor@google.com>
Acked-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers/mmc/host/sdhci.c')
-rw-r--r-- | drivers/mmc/host/sdhci.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c index 6f1fd02fe01b..e06299734f5d 100644 --- a/drivers/mmc/host/sdhci.c +++ b/drivers/mmc/host/sdhci.c | |||
@@ -1068,7 +1068,7 @@ static void sdhci_set_clock(struct sdhci_host *host, unsigned int clock) | |||
1068 | u16 clk = 0; | 1068 | u16 clk = 0; |
1069 | unsigned long timeout; | 1069 | unsigned long timeout; |
1070 | 1070 | ||
1071 | if (clock == host->clock) | 1071 | if (clock && clock == host->clock) |
1072 | return; | 1072 | return; |
1073 | 1073 | ||
1074 | host->mmc->actual_clock = 0; | 1074 | host->mmc->actual_clock = 0; |