diff options
author | Paul Walmsley <paul@pwsan.com> | 2011-02-25 20:22:08 -0500 |
---|---|---|
committer | Paul Walmsley <paul@pwsan.com> | 2011-03-01 18:39:30 -0500 |
commit | a05dcdb98011a53d150d699ef8243754e2c9a61c (patch) | |
tree | f028211b138d966b293f930c510c7e30a01c0ca1 /drivers/mmc/host/omap_hsmmc.c | |
parent | dd9c1549edef02290edced639f67b54a25abbe0e (diff) |
MMC: omap_hsmmc: enable interface clock before calling mmc_host_enable()
The code path entered via mmc_host_enable() can include register
accesses to the HSMMC IP block. For this to work, both the device
interface clock and functional clock need to be enabled before
mmc_host_enable() is called. However, omap_hsmmc_probe() calls
mmc_host_enable() before enabling the device interface clock.
Fix by calling mmc_host_enable() after the device interface clock is
enabled.
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Madhusudhan Chikkature Rajashekar <madhu.cr@ti.com>
Cc: Adrian Hunter <adrian.hunter@nokia.com>
Cc: Kishore Kadiyala <kishore.kadiyala@ti.com>
Cc: Tero Kristo <Tero.Kristo@nokia.com>
Acked-by: Madhusudhan Chikkature Rajashekar <madhu.cr@ti.com>
Diffstat (limited to 'drivers/mmc/host/omap_hsmmc.c')
-rw-r--r-- | drivers/mmc/host/omap_hsmmc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c index 078fdf11af03..0cf0d89e4183 100644 --- a/drivers/mmc/host/omap_hsmmc.c +++ b/drivers/mmc/host/omap_hsmmc.c | |||
@@ -2101,14 +2101,14 @@ static int __init omap_hsmmc_probe(struct platform_device *pdev) | |||
2101 | /* we start off in DISABLED state */ | 2101 | /* we start off in DISABLED state */ |
2102 | host->dpm_state = DISABLED; | 2102 | host->dpm_state = DISABLED; |
2103 | 2103 | ||
2104 | if (mmc_host_enable(host->mmc) != 0) { | 2104 | if (clk_enable(host->iclk) != 0) { |
2105 | clk_put(host->iclk); | 2105 | clk_put(host->iclk); |
2106 | clk_put(host->fclk); | 2106 | clk_put(host->fclk); |
2107 | goto err1; | 2107 | goto err1; |
2108 | } | 2108 | } |
2109 | 2109 | ||
2110 | if (clk_enable(host->iclk) != 0) { | 2110 | if (mmc_host_enable(host->mmc) != 0) { |
2111 | mmc_host_disable(host->mmc); | 2111 | clk_disable(host->iclk); |
2112 | clk_put(host->iclk); | 2112 | clk_put(host->iclk); |
2113 | clk_put(host->fclk); | 2113 | clk_put(host->fclk); |
2114 | goto err1; | 2114 | goto err1; |