From: Ulf Hansson <ulf.hansson@stericsson.com>
To: Chris Ball <cjb@laptop.org>
Cc: "linux-mmc@vger.kernel.org" <linux-mmc@vger.kernel.org>,
"eliad@wizery.com" <eliad@wizery.com>,
"nico@fluxnic.net" <nico@fluxnic.net>
Subject: Re: [Query] mmc: core "MMC_PM_KEEP_POWER"
Date: Wed, 23 Nov 2011 09:53:44 +0100 [thread overview]
Message-ID: <4ECCB498.4070809@stericsson.com> (raw)
In-Reply-To: <87hb1w2m29.fsf@laptop.org>
Chris Ball wrote:
> Hi Ulf,
>
> On Tue, Nov 22 2011, Ulf Hansson wrote:
>> Thanks for the quick reply! I understand the idea better now. Just a
>> minor follow-up question..
>>
>> The power_restore function for sdio also uses this flag, which is a
>> little bit strange I think.
>
> Yeah, it's being used to detect whether we're in the middle of a powered
> resume, and therefore shouldn't be trying to reinit the card. Then the
> value of MMC_PM_KEEP_POWER gets reset once the resume's finished.
>
>> Especially since the mmc_power_off|up is always called no matter of
>> the value of this flag.
>
> Hm, I don't think that's true.
I were thinking of mmc_power_save|restore_host, those functions is
always doing power_off|on.
>
> mmc_suspend_host() checks !mmc_card_keep_power(host) before mmc_power_off()
> mmc_resume_host() checks !mmc_card_keep_power(host) before mmc_power_up()
>
> static inline int mmc_card_keep_power(struct mmc_host *host)
> {
> return host->pm_flags & MMC_PM_KEEP_POWER;
> }
>
> Thanks,
>
> - Chris.
BR
Uffe
prev parent reply other threads:[~2011-11-23 8:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-22 13:29 [Query] mmc: core "MMC_PM_KEEP_POWER" Ulf Hansson
2011-11-22 13:44 ` Eliad Peller
2011-11-22 13:52 ` Nicolas Pitre
2011-11-22 13:53 ` Chris Ball
2011-11-22 15:33 ` Ulf Hansson
2011-11-22 15:50 ` Chris Ball
2011-11-23 8:53 ` Ulf Hansson [this message]
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=4ECCB498.4070809@stericsson.com \
--to=ulf.hansson@stericsson.com \
--cc=cjb@laptop.org \
--cc=eliad@wizery.com \
--cc=linux-mmc@vger.kernel.org \
--cc=nico@fluxnic.net \
/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