acpi_fakekey in sleepbtn.sh does nothing when thinkpad_acpi is loaded

Bug #162472 reported by Marc MERLIN
26
This bug affects 1 person
Affects Status Importance Assigned to Milestone
acpi-support (Ubuntu)
Fix Released
Undecided
Unassigned
kde-guidance (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Fn + Fx works, Fn+F4 generates executing action "/etc/acpi/lockbtn.sh"

acpi_fakekey $KEY_COFFEE does nothing
(although it did with thinkpad_acpi unloaded, but restore from suspend to ram didn't seem to work right)

If I replace it with /etc/acpi/sleep.sh, everything works fine.

Same thing with /etc/acpi/hibernatebtn.sh

Revision history for this message
Marc MERLIN (marc-soft) wrote :

acpi-support 0.103 in gutsy (dist-upgraded from feisty), thinkpad Z61p, 2.6.22.1 booted with acpi_sleep=s3_bios

Revision history for this message
Andreas Wenning (andreas-wenning) wrote :

Dist: Kubuntu hardy (alpha 2)
acpi-support: 0.104
uname -a:
Linux andreas-laptop 2.6.24-2-generic #1 SMP Thu Dec 20 17:36:12 GMT 2007 i686 GNU/Linux

I have the same problem on a Thinkpad T43. Sleep and hibernate works flawlessly from the buttons in the KDE-menu, or by executing the sleep / hibernate scripts. When using Fn+F4 and Fn+F12 I can see the events in /var/log/acpid, but the acpi_fakekey events in the button scripts doesn't work, so no hibernation or sleep (only a desktop lock when using Fn+F4).

Revision history for this message
Manuel Siggen (manuel-siggen) wrote :

(coming from bug 185305)

Just to say I have the same problem on a Thinkpad X40 running up-to-date Kubuntu Hardy. The Fn-F4 (suspend-to-ram on my machine) key does nothing (more precisely, the event appears on acpid log but then then acpi_fakekey does nothing). Suspend-to-ram itself works flawlessly from the Log Out -> Suspend menu.

Here there something I could do to help solve this issue ?

Thanks a lot !

Revision history for this message
Juha Tiensyrjä (juha-tiensyrja) wrote :

The same problem here, with a Thinkpad X60s. I can see log messages in /var/log/acpid when I press sleep or hibernate buttons, but the machine does nothing. Suspend works when executed from the Logout menu.

I'm using Kubuntu Hardy at the moment, with "uname -a" reporting the following:
Linux tele 2.6.24-5-generic #1 SMP Thu Jan 24 19:45:21 UTC 2008 i686 GNU/Linux

Revision history for this message
Chris Jones (cmsj) wrote :

I'm not sure that the description of this bug is exactly right, but it's clear that hardy is regressing on ACPI button support from the number of comments here, so I'm confirming this.

Changed in acpi-support:
status: New → Confirmed
Revision history for this message
Andreas Wenning (andreas-wenning) wrote :

Here is a patch, that should solve the problem.

  * Changed events/ibm-sleepbtn and events/ibm-hibernatebtn to use
    ibm-sleep.sh and ibm-hibernate.sh directly. (LP: #162472)

I've uploaded it to my PPA, so people can test:
https://launchpad.net/~andreas-wenning/+archive

Can someone confirm, that it works, as it should?

Changed in acpi-support:
assignee: nobody → andreas-wenning
status: Confirmed → In Progress
Revision history for this message
Manuel Siggen (manuel-siggen) wrote :

Thanks for this patch ! I applied it by hand (because it was so small) and ran :

  $ sudo /etc/init.d/acpid force-reload
  $ sudo /etc/init.d/acpid restart

... and then the Fn+F4 (suspend-to-ram) started working !

The funny thing is that I then reverted the patch, ran again the force-reload/restart commands so to come back to the initial state. The idea was to install the .deb and test the whole procedure, but then even with the reverted scripts the Fn+F4 continued working...

So I don't know what really fixed the problem : the patch or the force-reload on acpid (or something else) ?

Revision history for this message
Andreas Wenning (andreas-wenning) wrote :

@Manuel
I usually need to do:
sudo /etc/init.d/acpid restart
before restarting acpid to be sure, that the current scripts are reloaded. Might be answering, why it worked after reverting.

Revision history for this message
Andreas Wenning (andreas-wenning) wrote :

Sorry, it is of course:
sudo /etc/init.d/acpi-support restart

Revision history for this message
Andreas Wenning (andreas-wenning) wrote :

I'm subscribing ubuntu-main-sponsors. I hope the naming scheme is correct; haven't been able to verify if this is a truly native ubuntu package. If I should change anything, just point it out.

Changed in acpi-support:
assignee: andreas-wenning → nobody
status: In Progress → Confirmed
Revision history for this message
Daniel Holbach (dholbach) wrote :

Paul: could you please take a look at it?

Revision history for this message
Juha Tiensyrjä (juha-tiensyrja) wrote :

awen, I tried your package on my Thinkpad X60s. Now suspending with Fn+F4 works, but after resuming from suspend my WLAN card (Intel 3945 using iwl3945 driver) does not come back up. I can't get it to work even by removing the iwl3945 module and then modprobing it back. However, suspending from KDE's logout menu works like a charm, no such problems.

Revision history for this message
Andreas Wenning (andreas-wenning) wrote :

@Juha
As far as I know the suspend should be exactly the same. This happens every time?
You could try adding the wlan driver to MODULES= in /etc/default/acpi-support .

Revision history for this message
Andreas Wenning (andreas-wenning) wrote :

After some testing it seems that KDE uses it's own internal suspend script.

Revision history for this message
Andreas Wenning (andreas-wenning) wrote :

After some testing I can see, that in Hardy the fakekey events is sent; at least on my T43 (which didn't worked earlier). If there is still problems on certain laptops feel free to reopen and state exact model.
There is still some problems suspending from KDE with the buttons. This is reported as bug 194780 .

Changed in acpi-support:
status: Confirmed → Invalid
Changed in kde-guidance:
status: New → Invalid
Changed in acpi-support:
status: Invalid → Fix Released
Revision history for this message
Fred Flegel (spen-launchlinux) wrote :

still doesnt work with my thinpad r52 hardy. intrpid neither

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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