public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
From: Haibo Chen <haibo.chen@nxp.com>
To: ulf.hansson@linaro.org, shawn.lin@rock-chips.com
Cc: stable@vger.kernel.org, dianders@chromium.org,
	linux-mmc@vger.kernel.org, haibo.chen@nxp.com
Subject: [PATCH] mmc: mmc: fix switch to 1V8 for hs400es mode
Date: Fri,  7 Jul 2017 17:08:55 +0800	[thread overview]
Message-ID: <1499418535-10161-1-git-send-email-haibo.chen@nxp.com> (raw)

Change the default err value to -EINVAL, otherwise signal voltage
will not change to 1V8 if card or controller only support 1V8 for
HS400ES mode.

Fixes: commit 1720d3545b77 ("mmc: core: switch to 1V8 or 1V2 for hs400es mode")
Cc: <stable@vger.kernel.org>
Signed-off-by: Haibo Chen <haibo.chen@nxp.com>
---
 drivers/mmc/core/mmc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/core/mmc.c b/drivers/mmc/core/mmc.c
index 92c6167..336a950 100644
--- a/drivers/mmc/core/mmc.c
+++ b/drivers/mmc/core/mmc.c
@@ -1289,7 +1289,7 @@ int mmc_hs400_to_hs200(struct mmc_card *card)
 static int mmc_select_hs400es(struct mmc_card *card)
 {
 	struct mmc_host *host = card->host;
-	int err = 0;
+	int err = -EINVAL;
 	u8 val;
 
 	if (!(host->caps & MMC_CAP_8_BIT_DATA)) {
-- 
1.9.1


             reply	other threads:[~2017-07-07  9:02 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-07  9:08 Haibo Chen [this message]
2017-07-11  0:38 ` [PATCH] mmc: mmc: fix switch to 1V8 for hs400es mode Shawn Lin
2017-08-08 10:12   ` 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=1499418535-10161-1-git-send-email-haibo.chen@nxp.com \
    --to=haibo.chen@nxp.com \
    --cc=dianders@chromium.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=shawn.lin@rock-chips.com \
    --cc=stable@vger.kernel.org \
    --cc=ulf.hansson@linaro.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox