Hello Jasmine,

On Wednesday 17 October 2012 12:39 PM, Jasmine Hassan wrote:
> Package: laptop-mode-tools
> Version: 1.61-1
>
> # grep ENABLE_LAPTOP_MODE_TOOLS /etc/laptop-mode/laptop-mode.conf
> ENABLE_LAPTOP_MODE_TOOLS=0
>
> # ls -l /var/run/laptop-mode-tools/enabled
> ls: cannot access /var/run/laptop-mode-tools/enabled: No such file or 
> directory
>
> # /etc/init.d/laptop-mode start
> [ ok ] Enabling laptop mode...done (Warning: Configuration file
> /etc/laptop-mode/conf.d/board-specific/*.conf is not readable,
> skipping.
> laptop-mode-tools is disabled in config file. Exiting).
>
> # ls -l /var/run/laptop-mode-tools/enabled
> -rw-r--r-- 1 root root 0 Sep 21 17:12 /var/run/laptop-mode-tools/enabled

Yes. This should be handled better. Currently the "enabled" file is
touched in the init script. So even if LMT exited, the file doesn't get
cleaned.

Thanks for reporting this.


TODO: Investigate how to capture state, especially given that now we
have multiple invocation sources, pm-utils, acpid, kernel etc.


> ----
>
> I can see at least two problems with this:
>
> 1. /usr/lib/pm-utils/power.d/95hdparm-apm checks for the presence of
> /var/run/laptop-mode-tools/enabled , and when found, the pm-utils hook
> immediately exits because it assumes laptop-mode-tools is managing HDD
> PM (by checking for CONTROL_HD_POWERMGMT in
> /etc/laptop-mode/laptop-mode.conf).
> This also affects suspend/resume/hibernate/thaw modes, due to symlink
> from /usr/lib/pm-utils/sleep.d/95hdparm-apm
> This effectively prevents hdparm from managing HDD's APM.
>
> 2. /usr/lib/pm-utils/sleep.d/01laptop-mode , when it finds
> /usr/sbin/laptop_mode, runs it with the arguments "auto force". This
> results in error: laptop-mode-tools is disabled in config file.
> Exiting
>
> Best,
> Jasmine


-- 
Ritesh Raj Sarraf
RESEARCHUT - http://www.researchut.com
"Necessity is the mother of invention."


Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to