Package: hibernate
Version: 1.99-1
Severity: normal

Hello

I am running hibernate from the powerbtn acpid script, and it often
suspends just after resume because there are multiple button presses
queued.

Apparently the 3s time window which hibernate checks in CheckLastResume
is not sufficient.

The multiple events may be generated

 - when acpid is not running for some time and then started (all events
   are processed then)
 - when the hardware malfunctions and sends multiple events on a single
   button press (happens quite often here)
 - when some of the suspend scripts take long to execute and thus the
   button is seemingly not "pressed enough" although the event is
   actually being processed already. Happens sometimes here.

The right solution to this seems to 

1) stop scpid at suspend
2) read all acpi events after that - they are useless anyway, all
heppened before the suspend and have no meaning after the resume
3) (auto)restart acpid after resume

I think the setup could be shipped as comments in the configuration
file.

==> /bin/drain (mode 755) <==
#!/bin/sh

if [ -z "$1" ] ; then
echo Usage: "$0" "<socket>"
exit 2
fi

cat "$1"&
sleep 1

kill $!
==> end of /bin/drain <==


-- Package-specific info:
--- configuration
==> /etc/hibernate/common.conf <==
Verbosity 1
LogFile /var/log/hibernate.log
LogVerbosity 2
Distribution debian
SaveClock restore-only
IncompatibleDevices /dev/sd*
 LockXScreenSaver yes
OnSuspend 99 drain /proc/acpi/event
UnloadModules ehci_hcd
UnloadBlacklistedModules yes
LoadModules auto
RestartServices acpid
SwitchToTextMode yes
==> /etc/hibernate/disk.conf <==
TryMethod ususpend-disk.conf
TryMethod sysfs-disk.conf
==> /etc/hibernate/hibernate.conf <==
UnloadModules ehci-hcd button
Unmount /media/*
TryMethod suspend2.conf
TryMethod disk.conf
TryMethod ram.conf
==> /etc/hibernate/ram.conf <==
TryMethod ususpend-ram.conf
TryMethod sysfs-ram.conf
==> /etc/hibernate/suspend2.conf <==
UseSuspend2 yes
Reboot no
EnableEscape yes
DefaultConsoleLevel 1
Compressor lzf
Encryptor none
FullSpeedCPU yes
Include common.conf
==> /etc/hibernate/sysfs-disk.conf <==
UseSysfsPowerState disk
Include common.conf
==> /etc/hibernate/sysfs-ram.conf <==
UseSysfsPowerState mem
Include common.conf
==> /etc/hibernate/ususpend-both.conf <==
USuspendMethod both
Include common.conf
==> /etc/hibernate/ususpend-disk.conf <==
USuspendMethod disk
Include common.conf
==> /etc/hibernate/ususpend-ram.conf <==
USuspendMethod ram
Include common.conf

--- /sys/power
==> /sys/power/disk <==
[platform] test testproc shutdown reboot 
==> /sys/power/image_size <==
228141629
==> /sys/power/resume <==
254:1
==> /sys/power/state <==
mem disk

--- log
Starting suspend at Wed Dec 10 09:00:39 CET 2008
hibernate: 1 Executing CheckLastResume ...
hibernate: 1 Executing CheckRunlevel ...
hibernate: 1 Executing LockFileGet ...
hibernate: 1 Executing NewKernelFileCheck ...
hibernate: 1 Executing EnsureUSuspendCapable ...
hibernate: 1 Executing XHacksSuspendHook1 ...
hibernate: 1 Executing DevicesFree ...
hibernate: [30] Executing ServicesStop ...
Executing invoke-rc.d acpid stop
 * Stopping ACPI services...
   ...done.
hibernate: [50] Executing FilesystemsUnmount ...
hibernate: [59] Executing RemountXFSBootRO ...
hibernate: [89] Executing SaveKernelModprobe ...
hibernate: [90] Executing ModulesUnload ...
Unloading module ehci-hcd... not loaded.
Unloading module button... 
Unloading module ehci_hcd... 
hibernate: 1 Executing LockXScreensaver ...
Locking hramrach's xscreensaver on display :0 using authority file 
/home/hramrach/.Xauthority
xscreensaver-command: activating and locking.

hibernate: 1 Executing ModulesUnloadBlacklist ...
Unloading blacklisted modules listed /etc/hibernate/blacklisted-modules
hibernate: [95] Executing XHacksSuspendHook2 ...
hibernate: [98] Executing CheckRunlevel ...
hibernate: [99] Executing DoUSuspend ...
hibernate: Running /usr/sbin/s2disk ...
hibernate: [99] Executing MiscLaunchAuxFunc1 ...
Executing drain /proc/acpi/event...
thermal_zone TZ1 00000081 00000000
hibernate: [90] Executing ModulesLoad ...
Loading module button (from auto)...
Loading module ehci_hcd (from auto)...
hibernate: [89] Executing RestoreKernelModprobe ...
hibernate: [85] Executing XHacksResumeHook2 ...
hibernate: [70] Executing ClockRestore ...
hibernate: [59] Executing RemountXFSBootRW ...
hibernate: [30] Executing UnlockXScreensaver ...
Unlocking hramrach's xscreensaver on display :0 using authority file 
/home/hramrach/.Xauthority
xscreensaver-command: deactivating.

hibernate: [30] Executing ServicesStart ...
Executing invoke-rc.d acpid start
 * Starting ACPI services...
   ...done.
hibernate: 1 Executing XHacksResumeHook1 ...
hibernate: 1 Executing NoteLastResume ...
hibernate: 1 Executing LockFilePut ...
Resumed at Wed Dec 10 17:37:09 CET 2008

-- System Information:
Debian Release: lenny/sid
  APT prefers testing
  APT policy: (990, 'testing'), (300, 'unstable'), (100, 'experimental')
Architecture: i386 (i686)

Kernel: Linux 2.6.27-rc5+acpitz-report (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages hibernate depends on:
ii  kbd                           1.14.1-4   Linux console font and keytable ut

Versions of packages hibernate recommends:
pn  dash                          <none>     (no description available)
ii  hdparm                        8.9-2      tune hard disk parameters for high
ii  uswsusp                       0.7-1.2    tools to use userspace software su
ii  vbetool                       1.0-3      run real-mode video BIOS code to a

Versions of packages hibernate suggests:
pn  915resolution                 <none>     (no description available)
ii  vlock                         2.2.2-3    Virtual Console locking program
ii  xscreensaver                  5.05-3     Automatic screensaver for X

-- no debconf information



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to