Re: [PATCH v2] pm_ops: add system quiesce/activate hooks

Johannes Berg
2007-04-13T06:54:54Z

[-- Attachment #1.1: Type: text/plain, Size: 824 bytes --]

On Thu, 2007-04-12 at 21:36 +0400, Dmitry Krivoschekov wrote:

> It'd be nice adding some examples to patch header, and accurate
> explanation what is possible to do at this new level, this would
> sign to other people that they don't have to invent theirs own hacks
> anymore.

That's pretty hard to do generically since it'll most likely differ for
all platforms. I can paste some powermac specific code but that's
unlikely to help anybody.

> For example, I'd like to enter back to suspend mode
> right from "activate" stage, because I've woken up just
> to update some data and I do not want to resume all devices
> for that, is it ok for "activate"?

I'd think that better be done within ->enter itself, no? Like putting a
loop into ->enter:

do {
go to sleep;
while (should sleep);

johannes

[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 190 bytes --]

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]