On 14 April 2015 at 15:12, Adrian Hunter <[email protected]> wrote:
> Currently "mmc sleep" is only used before power off and
> is not paired with waking up. If that ever changed,
> re-tuning might need to be held, so add a comment for that.
>
> Signed-off-by: Adrian Hunter <[email protected]>
> ---
> drivers/mmc/core/mmc.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/mmc/core/mmc.c b/drivers/mmc/core/mmc.c
> index c84131e..53a9cb3 100644
> --- a/drivers/mmc/core/mmc.c
> +++ b/drivers/mmc/core/mmc.c
> @@ -1504,6 +1504,7 @@ static int mmc_can_sleep(struct mmc_card *card)
> return (card && card->ext_csd.rev >= 3);
> }
>
> +/* If necessary, callers must hold re-tuning */
Instead of adding a comment, let's fix what needs to be fixed.
I believe the proper thing would be to disable re-tuning when the card
is about to enter system PM sleep state. So somewhere early in
_mmc_suspend() we should disable re-tune. Likewise for SD and SDIO.
> static int mmc_sleep(struct mmc_host *host)
> {
> struct mmc_command cmd = {0};
> --
> 1.9.1
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html
Kind regards
Uffe
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html