From: ulf.hansson@linaro.org (Ulf Hansson)
To: linus-amlogic@lists.infradead.org
Subject: [PATCH 1/4] mmc: pwrseq: add op reset to struct mmc_pwrseq_ops
Date: Mon, 20 Mar 2017 18:56:03 +0100 [thread overview]
Message-ID: <CAPDyKFrhfteb8Nx2Tzi__VgmQrsWbvjAVnFmAPTOBtHohLXiUA@mail.gmail.com> (raw)
In-Reply-To: <ac5f62eb-64c6-b66f-24cc-b6ae74a01697@gmail.com>
[...]
>>> @@ -166,6 +166,7 @@ int mmc_wait_for_cmd(struct mmc_host *host, struct mmc_command *cmd,
>>> int retries);
>>>
>>> int mmc_hw_reset(struct mmc_host *host);
>>> +void mmc_hw_reset_pwrseq(struct mmc_host *host);
>>
>> Don't you think we can make this transparent to mmc host drivers,
>> instead of them having to assign their host_ops->hw_reset() callback
>> to this new API? Because I guess that's the though!?
>>
>> In principle the mmc core already have all the information it needs,
>> as to understand when the eMMC pwrseq should be invoked. Or perhaps
>> the code may become a bit too messy for that?
>>
> The easiest way I could think of:
> If host->ops->hw_reset is NULL overwrite it with pwrseq->ops->reset
> in mmc_add_host. But host->ops is defined es being const, so the compiler
> won't allow us to do this. Of course we could do some casting but usually
> I try to avoid hacks like casting away const qualifiers.
No thanks. :-)
[...]
Kind regards
Uffe
next prev parent reply other threads:[~2017-03-20 17:56 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <75ad5eac-412b-fe73-ff53-3d8b975937e4@gmail.com>
2017-02-08 21:48 ` [PATCH 1/4] mmc: pwrseq: add op reset to struct mmc_pwrseq_ops Heiner Kallweit
2017-03-15 10:50 ` Ulf Hansson
2017-03-15 21:42 ` Heiner Kallweit
2017-03-16 6:49 ` Heiner Kallweit
2017-03-20 18:02 ` Ulf Hansson
2017-03-20 17:56 ` Ulf Hansson [this message]
2017-02-08 21:49 ` [PATCH 2/4] mmc: pwrseq: implement reset operation in pwrseq_emmc Heiner Kallweit
2017-02-08 21:49 ` [PATCH 3/4] mmc: meson-gx: add pwrseq-based hw_reset Heiner Kallweit
2017-02-08 21:49 ` [PATCH 4/4] ARM64: dts: meson-gxbb-odroidc2: add hw-reset capability flag for emmc port Heiner Kallweit
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=CAPDyKFrhfteb8Nx2Tzi__VgmQrsWbvjAVnFmAPTOBtHohLXiUA@mail.gmail.com \
--to=ulf.hansson@linaro.org \
--cc=linus-amlogic@lists.infradead.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;
as well as URLs for NNTP newsgroup(s).