summaryrefslogtreecommitdiffstats
path: root/drivers/mmc/host/sdhci-pxav3.c
diff options
context:
space:
mode:
authorLars-Peter Clausen2013-01-28 19:27:12 +0100
committerChris Ball2013-02-24 20:37:09 +0100
commitd005d94359a8df84ea6e5ac137393707f9e87e81 (patch)
tree1cf5e1c0c6fc304e387705d00d72a82c50f82b10 /drivers/mmc/host/sdhci-pxav3.c
parentmmc: sdhci: update signal voltage switch code (diff)
downloadkernel-qcow2-linux-d005d94359a8df84ea6e5ac137393707f9e87e81.tar.gz
kernel-qcow2-linux-d005d94359a8df84ea6e5ac137393707f9e87e81.tar.xz
kernel-qcow2-linux-d005d94359a8df84ea6e5ac137393707f9e87e81.zip
mmc: sdhci-pltfm: Add a common clk API implementation of get_timeout_clock
Quite a few drivers have a implementation of the get_timeout_clock callback which simply returns the result of clk_get_rate on the device's clock. This patch adds a common implementation of this to the sdhci-pltfm module and replaces all custom implementations with the common one. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Tested-by: Stephen Warren <swarren@wwwdotorg.org> Acked-by: Shawn Guo <shawn.guo@linaro.org> Tested-by: Kevin Liu <kliu5@marvell.com> Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers/mmc/host/sdhci-pxav3.c')
-rw-r--r--drivers/mmc/host/sdhci-pxav3.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/mmc/host/sdhci-pxav3.c b/drivers/mmc/host/sdhci-pxav3.c
index 3d20c10fc571..f09877fcc3ec 100644
--- a/drivers/mmc/host/sdhci-pxav3.c
+++ b/drivers/mmc/host/sdhci-pxav3.c
@@ -163,18 +163,11 @@ static int pxav3_set_uhs_signaling(struct sdhci_host *host, unsigned int uhs)
return 0;
}
-static u32 pxav3_get_max_clock(struct sdhci_host *host)
-{
- struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host);
-
- return clk_get_rate(pltfm_host->clk);
-}
-
static struct sdhci_ops pxav3_sdhci_ops = {
.platform_reset_exit = pxav3_set_private_registers,
.set_uhs_signaling = pxav3_set_uhs_signaling,
.platform_send_init_74_clocks = pxav3_gen_init_74_clocks,
- .get_max_clock = pxav3_get_max_clock,
+ .get_max_clock = sdhci_pltfm_clk_get_max_clock,
};
#ifdef CONFIG_OF