mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rjw@rjwysocki.net>
To: viresh kumar <viresh.kumar@linaro.org>
Cc: linaro-kernel@lists.linaro.org, patches@linaro.org,
	cpufreq@vger.kernel.org, linux-pm@vger.kernel.org,
	linux-kernel@vger.kernel.org, tianyu.lan@intel.com, nm@ti.com,
	jinchoi@broadcom.com, sebastian.capella@linaro.org
Subject: Re: [PATCH] cpufreq: suspend/resume governors with PM notifiers
Date: Sat, 16 Nov 2013 15:29:36 +0100	[thread overview]
Message-ID: <2235672.LLJc6e6dny@vostro.rjw.lan> (raw)
In-Reply-To: <5286F536.70403@linaro.org>

On Saturday, November 16, 2013 10:01:50 AM viresh kumar wrote:
> On Saturday 16 November 2013 05:54 AM, Rafael J. Wysocki wrote:
> > Will cpufreq work during system-wide power transitions (suspend/resume etc.)
> > after this?  In particular, what about hibernation?
> 
> I am disabling governors as soon as we start suspend. So No, cpufreq wouldn't
> work during suspend/resume. But once system is resumed we are starting it back
> again.

Well, disabling it for the whole duration of suspend/resume and/or hibernation
may not be the right approach entirely, unless we force the pax perf of the
boot CPU at least in addition to that.  Otherwise the latency of suspend and
the subsequent resume will depend on what perf level the CPUs where before
disabling the governors, which is not desirable at al.

> Hibernation is probably not supported by my code yet.. I just went through
> hibernation code quickly and it looks we don't send PM_SUSPEND_PREPARE or
> PM_POST_SUSPEND notifications in case of hibernation. Correct?

Yes, that's correct.

> And these are the notifications that we send:
> - PM_HIBERNATION_PREPARE
> - PM_POST_HIBERNATION
> - PM_RESTORE_PREPARE
> - PM_POST_RESTORE
> 
> If I am not wrong I need to stop governors on PM_HIBERNATION_PREPARE and need to
> start them back on: PM_POST_HIBERNATION (I am a bit confused with this one. Does
> this POST_HIBERNATION one happens at the end of going into hibernation? or after
> booting back? I need a notifier at the end of restore)..

You'd need both PM_POST_HIBERNATION and PM_POST_RESTORE, but I wouldn't really
like cpufreq governors to be disabled throughout the whole hibernation.

Actually, we use CPU offline/online during system suspend/resume to avoid
having to do stuff like this from PM notifiers.  So I'd like the original
problem to be addressed in a different way.

Thanks!

PS
The sisk.pl address will start bouncing shortly, so please replace it with
rjw@rjwysocki.net in your address book.

-- 
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.

  reply	other threads:[~2013-11-16 14:17 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-15 10:12 Viresh Kumar
2013-11-15 13:48 ` Nishanth Menon
2013-11-15 15:34   ` Viresh Kumar
2013-11-16  0:24 ` Rafael J. Wysocki
2013-11-16  4:31   ` viresh kumar
2013-11-16 14:29     ` Rafael J. Wysocki [this message]
2013-11-16 15:17       ` Viresh Kumar
2013-11-17  1:08         ` Rafael J. Wysocki
2013-11-17  8:22           ` viresh kumar
2013-11-17 15:09             ` Rafael J. Wysocki
2013-11-17 16:57               ` Viresh Kumar
2013-11-17 21:37                 ` Rafael J. Wysocki
2013-11-18  5:39                   ` viresh kumar
2013-11-18 10:57                     ` Lan Tianyu
2013-11-18 11:01                       ` Viresh Kumar
2013-11-18 13:37                         ` Lan Tianyu
2013-11-18 15:32                           ` Viresh Kumar
2013-11-21 14:39                           ` Rafael J. Wysocki
2013-11-20  5:34                     ` Viresh Kumar
2013-11-21  1:07                       ` Rafael J. Wysocki
2013-11-21 14:38                       ` Rafael J. Wysocki
2013-11-21 16:17                         ` Viresh Kumar
2013-11-21 22:14                           ` Rafael J. Wysocki
2013-11-22  9:11                             ` viresh kumar
2013-11-25  4:25                               ` Viresh Kumar
2013-11-25 11:35                                 ` Rafael J. Wysocki
2013-12-25 22:39           ` Pavel Machek
2013-12-26  0:56             ` Rafael J. Wysocki
2013-11-16  5:56 ` Lan Tianyu

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=2235672.LLJc6e6dny@vostro.rjw.lan \
    --to=rjw@rjwysocki.net \
    --cc=cpufreq@vger.kernel.org \
    --cc=jinchoi@broadcom.com \
    --cc=linaro-kernel@lists.linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=nm@ti.com \
    --cc=patches@linaro.org \
    --cc=sebastian.capella@linaro.org \
    --cc=tianyu.lan@intel.com \
    --cc=viresh.kumar@linaro.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

all inboxes | Powered by JetHome®