pm-tools hook is run even if laptop-mode is disabled [PATCH]

Bug #437147 reported by Tormod Volden
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
laptop-mode-tools (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Binary package hint: laptop-mode-tools

By default laptop-mode is disabled by ENABLE_LAPTOP_MODE=false in /etc/default/acpi-support . This flag is probed for by /etc/init.d/laptop-mode which will just quit.

However, the /etc/pm/sleep.d/99laptop-mode hook for pm-utils will run "/usr/sbin/laptop_mode auto force" unconditionally, and laptop_mode itself does not probe for the above flag.

Although it was not run at boot and there is no existing /var/run/laptop-mode-tools/enabled , laptop_mode will run through its modules and apply a number of parameters. One example is /usr/share/laptop-mode-tools/modules/hdparm which calls hdparm, and on my laptop causes the hard drive to lock up.

ProblemType: Bug
Architecture: i386
Date: Sat Sep 26 13:23:44 2009
DistroRelease: Ubuntu 9.10
Package: laptop-mode-tools 1.47-1ubuntu1
PackageArchitecture: all
ProcEnviron:
 LANG=en_US.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.31-11.36-generic
SourcePackage: laptop-mode-tools
Uname: Linux 2.6.31-11-generic i686

Revision history for this message
Tormod Volden (tormodvolden) wrote :
Revision history for this message
Tormod Volden (tormodvolden) wrote :

You can see in this verbose output that laptop_mode does quite a number of things even if it detects that it is disabled (it says "disabled, not active" and STATE=disabled).

Revision history for this message
Tormod Volden (tormodvolden) wrote :
summary: - pm-tools hook is run even if laptop-mode is disabled
+ pm-tools hook is run even if laptop-mode is disabled [PATCH]
Revision history for this message
Tormod Volden (tormodvolden) wrote :

This is in fact fixed in /usr/lib/pm-utils/sleep.d/96laptop-mode which does the same. We just have to get rid of the obsolete and broken /etc/pm/sleep.d/99laptop-mode !

See bug 384875.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package laptop-mode-tools - 1.47-1ubuntu2

---------------
laptop-mode-tools (1.47-1ubuntu2) karmic; urgency=low

  * debian/rules: do not ship obsolete and broken
    /etc/pm/sleep.d/99laptop-mode (LP: #384875, #437147)
  * debian/laptop-mode-tools.preinst: delete it on upgrades

  [ Steve Langasek ]
  * debian/laptop-mode-tools.preinst: use the standard snippet for removing
    obsolete conffiles safely.

 -- Tormod Volden <email address hidden> Sat, 26 Sep 2009 13:54:30 +0200

Changed in laptop-mode-tools (Ubuntu):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.