Unable to toggle Touchpad by keyboard shortcut

Bug #1813783 reported by Caroga on 2019-01-29
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)

Bug Description

Pressing Fn+F5 button should toggle the onboard touchpad. This seems not to work and might be related to the following bug:

After pressing Fn+F5 shows the following:
$ dmesg
[ 248.412826] atkbd serio0: Unknown key pressed (translated set 2, code 0xf8 on isa0060/serio0).
[ 248.412833] atkbd serio0: Use 'setkeycodes e078 <keycode>' to make it known.
[ 250.261108] atkbd serio0: Unknown key released (translated set 2, code 0xf8 on isa0060/serio0).
[ 250.261110] atkbd serio0: Use 'setkeycodes e078 <keycode>' to make it known.

I've added the mentioned kernel parameters as described in
https://wiki.ubuntu.com/DebuggingACPI (adding acpi=off)
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/717931/comments/21 (i8042.nomux=1)
but the problem still exists.

Touchpad also has a little dot in the upper left side which I assume also is for toggling on/off the touchpad. This is also unresponsive.

How reproducible:

Steps to Reproduce:
Press Fn+F5

Actual results:
Touchpad is not working

Expected results:
Touchpad should toggle on/off, making it able to use the touchpad.

Extra info:
Bios is up to date.

$ lsb_release -rd

Description: Ubuntu 18.04.1 LTS
Release: 18.04

$ inxi -F

System: Host: CarogaLaptopLinux Kernel: 4.15.0-43-generic x86_64 bits: 64 Desktop: Gnome 3.28.3
           Distro: Ubuntu 18.04.1 LTS
Machine: Device: laptop System: Standard product: Standard v: Standard serial: N/A
           Mobo: Standard model: Standard v: Standard serial: N/A
           UEFI: American Megatrends v: N.0.05 date: 04/14/2018
Battery BAT0: charge: 42.2 Wh 90.2% condition: 46.7/46.7 Wh (100%)
CPU: 6 core Intel Core i7-8750H (-MT-MCP-) cache: 9216 KB
           clock speeds: max: 4100 MHz 1: 1541 MHz 2: 2043 MHz 3: 2069 MHz 4: 2345 MHz 5: 2241 MHz 6: 2111 MHz
           7: 2080 MHz 8: 2047 MHz 9: 2035 MHz 10: 2388 MHz 11: 1879 MHz 12: 2175 MHz
Graphics: Card-1: Intel Device 3e9b
           Card-2: NVIDIA GP106M [GeForce GTX 1060 Mobile]
           Display Server: x11 (X.Org 1.19.6 ) drivers: modesetting,nvidia (unloaded: fbdev,vesa,nouveau)
           Resolution: 1920x1080@144.00hz
           OpenGL: renderer: Mesa DRI Intel HD Graphics (Coffeelake 3x8 GT2) version: 4.5 Mesa 18.0.5
Audio: Card Intel Device a348 driver: snd_hda_intel Sound: ALSA v: k4.15.0-43-generic
Network: Card-1: Intel Device a370 driver: iwlwifi
           IF: wlo1 state: up speed: N/A duplex: N/A mac: 94:b8:6d:fc:16:24
           Card-2: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller driver: r8169
           IF: enp4s0 state: down mac: b0:25:aa:29:17:57
Drives: HDD Total Size: 500.1GB (25.6% used)
           ID-1: /dev/nvme0n1 model: WDS500G2X0C size: 500.1GB
           ID-2: /dev/nvme1n1 model: WDS500G2X0C size: 500.1GB
Partition: ID-1: / size: 398G used: 61G (17%) fs: ext4 dev: /dev/nvme0n1p2
           ID-2: swap-1 size: 65.53GB used: 0.00GB (0%) fs: swap dev: /dev/nvme0n1p1
RAID: No RAID devices: /proc/mdstat, md_mod kernel module present
Sensors: System Temperatures: cpu: 55.0C mobo: 54.0C
           Fan Speeds (in rpm): cpu: N/A
Info: Processes: 387 Uptime: 16 min Memory: 3855.5/32027.2MB Client: Shell (zsh) inxi: 2.3.56

ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: linux-image-4.15.0-43-generic 4.15.0-43.46
ProcVersionSignature: Ubuntu 4.15.0-43.46-generic 4.15.18
Uname: Linux 4.15.0-43-generic x86_64
ApportVersion: 2.20.9-0ubuntu7.5
Architecture: amd64
 /dev/snd/pcmC0D0p: caroga 3523 F...m pulseaudio
 /dev/snd/controlC0: caroga 3523 F.... pulseaudio
CurrentDesktop: ubuntu:GNOME
Date: Tue Jan 29 16:04:41 2019
HibernationDevice: RESUME=UUID=8cafe715-f523-4099-8dd8-7f80c5de58d4
InstallationDate: Installed on 2018-08-17 (164 days ago)
InstallationMedia: Ubuntu 18.04.1 LTS "Bionic Beaver" - Release amd64 (20180725)
MachineType: Standard Standard
ProcFB: 0 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-4.15.0-43-generic root=UUID=e177b84e-a10b-4a4e-8d1c-8eeafbb021ba ro quiet splash i8042.nomux=1 vt.handoff=1
 linux-restricted-modules-4.15.0-43-generic N/A
 linux-backports-modules-4.15.0-43-generic N/A
 linux-firmware 1.173.3
SourcePackage: linux
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 04/14/2018
dmi.bios.vendor: American Megatrends Inc.
dmi.bios.version: N.0.05
dmi.board.asset.tag: Standard
dmi.board.name: Standard
dmi.board.vendor: Standard
dmi.board.version: Standard
dmi.chassis.asset.tag: Standard
dmi.chassis.type: 10
dmi.chassis.vendor: Standard
dmi.chassis.version: Standard
dmi.modalias: dmi:bvnAmericanMegatrendsInc.:bvrN.0.05:bd04/14/2018:svnStandard:pnStandard:pvrStandard:rvnStandard:rnStandard:rvrStandard:cvnStandard:ct10:cvrStandard:
dmi.product.family: CFL
dmi.product.name: Standard
dmi.product.version: Standard
dmi.sys.vendor: Standard

Caroga (caroga) wrote :

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
Caroga (caroga) wrote :

As per request of lotuspsychje I updated my kernel from 43 -> 44.
This does NOT make a difference, bug still there.

Kai-Heng Feng (kaihengfeng) wrote :

Does your system have a model name?

dmi.product.name: Standard
dmi.product.version: Standard
dmi.sys.vendor: Standard

Doesn't seem to help.

Caroga (caroga) wrote :

Hi Kai-Heng,

My system is a build to order product, this is the link from my supplier:

I have no branded laptop, or model name.

Kai-Heng Feng (kaihengfeng) wrote :

You need something similar to [1].
But since your system is "Standard" everything, and upstream systemd hwdb would be impossible.

[1] https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1605433/comments/39

Kai-Heng Feng (kaihengfeng) wrote :

For this case, the key will be "KEYBOARD_KEY_f8=f21".

Caroga (caroga) wrote :

Following the instructions of the file /lib/udev/hwdb.d/60-keyboard.hwdb I've created another file /etc/udev/hwdb.d/70-keyboard.hwdb.
From what I understand I need to place the configuration in there and reload the configuration.
I just would like to know under what segment I'd place this line? Or could I just place this at the bottom?
Also, the physical key I'm pressing is F5, I'm inclined to change the f8 to f5 in the configuration, would that be correct?

Caroga (caroga) wrote :

Reading through some documentation I've composed the following rules:

This is based on the following information:
ls -la /dev/input/by-path
total 0
drwxr-xr-x 2 root root 120 mrt 7 10:10 .
drwxr-xr-x 4 root root 440 mrt 7 10:10 ..
lrwxrwxrwx 1 root root 9 mrt 7 10:10 pci-0000:00:14.0-usb-0:12:1.0-event-mouse -> ../event7
lrwxrwxrwx 1 root root 9 mrt 7 10:10 pci-0000:00:14.0-usb-0:12:1.0-mouse -> ../mouse0
lrwxrwxrwx 1 root root 10 mrt 7 10:10 pci-0000:00:14.0-usb-0:13:1.0-event -> ../event15
lrwxrwxrwx 1 root root 9 mrt 7 10:10 platform-i8042-serio-0-event-kbd -> ../event4

sudo udevadm info /dev/input/event4
P: /devices/platform/i8042/serio0/input/input4/event4
N: input/event4
S: input/by-path/platform-i8042-serio-0-event-kbd
E: DEVLINKS=/dev/input/by-path/platform-i8042-serio-0-event-kbd
E: DEVNAME=/dev/input/event4
E: DEVPATH=/devices/platform/i8042/serio0/input/input4/event4
E: ID_BUS=i8042
E: ID_PATH=platform-i8042-serio-0
E: ID_PATH_TAG=platform-i8042-serio-0
E: ID_SERIAL=noserial
E: LIBINPUT_DEVICE_GROUP=11/1/1:isa0060/serio0
E: TAGS=:power-switch:

cat /sys/class/input/event4/device/id/bustype /sys/class/input/event4/device/id/product /sys/class/input/event4/device/id/vendor /sys/class/input/event4/device/id/version

I don't know if this is correct, but we will see soon enough.
Please correct me if my approach is wrong.

Caroga (caroga) wrote :

Above did not work, I'm now trying to find the correct configuration. I'm fairly certain that I've found the keyboard info such as brand and all but that I need to format it correctly.

Some more information I've found:
$ lshw
                   description: Keyboard
                   product: ITE Device(8291)
                   vendor: ITE Tech. Inc.
                   physical id: 6
                   bus info: usb@1:6
                   version: 0.03
                   capabilities: usb-2.00
                   configuration: driver=usbhid maxpower=100mA speed=12Mbit/s

$ lsusb

Bus 001 Device 003: ID 048d:ce00 Integrated Technology Express, Inc.

Kai-Heng Feng (kaihengfeng) wrote :

Something like:


And yes it's f8 not f5.

Caroga (caroga) wrote :

Hi Kay-Heng, sorry for the delay, I'm currently on the road a lot.

I added the above, which makes ubuntu display the big icon for disabling the touchpad when pressing only the Fn button.
I tried finding the correct modifier. Unsuccessful yet.

I thought that explicitly defining the Fn button as the "function button" would solve this, and yes.. The error is gone with the following config:


BUT this does NOT solve the key combination Fn+F5 to toggle my touchpad. Although other functions, like brightness controls (Fn+F11 and Fn+F12) and sound control (Fn+F8 for mute, Fn+F9 lower, Fn+F10 higher) all work, even without this configuration.

So nothing gained, yet.

I figured that finding the keycode for the combination of Fn+F5 would be the next step and this is what I've found so far

Without the extra configuration I've used showkey -k
keycode 125 press
keycode 29 press
keycode 85 press
keycode 85 release
keycode 29 release
keycode 125 release

Where the following is produced when I add the above configuration again:
keycode 464 press
keycode 125 press
keycode 29 press
keycode 85 press
keycode 85 release
keycode 29 release
keycode 125 release
keycode 464 release

Would this help in finding the correct modifier/configuration?

Caroga (caroga) wrote :

Results from running evtest:

Event: time 1552906643.406374, -------------- SYN_REPORT ------------
Event: time 1552906647.145300, type 4 (EV_MSC), code 4 (MSC_SCAN), value f8
Event: time 1552906647.145300, type 1 (EV_KEY), code 464 (KEY_FN), value 1
Event: time 1552906647.145300, -------------- SYN_REPORT ------------
Event: time 1552906648.612061, type 4 (EV_MSC), code 4 (MSC_SCAN), value db
Event: time 1552906648.612061, type 1 (EV_KEY), code 125 (KEY_LEFTMETA), value 1
Event: time 1552906648.612061, -------------- SYN_REPORT ------------
Event: time 1552906648.614695, type 4 (EV_MSC), code 4 (MSC_SCAN), value 1d
Event: time 1552906648.614695, type 1 (EV_KEY), code 29 (KEY_LEFTCTRL), value 1
Event: time 1552906648.614695, -------------- SYN_REPORT ------------
Event: time 1552906648.617376, type 4 (EV_MSC), code 4 (MSC_SCAN), value 76
Event: time 1552906648.617376, type 1 (EV_KEY), code 85 (KEY_ZENKAKUHANKAKU), value 1
Event: time 1552906648.617376, -------------- SYN_REPORT ------------
Event: time 1552906648.622650, type 4 (EV_MSC), code 4 (MSC_SCAN), value 76
Event: time 1552906648.622650, type 1 (EV_KEY), code 85 (KEY_ZENKAKUHANKAKU), value 0
Event: time 1552906648.622650, -------------- SYN_REPORT ------------
Event: time 1552906648.628730, type 4 (EV_MSC), code 4 (MSC_SCAN), value 1d
Event: time 1552906648.628730, type 1 (EV_KEY), code 29 (KEY_LEFTCTRL), value 0
Event: time 1552906648.628730, -------------- SYN_REPORT ------------
Event: time 1552906648.635209, type 4 (EV_MSC), code 4 (MSC_SCAN), value db
Event: time 1552906648.635209, type 1 (EV_KEY), code 125 (KEY_LEFTMETA), value 0
Event: time 1552906648.635209, -------------- SYN_REPORT ------------
Event: time 1552906650.199171, type 4 (EV_MSC), code 4 (MSC_SCAN), value 3f
Event: time 1552906650.199171, -------------- SYN_REPORT ------------
Event: time 1552906650.798437, type 4 (EV_MSC), code 4 (MSC_SCAN), value f8
Event: time 1552906650.798437, type 1 (EV_KEY), code 464 (KEY_FN), value 0
Event: time 1552906650.798437, -------------- SYN_REPORT ------------

Kai-Heng Feng (kaihengfeng) wrote :

So this shows when FN gets pressed, before F5?
[ 248.412826] atkbd serio0: Unknown key pressed (translated set 2, code 0xf8 on isa0060/serio0).
[ 248.412833] atkbd serio0: Use 'setkeycodes e078 <keycode>' to make it known.

Caroga (caroga) wrote :

Yes, the error only appears when pressing Function button only.

Kai-Heng Feng (kaihengfeng) wrote :

Try KEYBOARD_KEY_76=f21.

Caroga (caroga) wrote :

I've tried, no success. Is there any more information I could provide?

Kai-Heng Feng (kaihengfeng) wrote :

I am afraid not. The basic idea is to find the correct scan code of the hotkey, and map it in systemd's hwdb.

Caroga (caroga) wrote :

This bug is still unresolved, however my touchpad started working after last update. I've tried the hotkeys again but cannot seem to toggle it.

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

Other bug subscribers