On 2012-08-04 03:40:11 +0200, Vincent Lefevre wrote: > Actually when I suspend and resume the laptop, the USB keyboard > is unaffected. Only when unplug it and plug it in again.
A few hours ago, as I did a suspend/resume of my laptop, with only its builtin keyboard, I noticed that the XKB settings were restored (without the need to run xkbcomp), and everything worked fine. I looked at the kernel and Xorg logs (see below), and saw that the builtin keyboard was recognized as a USB HID keyboard instead of an AT Translated Set 2 keyboard as usual. But I've done other tests and I can't make it work again. USB keyboard recognition needs the RF_KILL bit to be set to enable radio. I don't know whether this is a bug or there is a reason. But the bug (XKB settings lost after suspend) needs to be fixed one way or another. Since the problem may come from the kernel in the first place, this could be a kernel bug, the problem in Xorg being just a consequence. Here are the logs, when the XKB settings were restored: In the /var/log/syslog file, keyboard information did not appear after wake up, until the RF_KILL bit was toggled to enable radio: [...] Aug 10 21:11:25 xvii kernel: [235310.726023] iwlwifi 0000:0c:00.0: RF_KILL bit toggled to enable radio. Aug 10 21:11:26 xvii kernel: [235311.208293] usb 3-1: new full-speed USB device number 16 using uhci_hcd Aug 10 21:11:26 xvii kernel: [235311.385578] usb 3-1: New USB device found, idVendor=0a5c, idProduct=4500 Aug 10 21:11:26 xvii kernel: [235311.385588] usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0 Aug 10 21:11:26 xvii kernel: [235311.385595] usb 3-1: Product: BCM2046B1 Aug 10 21:11:26 xvii kernel: [235311.385599] usb 3-1: Manufacturer: Broadcom Aug 10 21:11:26 xvii kernel: [235311.387503] hub 3-1:1.0: USB hub found Aug 10 21:11:26 xvii kernel: [235311.389335] hub 3-1:1.0: 3 ports detected Aug 10 21:11:26 xvii kernel: [235311.670578] usb 3-1.1: new full-speed USB device number 17 using uhci_hcd Aug 10 21:11:26 xvii kernel: [235311.788586] usb 3-1.1: New USB device found, idVendor=413c, idProduct=8157 Aug 10 21:11:26 xvii kernel: [235311.788596] usb 3-1.1: New USB device strings: Mfr=0, Product=0, SerialNumber=0 Aug 10 21:11:26 xvii kernel: [235311.794006] input: HID 413c:8157 as /devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.1/3-1.1:1.0/input/input28 Aug 10 21:11:26 xvii kernel: [235311.794332] generic-usb 0003:413C:8157.000A: input,hidraw0: USB HID v1.11 Keyboard [HID 413c:8157] on usb-0000:00:1a.0-1.1/input0 [...] In the /var/log/Xorg.0.log file after wake up: [235125.841] (II) Open ACPI successful (/var/run/acpid.socket) [235125.841] (II) AIGLX: Resuming AIGLX clients after VT switch [235125.841] (II) NOUVEAU(0): NVEnterVT is called. [235125.990] (II) NOUVEAU(0): EDID vendor "AUO", prod id 16455 [235125.990] (II) NOUVEAU(0): Printing DDC gathered Modelines: [235125.990] (II) NOUVEAU(0): Modeline "1440x900"x0.0 108.00 1440 1504 1536 1970 900 903 906 912 +hsync -vsync (54.8 kHz eP) [235125.990] (II) NOUVEAU(0): Modeline "1440x900"x0.0 72.50 1440 1504 1536 1970 900 903 906 912 +hsync -vsync (36.8 kHz e) [235126.117] (**) Option "Device" "/dev/input/event10" [235126.117] (--) synaptics: AlpsPS/2 ALPS DualPoint TouchPad: touchpad found [235312.020] (II) config/udev: Adding input device HID 413c:8157 (/dev/input/event1) [235312.020] (**) HID 413c:8157: Applying InputClass "evdev keyboard catchall" [235312.020] (II) Using input driver 'evdev' for 'HID 413c:8157' [235312.020] Option "XkbRules" "evdev" [235312.020] Option "xkb_model" "pc105" [235312.020] Option "xkb_layout" "gb" [235312.020] Option "_source" "server/udev" [235312.020] Option "name" "HID 413c:8157" [235312.020] Option "path" "/dev/input/event1" [235312.020] Option "device" "/dev/input/event1" [235312.020] Option "xkb_options" "lv3:ralt_switch" [235312.020] Option "config_info" "udev:/sys/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.1/3-1.1:1.0/input/input28/event1" [235312.020] Option "driver" "evdev" [235312.020] (**) HID 413c:8157: always reports core events [235312.020] (**) evdev: HID 413c:8157: Device: "/dev/input/event1" [235312.020] (--) evdev: HID 413c:8157: Vendor 0x413c Product 0x8157 [235312.020] (--) evdev: HID 413c:8157: Found keys [235312.020] (II) evdev: HID 413c:8157: Configuring as keyboard [235312.020] (**) Option "config_info" "udev:/sys/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.1/3-1.1:1.0/input/input28/event1" [235312.020] (II) XINPUT: Adding extended input device "HID 413c:8157" (type: KEYBOARD, id 15) [235312.020] (**) Option "xkb_rules" "evdev" [235312.020] (**) Option "xkb_model" "pc105" [235312.020] (**) Option "xkb_layout" "gb" [235312.020] (**) Option "xkb_options" "lv3:ralt_switch" [235312.020] (II) XKB: Reusing cached keymap With a second try... In the /var/log/syslog file: [...] Aug 10 22:03:07 xvii kernel: [238341.135708] input: AT Translated Set 2 keyboard as /devices/platform/i8042/serio0/input/input32 [...] And after toggling the RF_KILL bit to enable radio: Aug 10 22:10:17 xvii kernel: [238774.107477] iwlwifi 0000:0c:00.0: RF_KILL bit toggled to enable radio. Aug 10 22:10:18 xvii kernel: [238774.588232] usb 3-1: new full-speed USB device number 22 using uhci_hcd Aug 10 22:10:18 xvii kernel: [238774.765505] usb 3-1: New USB device found, idVendor=0a5c, idProduct=4500 Aug 10 22:10:18 xvii kernel: [238774.765515] usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0 Aug 10 22:10:18 xvii kernel: [238774.765522] usb 3-1: Product: BCM2046B1 Aug 10 22:10:18 xvii kernel: [238774.765527] usb 3-1: Manufacturer: Broadcom Aug 10 22:10:18 xvii kernel: [238774.767445] hub 3-1:1.0: USB hub found Aug 10 22:10:18 xvii kernel: [238774.769264] hub 3-1:1.0: 3 ports detected Aug 10 22:10:18 xvii kernel: [238775.050498] usb 3-1.1: new full-speed USB device number 23 using uhci_hcd Aug 10 22:10:19 xvii kernel: [238775.169504] usb 3-1.1: New USB device found, idVendor=413c, idProduct=8157 Aug 10 22:10:19 xvii kernel: [238775.169514] usb 3-1.1: New USB device strings: Mfr=0, Product=0, SerialNumber=0 Aug 10 22:10:19 xvii kernel: [238775.175898] input: HID 413c:8157 as /devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.1/3-1.1:1.0/input/input33 Aug 10 22:10:19 xvii kernel: [238775.176371] generic-usb 0003:413C:8157.000C: input,hidraw0: USB HID v1.11 Keyboard [HID 413c:8157] on usb-0000:00:1a.0-1.1/input0 [...] In the /var/log/Xorg.0.log file: [238344.158] (II) Open ACPI successful (/var/run/acpid.socket) [238344.158] (II) AIGLX: Resuming AIGLX clients after VT switch [238344.158] (II) NOUVEAU(0): NVEnterVT is called. [238344.297] (II) NOUVEAU(0): EDID vendor "AUO", prod id 16455 [238344.297] (II) NOUVEAU(0): Printing DDC gathered Modelines: [238344.297] (II) NOUVEAU(0): Modeline "1440x900"x0.0 108.00 1440 1504 1536 1970 900 903 906 912 +hsync -vsync (54.8 kHz eP) [238344.297] (II) NOUVEAU(0): Modeline "1440x900"x0.0 72.50 1440 1504 1536 1970 900 903 906 912 +hsync -vsync (36.8 kHz e) [238344.420] (**) Option "Device" "/dev/input/event10" [238344.420] (--) synaptics: AlpsPS/2 ALPS DualPoint TouchPad: touchpad found [238344.421] (II) config/udev: Adding input device AT Translated Set 2 keyboard (/dev/input/event0) [238344.421] (**) AT Translated Set 2 keyboard: Applying InputClass "evdev keyboard catchall" [238344.421] (II) Using input driver 'evdev' for 'AT Translated Set 2 keyboard' [238344.421] Option "XkbRules" "evdev" [238344.421] Option "xkb_model" "pc105" [238344.421] Option "xkb_layout" "gb" [238344.421] Option "_source" "server/udev" [238344.421] Option "name" "AT Translated Set 2 keyboard" [238344.421] Option "path" "/dev/input/event0" [238344.421] Option "device" "/dev/input/event0" [238344.421] Option "xkb_options" "lv3:ralt_switch" [238344.421] Option "config_info" "udev:/sys/devices/platform/i8042/serio0/input/input32/event0" [238344.421] Option "driver" "evdev" [238344.421] (**) AT Translated Set 2 keyboard: always reports core events [238344.421] (**) evdev: AT Translated Set 2 keyboard: Device: "/dev/input/event0" [238344.421] (--) evdev: AT Translated Set 2 keyboard: Vendor 0x1 Product 0x1 [238344.421] (--) evdev: AT Translated Set 2 keyboard: Found keys [238344.421] (II) evdev: AT Translated Set 2 keyboard: Configuring as keyboard [238344.421] (**) Option "config_info" "udev:/sys/devices/platform/i8042/serio0/input/input32/event0" [238344.421] (II) XINPUT: Adding extended input device "AT Translated Set 2 keyboard" (type: KEYBOARD, id 9) [238344.421] (**) Option "xkb_rules" "evdev" [238344.421] (**) Option "xkb_model" "pc105" [238344.421] (**) Option "xkb_layout" "gb" [238344.421] (**) Option "xkb_options" "lv3:ralt_switch" [238344.421] (II) XKB: Reusing cached keymap [238775.401] (II) config/udev: Adding input device HID 413c:8157 (/dev/input/event1) [238775.401] (**) HID 413c:8157: Applying InputClass "evdev keyboard catchall" [238775.401] (II) Using input driver 'evdev' for 'HID 413c:8157' [238775.401] Option "XkbRules" "evdev" [238775.401] Option "xkb_model" "pc105" [238775.401] Option "xkb_layout" "gb" [238775.401] Option "_source" "server/udev" [238775.401] Option "name" "HID 413c:8157" [238775.401] Option "path" "/dev/input/event1" [238775.401] Option "device" "/dev/input/event1" [238775.401] Option "xkb_options" "lv3:ralt_switch" [238775.401] Option "config_info" "udev:/sys/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.1/3-1.1:1.0/input/input33/event1" [238775.401] Option "driver" "evdev" [238775.401] (**) HID 413c:8157: always reports core events [238775.401] (**) evdev: HID 413c:8157: Device: "/dev/input/event1" [238775.401] (--) evdev: HID 413c:8157: Vendor 0x413c Product 0x8157 [238775.401] (--) evdev: HID 413c:8157: Found keys [238775.401] (II) evdev: HID 413c:8157: Configuring as keyboard [238775.401] (**) Option "config_info" "udev:/sys/devices/pci0000:00/0000:00:1a.0/usb3/3-1/3-1.1/3-1.1:1.0/input/input33/event1" [238775.401] (II) XINPUT: Adding extended input device "HID 413c:8157" (type: KEYBOARD, id 11) [238775.402] (**) Option "xkb_rules" "evdev" [238775.402] (**) Option "xkb_model" "pc105" [238775.402] (**) Option "xkb_layout" "gb" [238775.402] (**) Option "xkb_options" "lv3:ralt_switch" [238775.402] (II) XKB: Reusing cached keymap But the XKB settings were not restored (whether before or after the RF_KILL bit was toggled). A third try, letting the RF_KILL bit always on to enable radio, i.e. before suspend and after wake up (resume). In the /var/log/syslog file: [...] Aug 10 22:21:34 xvii kernel: [239409.521324] input: AT Translated Set 2 keyboard as /devices/platform/i8042/serio0/input/input35 Aug 10 22:21:34 xvii kernel: [239409.564618] ata2.00: configured for UDMA/100 Aug 10 22:21:34 xvii kernel: [239409.572067] usb 3-1: reset full-speed USB device number 22 using uhci_hcd Aug 10 22:21:34 xvii kernel: [239410.009423] dell_wmi: Received unknown WMI event (0x11) Aug 10 22:21:34 xvii kernel: [239410.013989] usb 3-1.1: reset full-speed USB device number 23 using uhci_hcd Aug 10 22:21:34 xvii kernel: [239410.185946] usb 3-1.2: reset full-speed USB device number 24 using uhci_hcd [...] In the /var/log/Xorg.0.log file: [239412.722] (II) config/udev: Adding input device AT Translated Set 2 keyboard (/dev/input/event0) [239412.722] (**) AT Translated Set 2 keyboard: Applying InputClass "evdev keyboard catchall" [239412.722] (II) Using input driver 'evdev' for 'AT Translated Set 2 keyboard' [239412.722] Option "XkbRules" "evdev" [239412.722] Option "xkb_model" "pc105" [239412.722] Option "xkb_layout" "gb" [239412.722] Option "_source" "server/udev" [239412.722] Option "name" "AT Translated Set 2 keyboard" [239412.722] Option "path" "/dev/input/event0" [239412.722] Option "device" "/dev/input/event0" [239412.722] Option "xkb_options" "lv3:ralt_switch" [239412.722] Option "config_info" "udev:/sys/devices/platform/i8042/serio0/input/input35/event0" [239412.722] Option "driver" "evdev" [239412.722] (**) AT Translated Set 2 keyboard: always reports core events [239412.722] (**) evdev: AT Translated Set 2 keyboard: Device: "/dev/input/event0" [239412.722] (--) evdev: AT Translated Set 2 keyboard: Vendor 0x1 Product 0x1 [239412.722] (--) evdev: AT Translated Set 2 keyboard: Found keys [239412.722] (II) evdev: AT Translated Set 2 keyboard: Configuring as keyboard [239412.722] (**) Option "config_info" "udev:/sys/devices/platform/i8042/serio0/input/input35/event0" [239412.722] (II) XINPUT: Adding extended input device "AT Translated Set 2 keyboard" (type: KEYBOARD, id 11) [239412.722] (**) Option "xkb_rules" "evdev" [239412.722] (**) Option "xkb_model" "pc105" [239412.722] (**) Option "xkb_layout" "gb" [239412.722] (**) Option "xkb_options" "lv3:ralt_switch" [239412.722] (II) XKB: Reusing cached keymap [239412.755] (II) Open ACPI successful (/var/run/acpid.socket) [239412.755] (II) AIGLX: Resuming AIGLX clients after VT switch [239412.755] (II) NOUVEAU(0): NVEnterVT is called. [239412.896] (II) NOUVEAU(0): EDID vendor "AUO", prod id 16455 [239412.896] (II) NOUVEAU(0): Printing DDC gathered Modelines: [239412.896] (II) NOUVEAU(0): Modeline "1440x900"x0.0 108.00 1440 1504 1536 1970 900 903 906 912 +hsync -vsync (54.8 kHz eP) [239412.896] (II) NOUVEAU(0): Modeline "1440x900"x0.0 72.50 1440 1504 1536 1970 900 903 906 912 +hsync -vsync (36.8 kHz e) [239413.023] (**) Option "Device" "/dev/input/event10" [239413.023] (--) synaptics: AlpsPS/2 ALPS DualPoint TouchPad: touchpad found But the XKB settings were not restored. -- Vincent Lefèvre <vinc...@vinc17.net> - Web: <http://www.vinc17.net/> 100% accessible validated (X)HTML - Blog: <http://www.vinc17.net/blog/> Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon) -- To UNSUBSCRIBE, email to debian-x-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20120811003308.gb15...@xvii.vinc17.org