diff options
author | Rafael J. Wysocki <rjw@sisk.pl> | 2007-10-25 19:01:10 -0400 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2008-02-01 18:30:53 -0500 |
commit | eb57c1cf059630454b40fb8bb124e3f318d241f8 (patch) | |
tree | df8abba4265647f15b3b30053a4d843099bb6b9e /kernel/power/power.h | |
parent | af508b34d27e3341287d89e0eae6752fdb1b873f (diff) |
Hibernation: Rework platform support ioctls (rev. 2)
Modify the hibernation userland interface by adding two new ioctls to it,
SNAPSHOT_PLATFORM_SUPPORT and SNAPSHOT_POWER_OFF, that can be used,
respectively, to switch the hibernation platform support on/off and to make the
kernel transition the system to the hibernation state (eg. ACPI S4) using the
platform (eg. ACPI) driver.
These ioctls are intended to replace the misdesigned SNAPSHOT_PMOPS ioctl,
which from now is regarded as obsolete and will be removed in the future.
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'kernel/power/power.h')
-rw-r--r-- | kernel/power/power.h | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/kernel/power/power.h b/kernel/power/power.h index 23c17031ed21..6ca85fd4975f 100644 --- a/kernel/power/power.h +++ b/kernel/power/power.h | |||
@@ -156,15 +156,12 @@ struct resume_swap_area { | |||
156 | #define SNAPSHOT_FREE_SWAP_PAGES _IO(SNAPSHOT_IOC_MAGIC, 9) | 156 | #define SNAPSHOT_FREE_SWAP_PAGES _IO(SNAPSHOT_IOC_MAGIC, 9) |
157 | #define SNAPSHOT_SET_SWAP_FILE _IOW(SNAPSHOT_IOC_MAGIC, 10, unsigned int) | 157 | #define SNAPSHOT_SET_SWAP_FILE _IOW(SNAPSHOT_IOC_MAGIC, 10, unsigned int) |
158 | #define SNAPSHOT_S2RAM _IO(SNAPSHOT_IOC_MAGIC, 11) | 158 | #define SNAPSHOT_S2RAM _IO(SNAPSHOT_IOC_MAGIC, 11) |
159 | #define SNAPSHOT_PMOPS _IOW(SNAPSHOT_IOC_MAGIC, 12, unsigned int) | ||
160 | #define SNAPSHOT_SET_SWAP_AREA _IOW(SNAPSHOT_IOC_MAGIC, 13, \ | 159 | #define SNAPSHOT_SET_SWAP_AREA _IOW(SNAPSHOT_IOC_MAGIC, 13, \ |
161 | struct resume_swap_area) | 160 | struct resume_swap_area) |
162 | #define SNAPSHOT_GET_IMAGE_SIZE _IOR(SNAPSHOT_IOC_MAGIC, 14, loff_t) | 161 | #define SNAPSHOT_GET_IMAGE_SIZE _IOR(SNAPSHOT_IOC_MAGIC, 14, loff_t) |
163 | #define SNAPSHOT_IOC_MAXNR 14 | 162 | #define SNAPSHOT_PLATFORM_SUPPORT _IO(SNAPSHOT_IOC_MAGIC, 15) |
164 | 163 | #define SNAPSHOT_POWER_OFF _IO(SNAPSHOT_IOC_MAGIC, 16) | |
165 | #define PMOPS_PREPARE 1 | 164 | #define SNAPSHOT_IOC_MAXNR 16 |
166 | #define PMOPS_ENTER 2 | ||
167 | #define PMOPS_FINISH 3 | ||
168 | 165 | ||
169 | /* If unset, the snapshot device cannot be open. */ | 166 | /* If unset, the snapshot device cannot be open. */ |
170 | extern atomic_t snapshot_device_available; | 167 | extern atomic_t snapshot_device_available; |