Re: Power-managing devices that are not of interest at some point in time

From: Oliver Neukum
Date: Thu Jul 17 2014 - 02:02:08 EST


On Thu, 2014-07-17 at 01:33 +0200, Rafael J. Wysocki wrote:
> On Thursday, July 17, 2014 01:13:42 AM Bastien Nocera wrote:

> > Applications can already check the lid status (through UPower), and with
> > the additional metadata from the kernel, know that the webcam won't be
> > usable when the lid is closed. Switching to external webcam, a webcam on
> > the outside of the case, or switch off the video stream would then be
> > the expected behaviour.
>
> Well, is the scenario I described correct or not? If not, then what
> exactly is the scenario you want to be able to handle?

Well, I think you need to add that you want user space to tell the
kernel that devices should not do remote wakeup under some conditions.
And I think this should not be limited to lid closure. And thus it
does not belong into the kernel.

A good example would be mice. From the kernel side runtime power
management works just fine. In practice it is rarely usable because
remote wakeup doesn't work well enough in common mice. It would
be good enough if the screen saver were working.

So I think lacking is the ability to model that remote wakeup
capabilities are

- dependent on external events
- binary capable or incapable

And we might introduce a system similar to rfkill that tells
devices that they are useless and hence idle due to external factors
(the internal webcam, keyboard, touchscreen ...)
Putting this into user space is difficult because you cannot really
fully close a keyboard.

Regards
Oliver


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/