diff options
author | Victor Lowther <victor.lowther@gmail.com> | 2008-11-28 16:15:15 -0600 |
---|---|---|
committer | Victor Lowther <victor.lowther@gmail.com> | 2008-11-30 18:21:02 -0600 |
commit | 493224b1beeac0154807bcb1ac8a3007a46c435b (patch) | |
tree | f62b71e81c96e60278a92e46fb4a682ac324ab80 /pm | |
parent | 6eb53f4de576e9a569d9019f3398c23438c2cfa5 (diff) |
90clock takes over a second to run on suspend.
Most systems do not need it. Add NEED_CLOCK_SYNC, and only run hwclock
if it is set. This will probably go away entirely in a later release.
Diffstat (limited to 'pm')
-rw-r--r-- | pm/defaults | 3 | ||||
-rwxr-xr-x | pm/sleep.d/90clock | 2 |
2 files changed, 5 insertions, 0 deletions
diff --git a/pm/defaults b/pm/defaults index c0063c5..db4d59a 100644 --- a/pm/defaults +++ b/pm/defaults @@ -47,3 +47,6 @@ # If you want to ignore commandline parameters, add them here. # DROP_PARAMETERS="" +# If you need to synchronize the system clock across a suspend/resume or +# hibernate/thaw cycle, set this variable. +# NEED_CLOCK_SYNC="true" diff --git a/pm/sleep.d/90clock b/pm/sleep.d/90clock index d824778..5df6e8e 100755 --- a/pm/sleep.d/90clock +++ b/pm/sleep.d/90clock @@ -15,6 +15,8 @@ resume_clock() /sbin/hwclock --hctosys >/dev/null 2>&1 0<&1 } +[ "$NEED_CLOCK_SYNC" ] || exit $NA + case "$1" in hibernate|suspend) suspend_clock ;; thaw|resume) resume_clock ;; |