Hotkeys not detected on Asus F3sv (ACPI events)

Bug #361505 reported by Sika
4
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Undecided
Corentin Chary

Bug Description

Hi
Using jaunty fully updated (with live cd or with an upgraded intrepid), some hotkeys are not working on my laptop (asus f3sv).
I followed the procedure there: https://wiki.ubuntu.com/Hotkeys/Troubleshooting .
The hotkeys that are not working are sending ACPI events but no input event is generated. This is the list og these keys:
"hotkey ATKD 00000050 00000000" -> should launch email client
"hotkey ATKD 00000051 00000000" -> should launch web browser
"hotkey ATKD 00000061 00000000" -> switch between LCD/external monitor (Maybe this one works, I couldn't test).
"hotkey ATKD 0000005c 00000000" -> lock the screen
"hotkey ATKD 00000095 00000000" -> the manual says "Launches a multimedia application (cd/dvd, tv, video, audio)".
"hotkey ATKD 0000008a 00000000" -> the manual says "Switch between different color, brightness, sharpness and contrast presets".
"hotkey ATKD 00000082 00000000" -> should launch a webcam app (cheese for example)
"hotkey ATKD 00000099 00000000" -> the manual says "Activate or desativate "Power for Phone"", I think launching ekiga would be ok.

Other keys are working great.

Would it be possible to fix this for jaunty? It must be quite trivial to solve with the new hotkeys management architecture?
In case this couldn't be done for jaunty, is there a workaround to make these hotkeys work?

I can provide more info if needed.
Thanks.

ProblemType: Bug
Architecture: amd64
DistroRelease: Ubuntu 9.04
MachineType: ASUSTeK Computer Inc. F3Sv
NonfreeKernelModules: nvidia
Package: linux-image-2.6.28-11-generic 2.6.28-11.41
ProcCmdLine: root=UUID=502463fb-a2a5-41bd-830e-a219af060fd3 ro quiet splash
ProcEnviron:
 LANG=fr_FR.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.28-11.41-generic
SourcePackage: linux

Revision history for this message
Sika (sikamikaniboots) wrote :
Revision history for this message
Sika (sikamikaniboots) wrote :

Looking at asus-laptop module code in 2.6.29 (http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.29.y.git;a=blob;f=drivers/platform/x86/asus-laptop.c;h=eeafc6c0160dbe41b827a627f77c842d396adbd6;hb=8d7bff2d72660d9d60aa371ae3d1356bbf329a09) it seems like it is solved in 2.6.29 (I didn't test it).

So is there some way to backport this module?

Revision history for this message
Leann Ogasawara (leannogasawara) wrote :

Hi Sika,

Unfortunately the kernel is currently frozen for the upcoming Jaunty 9.04 release. Any fixes will likely have to wait for Karmic. I'm also unsure of the likelyhood that this would qualify for a Stable Release Update to Jaunty - http://wiki.ubuntu.com/StableReleaseUpdates. However, I would like to let you know the Ubuntu kernel team has been packaging upstream Mainline kernel builds for testing. You could test the 2.6.29 kernel and see if it resolves the issue you are seeing. Please let us know. Thanks.

Changed in linux (Ubuntu):
status: New → Incomplete
Revision history for this message
Sika (sikamikaniboots) wrote :
Download full text (3.3 KiB)

Thanks for your answer.
I have tested 2.6.29-1 kernel: it's a better but there are still 2 issues:

First, there are 2 keys with an input event >255 (0x0ff):
-"hotkey ATKD 0000005c 00000000" mapped to BTN_EXTRA (0x179). I think it should be mapped to KEY_SCREENLOCK instead as this is what this button is supposed to do.
-"hotkey ATKD 0000008a 00000000" mapped to KEY_TV (0x114). I don't know what we could use instead.

The second problem is that for certain buttons, events are reported by 2 input device (so event triggered 2 times). It affects keys mapped to:
KEY_PLAYPAUSE
KEY_NEXTSONG
KEY_PREVIOUSSONG
KEY_STOPCD
KEY_VOLUMEDOWN
KEY_VOLUMEUP
KEY_MIN_INTERESTING
The two input devices that report events are these ones (from "hal-find-by-capability --capability input | xargs -n1 lshal -u"):

udi = '/org/freedesktop/Hal/devices/computer_logicaldev_input_3'
  info.addons.singleton = {'hald-addon-input'} (string list)
  info.callouts.add = {'debian-setup-keyboard'} (string list)
  info.capabilities = {'input', 'input.keys', 'button'} (string list)
  info.category = 'input' (string)
  info.parent = '/org/freedesktop/Hal/devices/computer' (string)
  info.product = 'Asus Laptop extra buttons' (string)
  info.subsystem = 'input' (string)
  info.udi = '/org/freedesktop/Hal/devices/computer_logicaldev_input_3' (string)
  input.device = '/dev/input/event8' (string)
  input.product = 'Asus Laptop extra buttons' (string)
  input.x11_driver = 'evdev' (string)
  input.xkb.layout = 'fr' (string)
  input.xkb.model = 'pc105' (string)
  input.xkb.rules = 'evdev' (string)
  input.xkb.variant = 'oss' (string)
  linux.device_file = '/dev/input/event8' (string)
  linux.hotplug_type = 2 (0x2) (int)
  linux.subsystem = 'input' (string)
  linux.sysfs_path = '/sys/devices/virtual/input/input8/event8' (string)

udi = '/org/freedesktop/Hal/devices/platform_i8042_i8042_KBD_port_logicaldev_input'
  info.addons.singleton = {'hald-addon-input'} (string list)
  info.callouts.add = {'debian-setup-keyboard'} (string list)
  info.capabilities = {'input', 'input.keyboard', 'input.keypad', 'input.keys', 'button'} (string list)
  info.category = 'input' (string)
  info.parent = '/org/freedesktop/Hal/devices/platform_i8042_i8042_KBD_port' (string)
  info.product = 'AT Translated Set 2 keyboard' (string)
  info.subsystem = 'input' (string)
  info.udi = '/org/freedesktop/Hal/devices/platform_i8042_i8042_KBD_port_logicaldev_input' (string)
  input.device = '/dev/input/event4' (string)
  input.originating_device = '/org/freedesktop/Hal/devices/platform_i8042_i8042_KBD_port' (string)
  input.product = 'AT Translated Set 2 keyboard' (string)
  input.x11_driver = 'evdev' (string)
  input.xkb.layout = 'fr' (string)
  input.xkb.model = 'pc105' (string)
  input.xkb.rules = 'evdev' (string)
  input.xkb.variant = 'oss' (string)
  linux.device_file = '/dev/input/event4' (string)
  linux.hotplug_type = 2 (0x2) (int)
  linux.subsystem = 'input' (string)
  linux.sysfs_path = '/sys/devices/platform/i8042/serio0/input/input4/event4' (string)

So it seems like /dev/input/event4 should not report them?

I can provide more infos if needed, or make any test.
I can understan...

Read more...

Revision history for this message
Sika (sikamikaniboots) wrote :

I've made a few tests. With 2.6.30 rc2 I get the same results as 2.6.29.
The problem of events sent twice is not really hard to solve: these events are sent both by the kernel module (acpi_laptop) and by acpi_fakekey. But if I understood correctly, acpi_fakekey is deprecated? So this should be solved in karmic: we'll only have to remove some stuff from acpi-support package (files in /etc/acpi and /etc/acpi/events).

Now the only thing that needs to be done in the kernel is replacing 3 keycodes in asus-laptop.c:
l272, "{KE_KEY, 0x43, KEY_STOP}," should be replaced by "{KE_KEY, 0x43, KEY_STOPCD},"
l276, "{KE_KEY, 0x5C, BTN_EXTRA}," should be replaced by "{KE_KEY, 0x5C, KEY_SCREENLOCK},"
l281, "{KE_KEY, 0x8A, KEY_TV}," should be replaced by "{KE_KEY, 0x8A, KEY_PROG1},"

So can anyone send this patch upstream before the 2.6.30 release? Or tell me how to do it.
Thanks

Revision history for this message
Corentin Chary (iksaif) wrote :

Here is the patch.
I'll send it to linux-acpi soon, but it's already in the acpi4asus git tree.

Changed in linux (Ubuntu):
assignee: nobody → corentin-chary
status: Incomplete → 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.