From: Zhoujie Wu <zjwu@marvell.com>
To: Shawn Lin <shawn.lin@rock-chips.com>
Cc: linux-mmc@vger.kernel.org, ulf.hansson@linaro.org,
adrian.hunter@intel.com, zmxu@marvell.com, jszhang@marvell.com,
nadavh@marvell.com, xigu@marvell.com, dingwei@marvell.com,
kostap@marvell.com, hannah@marvell.com, hongd@marvell.com,
dougj@marvell.com, ygao@marvell.com, liuw@marvell.com,
gregory.clement@free-electrons.com,
thomas.petazzoni@free-electrons.com
Subject: Re: [EXT] Re: [PATCH] mmc: sdhci-xenon: add gpio hard reset support
Date: Wed, 16 Aug 2017 15:46:53 -0700 [thread overview]
Message-ID: <5994CB5D.5080509@marvell.com> (raw)
In-Reply-To: <b56fc3b4-4fff-0881-2233-8f26a6c8407a@rock-chips.com>
Hi ,
On 08/15/2017 05:32 PM, Shawn Lin wrote:
> Hi
>
> On 2017/8/16 6:40, Zhoujie Wu wrote:
>> Hi Shawn,
>
>>> ----------------------------------------------------------------------
>>> Hi
>>>
>>> On 2017/8/15 6:19, Zhoujie Wu wrote:
>>>> On some platforms, like armada3700, SD card need to
>>>> do hard reset by gpio toggling to make it work properly
>>>> after warm reset the board.
>>>
>>> I don't get this that SD card need to do hard reset...
>>>
>>> I assume what you talk about is either for eMMC or a power-cycle
>>> for SD card.
>>
>> The subject of the patch confused you. What I want is a power-cycle
>> for the SD card. The gpio is used to enable/disable the vdd power
>> supply for sd card.
>> Actually on a3700, when warm reset the board, their is no power-cycle
>> for SD card, which will lead sd card can't response correct ocr and
>> never set S18A unless a power-cycle.
>> This is the purpose I submit this patch.
>>
>
> Well, if that is the case, I suggest you to use regulator-gpio.
>
> i.e:
>
> vcc_sd: regulator {
> compatible = "regulator-gpio";
> regulator-name = "vcc_sd";
> regulator-min-microvolt = <3300000>;
> regulator-max-microvolt = <3300000>;
>
> gpios = <&gpio1 23 GPIO_ACTIVE_HIGH>;
> enable-active-high;
> };
>
> &sdhci {
> vmmc-supply = <&vcc_sd>;
> }
>
>
I tried to use the vmmc-supply regulator before I submit this patch, I
met a issue in this case.
sdhci_set_power_reg will be called instead, and I saw
mmc_regulator_set_ocr do enabled the regulator, after that SW will set
0xf to power controller register, but the register is self-cleared to 0
soon which lead to later cmd timeout all the time.
Have you ever met similar issue before?
>>>
>>>> Add gpio hard reset feature for this purpose.
>>>>
>
>>
>>
>>
>>
>
next prev parent reply other threads:[~2017-08-16 22:47 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-14 22:19 [PATCH] mmc: sdhci-xenon: add gpio hard reset support Zhoujie Wu
2017-08-15 2:11 ` Shawn Lin
2017-08-15 22:40 ` [EXT] " Zhoujie Wu
2017-08-15 23:27 ` Zhoujie Wu
2017-08-16 0:32 ` Shawn Lin
2017-08-16 2:44 ` Jisheng Zhang
2017-08-16 22:46 ` Zhoujie Wu [this message]
2017-08-17 0:47 ` Shawn Lin
2017-08-17 18:34 ` Zhoujie Wu
2017-08-15 2:56 ` Jisheng Zhang
2017-08-15 22:43 ` Zhoujie Wu
2017-08-16 2:22 ` Jisheng Zhang
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=5994CB5D.5080509@marvell.com \
--to=zjwu@marvell.com \
--cc=adrian.hunter@intel.com \
--cc=dingwei@marvell.com \
--cc=dougj@marvell.com \
--cc=gregory.clement@free-electrons.com \
--cc=hannah@marvell.com \
--cc=hongd@marvell.com \
--cc=jszhang@marvell.com \
--cc=kostap@marvell.com \
--cc=linux-mmc@vger.kernel.org \
--cc=liuw@marvell.com \
--cc=nadavh@marvell.com \
--cc=shawn.lin@rock-chips.com \
--cc=thomas.petazzoni@free-electrons.com \
--cc=ulf.hansson@linaro.org \
--cc=xigu@marvell.com \
--cc=ygao@marvell.com \
--cc=zmxu@marvell.com \
/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.