Re: [PATCH] swsusp: allow drivers to determine between write-resume and actual wakeup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Po 05-06-06 18:11:31, Tejun Heo wrote:
> Currently, there is no way to tell whether a device is resuming to
> write swsusp image or waking up from actual software suspend.  FREEZE
> and SUSPEND are different operations for some devices (e.g. disks
> don't spin down for FREEZE) and the resume operation for each is also
> different.
> 
> This patch makes swsusp change device power state from PMSG_FREEZE to
> PMSG_SUSPEND on resume from software suspend.  A driver can determine
> whether it's getting thawed or resuming by looking at device power
> state - if FREEZE, it's getting thawed to write image; if SUSPEND,
> resuming from software suspend.  This patch doesn't affect drivers
> which don't update device power state.  Only drivers which set power
> state to FREEZE after freezing are affected.

No, sorry.

If driver is interested if previous operation was FREEZE or
SUSPEND... just store that information locally.

If you want to know if you RESUME was after normal FREEZE or if it is
after reboot, there's better patch floating around to do that.
								Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux