Re: Wakeup-events implementation

Mark Brown
2010-08-18T10:32:19Z

On Tue, Aug 17, 2010 at 05:40:37PM -0700, Arve Hj?nnev?g wrote:
> 2010/8/17 Rafael J. Wysocki <rjw@sisk.pl>:

> >> On the other hand, a driver generally doesn't
> >> know until a suspend starts whether or not its devices should be
> >> enabled for wakeup.

> Why? How is the driver notified on suspend that it needs to be enabled
> for wakeup.

There's the wakeup API in pm_wakeup.h, plus subsystem specific knowledge
about what sensible defaults for the hardware in much the same way as we
handle what to do when we suspend.

> >> In addition, you retain all these debugging facilities in your
> >> production builds, not just in the debug kernels. ?Doesn't this seem
> >> excessive?

> > It definitely seems so.

> There are two reasons for keeping the debugging facilities in production builds.
> 1. The debugging information is useful for debugging problems in the field.
> 2. We want to test with the same code we ship.

Plus the fact that power usage tends to be very dynamic often with
strong dependencies on usage patterns. Power usage is something that
end users will want to debug as well as developers, though most likely
not in the same detail.