FS#29333 - [laptop-mode-tools] 'laptop_mode auto' no longer suspends when lid closed
Attached to Project:
Community Packages
Opened by Jamie Kitson (JamieKitson) - Sunday, 08 April 2012, 10:22 GMT
Last edited by Lukas Jirkovsky (6xx) - Monday, 18 June 2012, 10:09 GMT
Opened by Jamie Kitson (JamieKitson) - Sunday, 08 April 2012, 10:22 GMT
Last edited by Lukas Jirkovsky (6xx) - Monday, 18 June 2012, 10:09 GMT
|
Details
Description:
My laptop stopped suspending to RAM when I closed the lid. On investigation I found that the ACPI event and action were still being fired, but 'laptop_mode auto' was no longer causing the machine to suspend. Replacing that line in actions/lm_lid.sh with pm-suspend fixed the issue. Additional info: * package version(s) community/laptop-mode-tools 1.60-2 [installed] * config and/or log files etc. [jamie@jamie-laptop ~]$ cat /etc/acpi/events/lm_lid event=button[ /]lid action=/etc/acpi/actions/lm_lid.sh %e [jamie@jamie-laptop ~]$ cat /etc/acpi/actions/lm_lid.sh #! /bin/sh test -f /usr/sbin/laptop_mode || exit 0 # lid button pressed/released event handler /usr/sbin/laptop_mode auto |
This task depends upon
grep -q open /proc/acpi/button/lid/LID/state && exit 0
Also is it possible that you used some desktop environment before? Eg. KDE handles suspend on lid closed independently on daemons such as pm-utils and laptop-mode-tools.
In the package is the file:
---
[jamie@jamie-laptop laptop-mode-tools_1.60]$ cat etc/acpi/actions/lm_lid.sh
#! /bin/sh
test -f /usr/sbin/laptop_mode || exit 0
# lid button pressed/released event handler
/usr/sbin/laptop_mode auto
---
So my question would be, what does that do? I suppose it is possible that that file (or /etc/acpi/handler.sh from acpid) has been overwritten on my system. I use dwm, so I'm pretty sure there isn't any desktop stuff interfering.
Quick googling on "laptop-mode-tools suspend on lid close" mostly refers to acpid and pm-utils for suspend or to enabling the same power saving settings that are used on battery.
Neither Arch Wiki lists anything related to suspend in the laptop-mode-page apart from the talk mentioning laptop-mode doesn't do that: https://wiki.archlinux.org/index.php/Talk:Laptop_Mode_Tools However acpid page mentions using pm-utils for suspend: https://wiki.archlinux.org/index.php/Acpid#Extending_acpid_with_pm-utils
Finally when I used OpenSuSE on my laptop, suspend on lid closed worked without was handled by pm-utils without actually having laptop-mode-tools installed.
Maybe you can ask on mailing list or forums to get more feedback.
I tried downgrading all power-related tools to the versions before laptop-mode-tools-1.60-2 came out and autosuspend didn't work for me out of the box either. I was able to get it working using the handler.sh from acpid, but that works with the new laptop-mode-tools too.