From: Valdis.Kletnieks@vt.edu
To: Ran Shalit <ranshalit@gmail.com>
Cc: linux-pm@vger.kernel.org,
kernelnewbies <kernelnewbies@kernelnewbies.org>
Subject: Re: suspend/resume PM criterion for application
Date: Wed, 10 Sep 2014 15:25:00 -0400 [thread overview]
Message-ID: <23104.1410377100@turing-police.cc.vt.edu> (raw)
In-Reply-To: Your message of "Wed, 10 Sep 2014 21:58:48 +0300." <CAJ2oMhLnP7TpP3caycqVS0xHRE3tf=+2vREE6H1NradsmFmH4A@mail.gmail.com>
[-- Attachment #1.1: Type: text/plain, Size: 1288 bytes --]
On Wed, 10 Sep 2014 21:58:48 +0300, Ran Shalit said:
> 1. How can I make a process to notice this inactivity ? Do you think
> it can be implemented by some periodic process who check if there is
> activity ? It returns to the original question I raised, that I will
> use some periodic process who checks maybe cpu load or something like
> that. What do you think ?
That's going to depend on your system and what processes are running.
You may have an MP3 player going that doesn't take much CPU at all - but
shutting down because the user hasn't hit a button in 47 minutes will probably
irritate the user no end. Or there may be a screensaver running that takes
twice as much CPU as the MP3 player, but is totally OK on the system
suspending whenever the rest of the system wants it.
You're going to have to look at your system design, and decide for yourself
what the criteria are.
> 2. What Do you mean here by process ? Do you mean SW process which
> register for suspend notification (how do we do this) ? What about
> devices which register for suspend/resume. Must they accept the
> suspend ?
I believe Android already has libraries and monitor processes for this.
It's really hard to give more specific advice without knowing what your
hardware, software, and usage is.
[-- Attachment #1.2: Type: application/pgp-signature, Size: 848 bytes --]
[-- Attachment #2: Type: text/plain, Size: 169 bytes --]
_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
next prev parent reply other threads:[~2014-09-10 19:25 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-10 17:26 suspend/resume PM criterion for application Ran Shalit
2014-09-10 17:59 ` Valdis.Kletnieks
2014-09-10 18:23 ` Ran Shalit
2014-09-10 18:39 ` Valdis.Kletnieks
2014-09-10 18:58 ` Ran Shalit
2014-09-10 19:25 ` Valdis.Kletnieks [this message]
2014-09-10 19:31 ` Ran Shalit
2014-09-11 5:32 ` AYAN KUMAR HALDER
2014-09-11 9:24 ` Ran Shalit
2014-09-14 6:11 ` Ran Shalit
2014-09-17 3:16 ` Peter Teoh
2014-09-17 3:32 ` Peter Teoh
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=23104.1410377100@turing-police.cc.vt.edu \
--to=valdis.kletnieks@vt.edu \
--cc=kernelnewbies@kernelnewbies.org \
--cc=linux-pm@vger.kernel.org \
--cc=ranshalit@gmail.com \
/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