No function keys for sleep and hibernation in Kubuntu on Thinkpad

Bug #281284 reported by Katsudon
46
This bug affects 6 people
Affects Status Importance Assigned to Milestone
KDE Base
Fix Released
Medium
acpi
Invalid
Undecided
Unassigned
kdebase-workspace (Ubuntu)
Fix Released
Low
Unassigned

Bug Description

Kubuntu 8.10 beta with all upgrades, laptop Thinkpad R61i

Regression from Kubuntu 8.04: the function keys for hibernation, sleep do not work.
Function keys for locking the screen and battery state do not work and they never worked.
The function keys for brightness work, but very slowly (1 step of brightness per second).

Revision history for this message
Ian Weisser (ian-weisser) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. Unfortunately we can't fix it without more information.

Please include the information requested at https://wiki.ubuntu.com/DebuggingACPI as separate attachments.

Revision history for this message
Katsudon (katsudon) wrote :
Revision history for this message
Katsudon (katsudon) wrote :
Revision history for this message
Katsudon (katsudon) wrote :
Revision history for this message
Katsudon (katsudon) wrote :
Revision history for this message
Katsudon (katsudon) wrote :
Changed in acpi:
status: Incomplete → New
Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

Looks like Xorg is dropped the event. Installing kpowersave fixed this issue for me. Also see https://bugs.launchpad.net/ubuntu/+source/hal/+bug/267682

Revision history for this message
Katsudon (katsudon) wrote :

Installing kpowersave indeed fixes this issue concerning Fn-F12 (hibernation) and Fn-F4 (sleep). It would be cool to make them work without such workarounds.

Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

This is the same as bug #198214 except this bug is for KDE desktop

Revision history for this message
Steve Langasek (vorlon) wrote :

Confirmed, this is mostly a duplicate of 198214, but 198214 is a bug of acpi-support which is intended to be deprecated for Ubuntu 9.04. It seems to me that kpowersave should be a dependency or recommendation of kubuntu-desktop, is there a reason this isn't the case?

Changed in acpi:
status: New → Confirmed
Revision history for this message
Jonathan Thomas (echidnaman) wrote :

We use guidance-power-manager in Intrepid and are going to use Powerdevil from upstream in KDE for 9.04.

Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

guidance-power-manager isn't a dependency of kubuntu-desktop?

Revision history for this message
danR (rappdw) wrote :

I tried installing kpowersave to work around this issue and it exhibited the following characteristics. While Fn-4 will sleep after a clean boot, after a resume from sleep, it no longer does so.

Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

I don't see that, but I do see something odd - using fn-f4 suspends, and then on restart it will suspend again (!), and then the next restart will be fine. Probably the event is now getting delivered and handled twice due to some changes somewhere... "Suspend to RAM" from the start menu works as expected.

Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

This is still broken in Jaunty.
fn-f4 and fn-f12 do not work.

Tested using Thinkpad T42p, Kubuntu alpha 3 live CD and Jaunty with updates as of 20080130.

Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

Just to confirm: The Jaunty testing was done with a complete install. Both the live CD and new install are broken.

Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

Jaunty again: installed kpowersave, it responds to fn-f4 and suspends. On resume it reports a suspend "error -1" that wasn't present with Intrepid. But at least it sees the key press event and suspends.

lsof shows me that kded4 and krunner have loaded /usr/lib/kde4/kded_powerdevil.so /usr/lib/kde4/krunner_powerdevil.so

So powerdevil is there, it just doesn't seem to react to fn-f4.

Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

Jaunty+kpowersave also suspends immediately after resume (same as Intrepid+kpowersave).

Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

Bug 306310 appears to be the same "suspend after resume" bug assigned to gnome-power-manager. Obviously this is not the case for KDE but both may have a common cause.

Revision history for this message
Chris Bainbridge (chris-bainbridge) wrote :

Jonathan: In Intrepid, should guidance-power-manager not be a dependency of kubuntu-desktop?

With the latest acpid update of today I no longer see repeated suspends under Jaunty KDE+kpowersave. Instead kpowersave reports an "error -1" after resume.

powerdevil still does not respond to XF86Sleep event from suspend key, there is an upstream bug for this.

Changed in acpi:
status: Unknown → Confirmed
Revision history for this message
Jonathan Thomas (echidnaman) wrote :

Since some may prefer to use other power managers, a hard dependency on g-p-m is not required. Recommends get pulled in to the live cd, and are installed by default.

Changed in kubuntu-meta:
importance: Undecided → Low
status: Confirmed → Triaged
Changed in acpi:
importance: Unknown → Undecided
status: Confirmed → New
status: New → Invalid
Changed in kdebase:
status: Unknown → Confirmed
Revision history for this message
Tillmann Falck (tfalck) wrote :

Putting the attached script in .kde/Autostart (or just running it manually) activates most of the missing hotkeys on my thinkpad. In particular it supports

* lock screen
* suspend
* hibernate
* toggle screen
* undock
* battery information

I have used the script for a month now and for me it works. It should not be limited to thinkpads but support all laptops that generate the corresponding key press events. Most functionality is accessed via dbus either using HAL or KDE services.

It depends on python2.6 (could be easily backported to 2.5), python-dbus and python-xlib.

Revision history for this message
Brian Harkness (maestro-bwh) wrote :

This is still an issue in Karmic alpha 5

the softkeys.py don't seem to work for me in (fresh install)

I notice that in /etc/acpi/events: There is not a single reference to the ibm functions (i.e. in debian, ibm-sleepbtn and ibm-hibernatebtn.

How annoying is that?

I am going to try to manually make those two files according to

http://www.thinkwiki.org/wiki/Installing_Debian_4.0_%28Etch%29_on_a_ThinkPad_T42

and see what happens.

Revision history for this message
Brian Harkness (maestro-bwh) wrote :

Thinkpad T43

Although I should not HAVE to, I did add the two files (above link) to get fn+F4 and fn+F12 to work:

/etc/acpi/events/ibm-sleepbtn
   event=ibm/hotkey HKEY 00000080 00001004
   action=/etc/acpi/sleep.sh force

/etc/acpi/events/ibm-hibernatebtn
   event=ibm/hotkey HKEY 00000080 00001004
   action=/etc/acpi/hibernate.sh

The former causes a hiccup where it sort of suspends, and comes right back, which apparently causes something else to happen and then the unit will suspend properly. it comes out of suspend fine, although it is not interfacing with powerdevil (kde's power managment) because it does not prompt me for a password upon resume.

If I suspend the unit from the tray icon or using the logout dialog, suspend works without the hiccup and it prompts me for a login password on resume.

I generally have learned to use the tray icon or the logout dialogue, just because the keys never worked in Ubuntu for me (apparently this broke during/after Hardy)

These keys work in Arch, and oddly, knoppix 6.01 (modified debian lenny)

Revision history for this message
Brian Harkness (maestro-bwh) wrote :

My reference to the hibernate hotkey is incorrect, it would be whatever acpi_listen would output. I have it disabled because I don't have a swapspace (using an SSD).

Revision history for this message
dm (jan-rauberg) wrote :

I'm using a Lenovo T400s and have the same problems with KDE4.3 on Jaunty. Neither Fn+F4 nor Fn+F12 works. Under Gnome everything is fine. I prefer KDE and these bug is a very annoying thing. It would be very, very nice if it gets fixed. Please.

Revision history for this message
Sean Hunt (coppro) wrote :

I can confirm this with a T500 on Karmic.

Revision history for this message
A. Hornung (mail-arminhornung) wrote :

Same annoying problem on a Lenovo X301 in Kubuntu 9.10. The script attached by T. Falck (#22) works perfectly, so why hasn't that functionality been properly integrated yet?

Revision history for this message
Tillmann Falck (tfalck) wrote :

As at least some people are using my script (comment #22), I gave it a quick update for Karmic or rather KDE 4.4. Now the used dbus path should be all valid once more and all claimed buttons do what they are supposed to.

Changed in kdebase:
status: Confirmed → Fix Released
Changed in kdebase:
importance: Unknown → Medium
Changed in kdebase-workspace (Ubuntu):
status: Triaged → 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.