From: Oliver Neukum <oneukum@suse.de>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>,
Irina Tirdea <irina.tirdea@intel.com>,
Len Brown <len.brown@intel.com>,
Octavian Purdila <octavian.purdila@intel.com>,
"Rafael J. Wysocki" <rafael@kernel.org>,
Ulf Hansson <ulf.hansson@linaro.org>,
"Rafael J. Wysocki" <rjw@rjwysocki.net>,
Pavel Machek <pavel@ucw.cz>,
"linux-input@vger.kernel.org" <linux-input@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>
Subject: Re: [RFC PATCH] PM / Runtime: runtime: Add sysfs option for forcing runtime suspend
Date: Wed, 23 Sep 2015 05:03:14 +0200 [thread overview]
Message-ID: <1442977394.8607.8.camel@suse.de> (raw)
In-Reply-To: <Pine.LNX.4.44L0.1509221116430.1742-100000@iolanthe.rowland.org>
On Tue, 2015-09-22 at 11:22 -0400, Alan Stern wrote:
> On Tue, 22 Sep 2015, Oliver Neukum wrote:
>
> > Cancel, yes, going to low power is a consequence which needn't bother
> > the power subsystem.
>
> Going to low power needn't involve the power subsystem? That sounds
> weird.
Think of it like rfkill. It makes sense to suspend an rfkilled device.
It still is the job of the driver to report that its device is idle.
> > You need a callback. If there are spurious
> > events, the current heuristics will keep devices awake.
> > You must discard them anyway, as they are spurious. There's no point
> > in transporting over the bus at all. We can cease IO for input.
> >
> > > This would create a parallel runtime-PM mechanism which is independent
> > > of the existing one. Is that really a good idea?
> >
> > It isn't strictly PM. It helps PM to do a better job, but
> > conceptually it is independent.
>
> So my next question is: _How_ can this help PM to do a better job?
> That is, what are the mechanisms?
"inhibit" -> driver stops input -> driver sets PM count to zero
-> PM subsystem acts
To go from the first to the second step a callback is needed
> One you have already stated: Lack of spurious events will help prevent
> unwanted wakeups (or unwanted failures to go to sleep).
That too. We also save CPU cycles.
> But Dmitry made a stronger claim: Inhibiting an input device should
> allow the device to go to low power. I would like to know how we can
> implement this cleanly. The most straightforward approach is to use
> runtime PM, but it's not obvious how this can be made to work with the
> current API.
Yes, we can use the current API.
The key is that you think of the mechanism as induced idleness,
not forced suspend. We already have a perfectly working mechanism
for suspending idle devices.
Regards
Oliver
next prev parent reply other threads:[~2015-09-23 3:03 UTC|newest]
Thread overview: 58+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-07 20:42 [RFC PATCH] PM / Runtime: runtime: Add sysfs option for forcing runtime suspend Irina Tirdea
2015-09-07 21:20 ` Rafael J. Wysocki
2015-09-08 1:10 ` Tirdea, Irina
2015-09-08 1:10 ` Tirdea, Irina
2015-09-08 7:35 ` Oliver Neukum
2015-09-08 20:56 ` Rafael J. Wysocki
2015-09-08 22:25 ` Ulf Hansson
2015-09-08 23:50 ` Rafael J. Wysocki
2015-09-09 11:13 ` Octavian Purdila
2015-09-09 12:22 ` Rafael J. Wysocki
2015-09-09 13:55 ` Oliver Neukum
2015-09-09 15:02 ` Octavian Purdila
2015-09-09 20:25 ` Rafael J. Wysocki
2015-09-10 9:38 ` Oliver Neukum
2015-09-21 12:29 ` Pavel Machek
2015-09-09 15:20 ` Alan Stern
2015-09-09 20:35 ` Rafael J. Wysocki
2015-09-09 20:16 ` Colin Cross
2015-09-21 12:30 ` Pavel Machek
2015-09-21 14:38 ` Alan Stern
2015-09-21 16:16 ` Dmitry Torokhov
2015-09-21 16:34 ` Alan Stern
2015-09-21 16:59 ` Dmitry Torokhov
2015-09-21 17:32 ` Alan Stern
2015-09-21 18:00 ` Dmitry Torokhov
2015-09-21 20:02 ` Alan Stern
2015-09-21 20:56 ` Dmitry Torokhov
2015-09-22 12:05 ` Oliver Neukum
2015-09-22 14:15 ` Alan Stern
2015-09-22 14:31 ` Oliver Neukum
2015-09-22 15:22 ` Alan Stern
2015-09-23 3:03 ` Oliver Neukum [this message]
2015-09-23 7:27 ` Octavian Purdila
2015-09-23 14:55 ` Alan Stern
2015-09-25 0:43 ` Rafael J. Wysocki
2015-09-25 14:29 ` Alan Stern
2015-09-25 20:15 ` Rafael J. Wysocki
2015-09-25 21:13 ` Alan Stern
2015-09-25 21:52 ` Rafael J. Wysocki
2015-09-25 23:04 ` Rafael J. Wysocki
2015-09-26 15:20 ` Alan Stern
2015-09-27 13:41 ` Rafael J. Wysocki
2015-09-27 14:27 ` Alan Stern
2015-09-28 13:41 ` Rafael J. Wysocki
2015-09-28 14:29 ` Alan Stern
2015-09-28 20:03 ` Rafael J. Wysocki
2015-09-28 20:23 ` Alan Stern
2015-10-04 15:16 ` Pavel Machek
2015-09-27 17:02 ` Pavel Machek
2015-09-28 13:47 ` Rafael J. Wysocki
2015-09-21 20:20 ` Pavel Machek
2015-09-08 14:44 ` Alan Stern
2015-09-08 15:15 ` Rafael J. Wysocki
2015-09-08 15:00 ` Alan Stern
2015-09-08 20:28 ` Rafael J. Wysocki
2015-09-09 15:22 ` Alan Stern
2015-09-09 6:26 ` Oliver Neukum
2015-09-09 14:33 ` Alan Stern
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=1442977394.8607.8.camel@suse.de \
--to=oneukum@suse.de \
--cc=dmitry.torokhov@gmail.com \
--cc=irina.tirdea@intel.com \
--cc=len.brown@intel.com \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=octavian.purdila@intel.com \
--cc=pavel@ucw.cz \
--cc=rafael@kernel.org \
--cc=rjw@rjwysocki.net \
--cc=stern@rowland.harvard.edu \
--cc=ulf.hansson@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.