From: Sreedhar Sambangi <ssambang@codeaurora.org>
To: andy.gross@linaro.org, linux-mmc@vger.kernel.org,
linux-arm-msm@vger.kernel.org
Cc: qca-upstream.external@qca.qualcomm.com, ivan.ivanov@linaro.org,
sboyd@codeaurora.org, georgi.djakov@linaro.org,
linux-kernel@vger.kernel.org
Subject: [PATCH] qcom: sdhci-msm: enable the DLL clock
Date: Tue, 5 Apr 2016 00:46:43 -0700 [thread overview]
Message-ID: <1459842403-4052-1-git-send-email-ssambang@codeaurora.org> (raw)
The DLL clock has to be enabled until the correct
clock frequency is delivered to DLL
'1'(default) - DLL clock is disabled
'0' - dll clock has legacly clock enable.
Signed-off-by: Varadarajan Narayanan <varada@codeaurora.org>
Signed-off-by: Sreedhar Sambangi <ssambang@codeaurora.org>
---
drivers/mmc/host/sdhci-msm.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c
index 4695bee..95b8b70 100644
--- a/drivers/mmc/host/sdhci-msm.c
+++ b/drivers/mmc/host/sdhci-msm.c
@@ -43,6 +43,9 @@
#define CORE_DLL_CONFIG 0x100
#define CORE_DLL_STATUS 0x108
+#define CORE_DLL_CONFIG2 0x1b4
+#define CORE_DLL_CLK_DISABLE BIT(21)
+
#define CORE_VENDOR_SPEC 0x10c
#define CORE_CLK_PWRSAVE BIT(1)
@@ -326,6 +329,10 @@ static int msm_init_cm_dll(struct sdhci_host *host)
writel_relaxed((readl_relaxed(host->ioaddr + CORE_DLL_CONFIG)
| CORE_CK_OUT_EN), host->ioaddr + CORE_DLL_CONFIG);
+ /* Write 0 to DLL_CLOCK_DISABLE bit of DLL_CONFIG_2 register */
+ writel_relaxed((readl_relaxed(host->ioaddr + CORE_DLL_CONFIG2)
+ & ~CORE_DLL_CLK_DISABLE), host->ioaddr + CORE_DLL_CONFIG2);
+
/* Wait until DLL_LOCK bit of DLL_STATUS register becomes '1' */
while (!(readl_relaxed(host->ioaddr + CORE_DLL_STATUS) &
CORE_DLL_LOCK)) {
--
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project
next reply other threads:[~2016-04-05 7:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-05 7:46 Sreedhar Sambangi [this message]
2016-04-11 13:33 ` [PATCH] qcom: sdhci-msm: enable the DLL clock Ulf Hansson
2016-04-11 22:11 ` Stephen Boyd
2016-04-13 11:40 ` Ulf Hansson
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=1459842403-4052-1-git-send-email-ssambang@codeaurora.org \
--to=ssambang@codeaurora.org \
--cc=andy.gross@linaro.org \
--cc=georgi.djakov@linaro.org \
--cc=ivan.ivanov@linaro.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mmc@vger.kernel.org \
--cc=qca-upstream.external@qca.qualcomm.com \
--cc=sboyd@codeaurora.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.