On Wed, Jul 13, 2011 at 8:06 PM, Balaji T K <balajitk@xxxxxx> wrote: > Put MMC to sleep if it supports SLEEP/AWAKE (CMD5) > in the mmc suspend to minimize power consumption. > > Signed-off-by: Balaji T K <balajitk@xxxxxx> > --- > drivers/mmc/core/mmc.c | 8 ++++++-- > 1 files changed, 6 insertions(+), 2 deletions(-) > > diff --git a/drivers/mmc/core/mmc.c b/drivers/mmc/core/mmc.c > index afabdc3..e8dfcde 100644 > --- a/drivers/mmc/core/mmc.c > +++ b/drivers/mmc/core/mmc.c > @@ -900,16 +900,20 @@ static void mmc_detect(struct mmc_host *host) > */ > static int mmc_suspend(struct mmc_host *host) > { > + int err = 0; > + > BUG_ON(!host); > BUG_ON(!host->card); > > mmc_claim_host(host); > - if (!mmc_host_is_spi(host)) > + if (mmc_card_can_sleep(host)) > + err = mmc_card_sleep(host); > + else if (!mmc_host_is_spi(host)) > mmc_deselect_cards(host); > host->card->state &= ~MMC_STATE_HIGHSPEED; > mmc_release_host(host); > > - return 0; > + return err; > } > > /* > -- > 1.7.0.4 > Balaji, Would you mind reposting the patch without the RFC and s/CORE/core in subject line ? You can add my Acked-by: Venkatraman S <svenkatr@xxxxxx> -- To unsubscribe from this list: send the line "unsubscribe linux-mmc" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html