linux-mmc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dong Aisheng <b29396@freescale.com>
To: linux-mmc@vger.kernel.org
Cc: linux-arm-kernel@lists.infradead.org, cjb@laptop.org,
	shawn.guo@linaro.org, s.hauer@pengutronix.de,
	b29396@freescale.com, wsa@the-dreams.de
Subject: [PATCH 4/5] mmc: sdhci-esdhc-imx: fix runtime pm unblance issue
Date: Wed, 30 Oct 2013 22:12:17 +0800	[thread overview]
Message-ID: <1383142338-25062-5-git-send-email-b29396@freescale.com> (raw)
In-Reply-To: <1383142338-25062-1-git-send-email-b29396@freescale.com>

Since we're using common esdhc_send_command for tuning commands and
the core code will call pm_runtime_put after command is finished.
So we add a pm_runtime_get_sync here to get the blance.

Signed-off-by: Dong Aisheng <b29396@freescale.com>
---
 drivers/mmc/host/sdhci-esdhc-imx.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c
index 0bd99eb..da8026b 100644
--- a/drivers/mmc/host/sdhci-esdhc-imx.c
+++ b/drivers/mmc/host/sdhci-esdhc-imx.c
@@ -698,6 +698,7 @@ static void esdhc_prepare_tuning(struct sdhci_host *host, u32 val)
 	/* FIXME: delay a bit for card to be ready for next tuning due to errors */
 	mdelay(1);
 
+	pm_runtime_get_sync(host->mmc->parent);
 	reg = readl(host->ioaddr + ESDHC_MIX_CTRL);
 	reg |= ESDHC_MIX_CTRL_EXE_TUNE | ESDHC_MIX_CTRL_SMPCLK_SEL |
 			ESDHC_MIX_CTRL_FBCLK_SEL;
-- 
1.7.2.rc3



  parent reply	other threads:[~2013-10-30 14:31 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-30 14:12 [PATCH 0/5] mmc: sdhci-esdhc-imx: add runtime pm support Dong Aisheng
2013-10-30 14:12 ` [PATCH 1/5] mmc: sdhci-pltfm: export pltfm suspend/resume api Dong Aisheng
2013-10-30 14:12 ` [PATCH 2/5] mmc: sdhci-esdhc-imx: tuning bits should not be cleared during reset Dong Aisheng
2013-10-30 14:12 ` [PATCH 3/5] mmc: sdhci-esdhc-imx: clear SDHCI_CTRL_EXEC_TUNING should not affect other bits Dong Aisheng
2013-10-30 14:12 ` Dong Aisheng [this message]
2013-10-30 14:12 ` [PATCH 5/5] mmc: sdhci-esdhc-imx: add runtime pm support Dong Aisheng
2013-10-30 22:49   ` Ulf Hansson
2013-11-01 12:31     ` Dong Aisheng

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=1383142338-25062-5-git-send-email-b29396@freescale.com \
    --to=b29396@freescale.com \
    --cc=cjb@laptop.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=s.hauer@pengutronix.de \
    --cc=shawn.guo@linaro.org \
    --cc=wsa@the-dreams.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).