diff options
author | Victor Lowther <victor.lowther@gmail.com> | 2008-03-20 12:48:19 -0500 |
---|---|---|
committer | Victor Lowther <victor.lowther@gmail.com> | 2008-03-20 12:48:19 -0500 |
commit | f75ffa2e8c5391b50177375f0b46653dbd38cc7f (patch) | |
tree | 0611b18527fc445355d8d4e541605a96a2f72d4d | |
parent | 868a6fabf6b254c53b12309fa9719eb5120e6d3f (diff) |
Changed kernel hibernation to use the default kernel method unless overridden.
Hopefully this will get rid of the bug reports where "platform" causes
problems. If it does not, we should probably default to "shutdown" as the
default method.
-rw-r--r-- | pm/defaults | 7 | ||||
-rwxr-xr-x | pm/module.d/kernel | 3 | ||||
-rw-r--r-- | pm/pm-functions.in | 2 |
3 files changed, 7 insertions, 5 deletions
diff --git a/pm/defaults b/pm/defaults index 19d38ec..449d34a 100644 --- a/pm/defaults +++ b/pm/defaults @@ -5,11 +5,12 @@ ########################################################## # Default method to power down the system when hibernating. -# If commented out, the system will use "shutdown" as a +# If commented out, the system will use the kernel default as a # default value. # -# Check /sys/power/disk for valid values. -# HIBERNATE_MODE="platform" +# Check /sys/power/disk for valid values. The default value +# will be surrounded by [square brackets]. +# HIBERNATE_MODE="shutdown" # Whetner we need to post the video card when resuming from # hibernate. You should not normally need to set this. diff --git a/pm/module.d/kernel b/pm/module.d/kernel index 9a6b5ad..7e40cd5 100755 --- a/pm/module.d/kernel +++ b/pm/module.d/kernel @@ -22,7 +22,8 @@ check_hibernate() do_hibernate() { - echo -n "${HIBERNATE_MODE}" > /sys/power/disk + [ "$HIBERNATE_MODE ] && \ + echo -n "${HIBERNATE_MODE}" > /sys/power/disk echo -n "disk" > /sys/power/state } diff --git a/pm/pm-functions.in b/pm/pm-functions.in index aebbd0c..a3050da 100644 --- a/pm/pm-functions.in +++ b/pm/pm-functions.in @@ -35,7 +35,7 @@ LC_COLLATE=C # These should be overridden by defaults and/or config.d settings. # Specifically, distros should override these by modifying defaults, # and end users should modify these using files in /etc/pm/config. -HIBERNATE_MODE="shutdown" +HIBERNATE_MODE="" HIBERNATE_RESUME_POST_VIDEO="no" SLEEP_MODULE="kernel" # These variables will be handled specially when we load the config file. |