You are not logged in.

#1 2012-01-23 15:13:30

ajaxas
Member
Registered: 2009-02-23
Posts: 65
Website

[SOLVED] Sony Vaio Keys don't work (probably udev issue)

Hardware: SONY VAIO VPC-EH2L1R
Linux distribution: archlinux, XFCE
udev versions: 177, 178 (core), udev-git 20120123-1 (AUR)
keyboard driver: evdev

At least a week earlier I had some of Sony Vaio Keys working: Volume control (Fn+F2: mute, Fn+F3: down, Fn+F4: up) and Brightness control (Fn+F5: down, Fn+F6: up). Other Vaio Keys (Fn+F1: touchpad switch, Fn+F7: switch video mode, Fn+F12: suspend) never worked.
At some point (I think after updating to udev-177-1) Brightness control keys stopped working. Volume control keys still work.
Brightness control still works directly via acpi.

I know this may sound like this bug, but that solution doesn't work for me - neither updating to udev-git nor manually loading the keymap.

My keyboards are:

[ajaxas@r2d2 ~]$ /lib/udev/findkeyboards 
AT keyboard: input/event0
module: input/event1

which are actually:

[ajaxas@r2d2 ~]$ cat /proc/bus/input/devices 
I: Bus=0011 Vendor=0001 Product=0001 Version=ab41
N: Name="AT Translated Set 2 keyboard"
P: Phys=isa0060/serio0/input0
S: Sysfs=/devices/platform/i8042/serio0/input/input0
U: Uniq=
H: Handlers=kbd event0 
B: PROP=0
B: EV=120013
B: KEY=402000000 3803078f800d001 feffffdfffefffff fffffffffffffffe
B: MSC=10
B: LED=7

I: Bus=0010 Vendor=104d Product=0000 Version=0000
N: Name="Sony Vaio Keys"
P: Phys=
S: Sysfs=/devices/LNXSYSTM:00/device:00/PNP0A08:00/device:02/SNY5001:00/input/input1
U: Uniq=
H: Handlers=kbd rfkill event1 
B: PROP=0
B: EV=13
B: KEY=1f16cf0000 c00000000 10010000000000 200000000 600e00102c00 380000240300400 e000000000000 0
B: MSC=10

Now, the funny thing is that (I think) udev loads my keymap correctly:

[ajaxas@r2d2 ~]$ cat /sys/class/dmi/id/{sys_vendor,product_name}
Sony Corporation
VPCEH2L1R

Here is this keymap module-sony (which worked until recently!):

[ajaxas@r2d2 ~]$ cat /lib/udev/keymaps/module-sony
0x06 mute # Fn+F2
0x07 volumedown # Fn+F3
0x08 volumeup # Fn+F4
0x09 brightnessdown # Fn+F5
0x0A brightnessup # Fn+F6
0x0B switchvideomode # Fn+F7
0x0E zoom # Fn+F10
0x10 suspend # Fn+F12

- but here is where it starts getting curiouser and curiouser.
My Volume control keys seem to be mapped to input/event0 (keyboard itself):

[root@r2d2 ajaxas]# /lib/udev/keynap -i input/event0
scan code: 0xA0   key code: mute
scan code: 0xAE   key code: volumedown
scan code: 0xB0   key code: volumeup

and these scan codes correspond not to my keymap (0x06, 0x07, 0x08), but to /lib/udev/keymaps/force-release/common-volume-keys:

[ajaxas@r2d2 ~]$ cat /lib/udev/keymaps/force-release/common-volume-keys
0xa0 #mute
0xae #volume down
0xb0 #volume up

So I assume, udev uses force-release rules before other keymaps and maps my Volume control keys to input/event0 (how? I couldn't find the rule!), which is more or less fine with me, but!
My Brightness control keys, mapped as 0x09 and 0x0A in the keymap, are reported by udev as:

[root@r2d2 ajaxas]# /lib/udev/keymap -i input/event1
scan code: 0x10   key code: brightnessdown
scan code: 0x11   key code: brightnessup

If I change my keymap file (0x09 -> 0x10, 0x0A -> 0x11) and load keymap manually, nothing changes. And when I reboot with this changed keymap, udev reports this for my Brightness control keys:

[root@r2d2 ajaxas]# /lib/udev/keymap -i input/event1
scan code: 0x10   key code: fn_f5
scan code: 0x11   key code: fn_f6

Again, nothing works, and keys are not reported as Brightness control keys anymore.

As I said earlier, updating udev doesn't help.

Could somebody please help me?

EDIT: added keyboard driver (evdev) reference.

Last edited by ajaxas (2012-01-25 13:52:54)

Offline

#2 2012-01-25 13:52:06

ajaxas
Member
Registered: 2009-02-23
Posts: 65
Website

Re: [SOLVED] Sony Vaio Keys don't work (probably udev issue)

Okay, this is stupid but it was XFCE's fault. If anyone with the same problem reads this, try creating a new user account and see if it's actually udev or only your shitty DE. -_-

Offline

#3 2012-01-27 11:46:21

Mrs.Columbo
Member
Registered: 2008-06-18
Posts: 24

Re: [SOLVED] Sony Vaio Keys don't work (probably udev issue)

Hi,

Seems to me that I have a similar problem - on a different sony laptop model.
However, adding a new user did not change anything for me. Usually I start my (E17-) session via startx; function keys used to work just fine that way. Now they dont.
Furthermore, I got gnome3 installed; launching a gnome-session via startx also leaves me without brightness key functionality.

However, if I use gdm to log into a gnome-session everything works like a charm. On the same user. Unfortunately, I have no clue what services gdm starts that are then passed on to the gnome session.
Do you use a login manager?

MC.

Offline

#4 2012-01-27 12:06:54

ajaxas
Member
Registered: 2009-02-23
Posts: 65
Website

Re: [SOLVED] Sony Vaio Keys don't work (probably udev issue)

I use slim and it has nothing to do with backlight.
Did you update to udev-179? Does xev report anything for your backlight control keys?

If yes, find which input is Sony Vaio Keys and then run

# /lib/udev/keymap -i input/eventX

- and press you brightness control keys, see if it reports proper key codes (brightnessdown, brightnessup). Ctrl+C to exit.

Offline

#5 2012-02-20 18:06:19

jst
Member
Registered: 2012-01-24
Posts: 5

Re: [SOLVED] Sony Vaio Keys don't work (probably udev issue)

ajaxas wrote:

Okay, this is stupid but it was XFCE's fault. If anyone with the same problem reads this, try creating a new user account and see if it's actually udev or only your shitty DE. -_-

How did you solve this? I realized I have the same problem with XFCE, but could not solve it smile

Offline

#6 2012-02-21 11:42:14

ajaxas
Member
Registered: 2009-02-23
Posts: 65
Website

Re: [SOLVED] Sony Vaio Keys don't work (probably udev issue)

jst wrote:
ajaxas wrote:

Okay, this is stupid but it was XFCE's fault. If anyone with the same problem reads this, try creating a new user account and see if it's actually udev or only your shitty DE. -_-

How did you solve this? I realized I have the same problem with XFCE, but could not solve it smile

I don't really remember. As a matter of fact, I've already switched to KDE and I'm quite content with it smile

Offline

Board footer

Powered by FluxBB