summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pm/defaults33
-rw-r--r--pm/pm-functions.in12
2 files changed, 37 insertions, 8 deletions
diff --git a/pm/defaults b/pm/defaults
index d5b6447..5e4def1 100644
--- a/pm/defaults
+++ b/pm/defaults
@@ -1,9 +1,34 @@
-
##########################################################
-# DO NOT EDIT THIS FILE, edit /etc/pm/config.d/ instead! #
+# DO NOT EDIT THIS FILE! #
+# #
+# Add files in /etc/pm/config.d/ instead! #
##########################################################
-HIBERNATE_RESUME_POST_VIDEO="no"
+# Default method to power down the system when hibernating.
+# If commented out, the system will use "shutdown" as a
+# default value.
+#
+# Check /sys/power/disk for valid values.
+# HIBERNATE_MODE="platform"
+
+# Whetner we need to post the video card when resuming from
+# hibernate. You should not normally need to set this.
+# In the future pm-utils will get this setting from HAL.
+#
+# Valid values are "no" and "yes"
+# HIBERNATE_RESUME_POST_VIDEO="no"
+
+# The default sleep/wake system to use. Valid values are:
+# kernel The built-in kernel suspend/resume support.
+# Use this if nothing else is supported on your system.
+# uswsusp If your system has support for the userspace
+# suspend programs (s2ram/s2disk/s2both), then use this.
+# tuxonice If your system has support for tuxonice, use this.
+#
+# The system defaults to "kernel" if this is commented out.
+# SLEEP_MODULE="kernel"
-SUSPEND_MODULES=""
+# If you need to unload any modules to suspend/resume, add them
+# here.
+# SUSPEND_MODULES=""
diff --git a/pm/pm-functions.in b/pm/pm-functions.in
index ea57c76..5068781 100644
--- a/pm/pm-functions.in
+++ b/pm/pm-functions.in
@@ -20,15 +20,11 @@ PM_UTILS_RUNDIR="/var/run/pm-utils"
PM_CMDLINE="$*"
PATH=/sbin:/usr/sbin:/bin:/usr/bin:"${PM_UTILS_LIBDIR}"/bin
-HIBERNATE_MODE="platform"
-HIBERNATE_RESUME_POST_VIDEO=no
INHIBIT="${PM_UTILS_RUNDIR}/inhibit"
PM_LOGFILE="${PM_LOGFILE:=/var/log/pm-suspend.log}"
-SUSPEND_MODULES=""
TEMPORARY_CPUFREQ_GOVERNOR="performance"
LOCKDIR="${PM_UTILS_RUNDIR}/locks"
STORAGEDIR="${PM_UTILS_RUNDIR}/storage"
-SLEEP_MODULE="kernel"
NA=254
NX=253
DX=252
@@ -36,6 +32,14 @@ PM_FUNCTIONS="$PM_UTILS_LIBDIR/functions"
# Use c sort order
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_RESUME_POST_VIDEO="no"
+SLEEP_MODULE="kernel"
+SUSPEND_MODULES=""
+
[ -f "${PM_UTILS_LIBDIR}"/defaults ] && . "${PM_UTILS_LIBDIR}"/defaults
set +a