From: Viresh Kumar <viresh.kumar@linaro.org>
To: cjb@laptop.org
Cc: spear-devel@list.st.com, linux-mmc@vger.kernel.org,
devicetree-discuss@lists.ozlabs.org, sr@denx.de,
Viresh Kumar <viresh.kumar@linaro.org>
Subject: [PATCH Resend 2/2] mmc: sdhci-spear: Add clk_{un}prepare() support
Date: Fri, 28 Sep 2012 10:48:09 +0530 [thread overview]
Message-ID: <4c4801cf7e901a14f2a98764a9478cd75d5b1010.1348809217.git.viresh.kumar2@arm.com> (raw)
In-Reply-To: <a42729885c593f61bb62c45f229174d9f7370c40.1348809217.git.viresh.kumar2@arm.com>
In-Reply-To: <a42729885c593f61bb62c45f229174d9f7370c40.1348809217.git.viresh.kumar2@arm.com>
clk_{un}prepare is mandatory for platforms using common clock framework. Since
this driver is used by SPEAr platform, which supports common clock framework,
add clk_{un}prepare() support for it.
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
drivers/mmc/host/sdhci-spear.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/mmc/host/sdhci-spear.c b/drivers/mmc/host/sdhci-spear.c
index 1e82d0f..df96663 100644
--- a/drivers/mmc/host/sdhci-spear.c
+++ b/drivers/mmc/host/sdhci-spear.c
@@ -154,7 +154,7 @@ static int __devinit sdhci_probe(struct platform_device *pdev)
goto err;
}
- ret = clk_enable(sdhci->clk);
+ ret = clk_prepare_enable(sdhci->clk);
if (ret) {
dev_dbg(&pdev->dev, "Error enabling clock\n");
goto put_clk;
@@ -274,7 +274,7 @@ set_drvdata:
free_host:
sdhci_free_host(host);
disable_clk:
- clk_disable(sdhci->clk);
+ clk_disable_unprepare(sdhci->clk);
put_clk:
clk_put(sdhci->clk);
err:
@@ -296,7 +296,7 @@ static int __devexit sdhci_remove(struct platform_device *pdev)
sdhci_remove_host(host, dead);
sdhci_free_host(host);
- clk_disable(sdhci->clk);
+ clk_disable_unprepare(sdhci->clk);
clk_put(sdhci->clk);
return 0;
@@ -311,7 +311,7 @@ static int sdhci_suspend(struct device *dev)
ret = sdhci_suspend_host(host);
if (!ret)
- clk_disable(sdhci->clk);
+ clk_disable_unprepare(sdhci->clk);
return ret;
}
@@ -322,7 +322,7 @@ static int sdhci_resume(struct device *dev)
struct spear_sdhci *sdhci = dev_get_platdata(dev);
int ret;
- ret = clk_enable(sdhci->clk);
+ ret = clk_prepare_enable(sdhci->clk);
if (ret) {
dev_dbg(dev, "Resume: Error enabling clock\n");
return ret;
--
1.7.12.rc2.18.g61b472e
next prev parent reply other threads:[~2012-09-28 5:18 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-28 5:18 [PATCH Resend 1/2] mmc: sdhci-spear: add device tree bindings Viresh Kumar
2012-09-28 5:18 ` Viresh Kumar [this message]
2012-09-28 9:03 ` Chris Ball
2012-09-28 9:49 ` viresh kumar
2012-09-28 10:13 ` Chris Ball
2012-09-28 10:18 ` viresh kumar
2012-09-28 9:59 ` viresh kumar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4c4801cf7e901a14f2a98764a9478cd75d5b1010.1348809217.git.viresh.kumar2@arm.com \
--to=viresh.kumar@linaro.org \
--cc=cjb@laptop.org \
--cc=devicetree-discuss@lists.ozlabs.org \
--cc=linux-mmc@vger.kernel.org \
--cc=spear-devel@list.st.com \
--cc=sr@denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).