Re: [PATCH V4] mmc: Set suspend/resume bus operations if CONFIG_PM_RUNTIME is used

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> 2012/1/12 Dmitry Shmidt <dimitrysh@xxxxxxxxxx>
>>
>> On Tue, Jan 10, 2012 at 6:44 PM, Barry Song <21cnbao@xxxxxxxxx> wrote:
>> > 2012/1/10 Dmitry Shmidt <dimitrysh@xxxxxxxxxx>:
>> >> Signed-off-by: Dmitry Shmidt <dimitrysh@xxxxxxxxxx>

Acked-by: Barry Song <Baohua.Song@xxxxxxx>

>> >
>> > Hi Dmitry,
>> > after you move mmc_bus_suspend, mmc_bus_resume to dev_pm_ops, while
>> > doing hiberantion by swsusp, suspend/resume will not be called by the
>> > hibernation flow since it will move to call freeze/thaw/restore. if we
>> > don't stop blk queue for SD while doing hibernation, SD card will hang
>> > in the processing of restoring system.
>> >
>> > pls note Bin's patch "mmc: core: move suspend/resume to dev_pm_ops and
>> > add hibernation support"
>> > http://www.spinics.net/lists/linux-mmc/msg12007.html
>> > he has done some duplicated job with you except adding swsusp support.
>> >
>> > -barry
>>
>> Hi Barry,
>>
>> Definitely I didn't cover hibernation support.
>> Bin's patch resolves the problem I tried to address, so I am ok with
>> his version.

sorry. as i checked again, yours actually covered hibernation support
since SET_SYSTEM_SLEEP_PM_OPS is defined as:

#ifdef CONFIG_PM_SLEEP
#define SET_SYSTEM_SLEEP_PM_OPS(suspend_fn, resume_fn) \
        .suspend = suspend_fn, \
        .resume = resume_fn, \
        .freeze = suspend_fn, \
        .thaw = resume_fn, \
        .poweroff = suspend_fn, \
        .restore = resume_fn,
#else
#define SET_SYSTEM_SLEEP_PM_OPS(suspend_fn, resume_fn)
#endif

both s2ram and s2disk entries are set in SET_SYSTEM_SLEEP_PM_OPS.  so
i'd like to ack your patch directly.

>
> i think maybe merging yours and bin's is better. i'd like to send v4
> with your and bin's sob and think you as the author of the patch.
> at least, SET_SYSTEM_SLEEP_PM_OPS and SET_RUNTIME_PM_OPS are better used.
>
>>
>> Thanks,
>>
>> Dmitry
>>
>> >
>> >> ---
>> >>  drivers/mmc/card/block.c |    4 ++--
>> >>  drivers/mmc/core/bus.c   |   25 ++++++++-----------------
>> >>  include/linux/mmc/card.h |    2 +-
>> >>  3 files changed, 11 insertions(+), 20 deletions(-)

-barry
--
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


[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux