Summary: | libinput 1.6.2: touchpad detect for Razer Blade Pro (2016) | ||
---|---|---|---|
Product: | Wayland | Reporter: | ben simons <bsimons> |
Component: | libinput | Assignee: | Wayland bug list <wayland-bugs> |
Status: | RESOLVED NOTOURBUG | QA Contact: | |
Severity: | normal | ||
Priority: | medium | CC: | benjamin.tissoires, peter.hutterer |
Version: | unspecified | ||
Hardware: | x86-64 (AMD64) | ||
OS: | All | ||
See Also: | https://bugs.freedesktop.org/show_bug.cgi?id=101883 | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Attachments: |
Xorg.0.log
output from evemu-describe.txt Xorg.0.log output from libinput-debug-events output from evemu-record output from udevadm stderr output from running evemu-record ubuntu Xorg.0.log ubuntu udevadm ubuntu dmesg && lsmod i2c gentoo dmesg - pre-designware module install gentoo dmesg with i2c_hid dmesg with boot option i2c_hid.debug=1 another dmesg with i2c-hid debug=1 |
Description
ben simons
2017-03-12 02:53:01 UTC
Seems it's possible to set ID_INPUT_TOUCHPAD_INTEGRATION = external just using these rules to explore event8 /etc/udev/rules.d/50-Razer-touchpad.rules SUBSYSTEM=="input", KERNEL=="event8", ENV{ID_INPUT}="1" SUBSYSTEM=="input", KERNEL=="event8", ENV{ID_INPUT_TOUCHPAD}="1" SUBSYSTEM=="input", KERNEL=="event8", ENV{ID_INPUT_TOUCHPAD_INTEGRATION}="external" SUBSYSTEM=="input", KERNEL=="event8", ENV{ID_INPUT_KEYBOARD}="" then the question about internal / external goes away, but there's no input events seen when tapping/swiping on the trackpad. /home/ben # udevadm control --reload-rules ; udevadm trigger ; libinput-debug-events libinput error: kernel bug: device Razer Razer Blade Pro failed touchpad sanity checks -event3 DEVICE_ADDED Power Button seat0 default group1 cap:k -event9 DEVICE_ADDED Video Bus seat0 default group2 cap:k -event1 DEVICE_ADDED Power Button seat0 default group3 cap:k -event0 DEVICE_ADDED Sleep Button seat0 default group4 cap:k -event5 DEVICE_ADDED HID 1241:1111 seat0 default group5 cap:p left scroll-nat scroll-button -event11 DEVICE_ADDED ELAN Touchscreen seat0 default group6 cap:t size 284x172mm calib -event6 DEVICE_ADDED Razer Razer Blade Pro seat0 default group7 cap:k -event7 DEVICE_ADDED Razer Razer Blade Pro seat0 default group7 cap:kp scroll-nat -event12 DEVICE_ADDED USB Camera seat0 default group8 cap:k -event4 DEVICE_ADDED AT Raw Set 2 keyboard seat0 default group9 cap:k -event7 KEYBOARD_KEY +3.32s *** (-1) pressed event7 KEYBOARD_KEY +3.61s *** (-1) pressed ^C/home/ben # urgh, please attach long outputs as attachments, makes analysis a bit easier. first weird thing: udevadm doesn't show ID_INPUT_TOUCHPAD but the log claims it's tagged as touchpad. what's going on there? did you modify some rules but then attached a different udevadm output? That's the real bug here to fix, remove whatever assigns ID_INPUT_TOUCHPAD and the device should work as mouse. the internal/external bit should be added to the hwdb in systemd, see the instructions at the top of the file: https://github.com/systemd/systemd/blob/master/hwdb/70-touchpad.hwdb but first: this touchpad needs to be detected by the kernel correctly. Right now it's in relative mouse emulation mode. The touchpad needs to be switched to absolute mode, usually by sending the right initialization sequence from the kernel. Once that's done, the device should announce ABS_X/ABS_Y etc and then the rest should fall into place. If it works under Ubuntu, try their kernel and then get them to upstream the patches if it truly works. Otherwise, quick email search suggests https://patchwork.kernel.org/patch/5596041/ as a place to start kernel hacking. There's a chance that the new device is still a synaptics one and that it's hooked up the same way. CC-ing benjamin just in case he knows more. Created attachment 130181 [details]
Xorg.0.log
Created attachment 130182 [details]
output from evemu-describe.txt
Created attachment 130183 [details]
Xorg.0.log
Created attachment 130184 [details]
output from libinput-debug-events
Created attachment 130185 [details]
output from evemu-record
Created attachment 130186 [details]
output from udevadm
Created attachment 130187 [details]
stderr output from running evemu-record
Apologies for the logs! Yes, there was still a udev rule attempting to set ID_INPUT_TOUCHPAD. ouch. Sorry. My bad. For the record, new logs attached. Touchpad currently does not send any events (doesn't work) Thought the 'external' setting made sense as the touchpad is off to the right of the keyboard, away from hands at keyboard, however it is internal to the laptop. ? The touchpad is a Cirque Glidepoint Thanks for the suggestions. Will follow them up. I've seen this bug report (though mine does not even function as a mouse) https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1648259 Comment on attachment 130183 [details]
Xorg.0.log
whoops. duplicate attachment.
oh, interesting. I was looking at the Razer Blade before, not the Pro. That's fixable though, we'd have to add another tag for this though. We already have "LIBINPUT_ATTR_TPKBCOMBO_LAYOUT=below" for touchpad+keyboard combo devices and could easily adjust that one. there are a couple of things we used the tag for, and for some of the use-cases internal applies, so the internal/external labelling still applies for this device. Either way, before we add code for that in libinput let's make sure the device works correctly. Once it does, please open another bug for libinput to tag the device correctly. From the launchpad bug you attached, the touchpad seems to be connected over I2C. While on this bug, you only have USB devices reported. Could you check if i2c-hid is correctly loaded and if nothing shows up in the dmesg? (Hint: attach also the full dmesg here :-P ) Created attachment 130191 [details]
ubuntu Xorg.0.log
Created attachment 130192 [details]
ubuntu udevadm
Created attachment 130193 [details]
ubuntu dmesg && lsmod i2c
Hi Thanks for the help. Let me know what else to do.. I found a version of ubuntu, installed it on a USB stick, and am writing this booted into it. 3 new attachments attached. The cursor is stuck in the top right corner and does not move. The touchpad DOES do something!!! I can make empty selection boxes in the desktop background. Though it's hard to know where the mouse is, as the cursor remains stuck in the top-left corner all the time. The ELAN touchscreen works, which is how i can work with it. The USB remote mouse works. I think the touchpad is 'mouse3'. Note xinput now reports CRQ1001 buntu@ubuntu:/$ xinput ⎡ Virtual core pointer id=2 [master pointer (3)] ⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)] ⎜ ↳ ELAN Touchscreen id=11 [slave pointer (2)] ⎜ ↳ Razer Razer Blade Pro id=13 [slave pointer (2)] ⎜ ↳ Razer Razer Blade Pro id=14 [slave pointer (2)] ⎜ ↳ CRQ1001:00 0488:D020 id=16 [slave pointer (2)] ⎜ ↳ HID 1241:1111 id=10 [slave pointer (2)] ⎣ Virtual core keyboard id=3 [master keyboard (2)] ↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)] ↳ Power Button id=6 [slave keyboard (3)] ↳ Video Bus id=7 [slave keyboard (3)] ↳ Power Button id=8 [slave keyboard (3)] ↳ Sleep Button id=9 [slave keyboard (3)] ↳ Razer Razer Blade Pro id=12 [slave keyboard (3)] ↳ USB Camera id=15 [slave keyboard (3)] ↳ AT Raw Set 2 keyboard id=17 [slave keyboard (3)] ubuntu dmesg etc see attached. Will reboot into Gentoo and attach a full dmesg from there next. Rebooted back into gentoo. Note ubuntu i2c modules showed: $ lsmod | grep i2c i2c_designware_platform 16384 0 i2c_designware_core 20480 1 i2c_designware_platform i2c_algo_bit 16384 1 nouveau i2c_hid 20480 0 hid 118784 4 i2c_hid,hid_generic,usbhid,hid_multitouch on gentoo i have: /home/ben # lsmod|grep i2c i2c_i801 24576 0 i2c_smbus 16384 1 i2c_i801 i2c_algo_bit 16384 2 nvidiafb,igb Hmm. soething's missing? /usr/src/linux # grep -i design /usr/src/linux/.config # CONFIG_I2C_DESIGNWARE_PLATFORM is not set # CONFIG_I2C_DESIGNWARE_PCI is not set Hows about i add i2c_designware_platform as a module and report back? current dmesg will be attached as "dmesg.pre-designware" Created attachment 130194 [details]
gentoo dmesg - pre-designware module install
re-read benjamins comment while waiting for genkernel. i2c_hid!! <cough> will add i2c_hid too. ^C Created attachment 130195 [details]
gentoo dmesg with i2c_hid
Under Gentoo, the touchpad must be enumerated, but nothing shows up. The touchpad should be supported by hid-generic as the VID/PID is not assigned a specific driver (which also explains why the touchpad doesn't work). Anyway, could you attach the dmesg while booting with i2c_hid.debug=1 appended to the kernel boot line in grub? Created attachment 130196 [details]
dmesg with boot option i2c_hid.debug=1
Not sure this dmesg is any different. I added "i2c_hid.debug=1" to the variable GRUB_CMDLINE_LINUX in /etc/default/grub, then ran grub-update and rebooted.. Is there an i2c_debug kernel setting i should first enable? will look..
(In reply to ben simons from comment #23) > Not sure this dmesg is any different. I added "i2c_hid.debug=1" to the > variable GRUB_CMDLINE_LINUX in /etc/default/grub, then ran grub-update and > rebooted.. Is there an i2c_debug kernel setting i should first enable? will > look.. Weird. You can also simply rmmod i2c-hid and then run modprobe i2c-hid debug=1. If nothing shows up, that means that the device is not enumerated through ACPI, and that would be strange. Created attachment 130197 [details]
another dmesg with i2c-hid debug=1
Heya. Yes, i don't see any real difference in this dmesg. Take a look though. I went back into the kernel and also added options:
[*] I2C Core debugging messages
[*] I2C Algorithm debugging messages
[*] I2C Bus debugging messages
in case that helped. Also did the suggested rmmod i2c_hid, which you will see posted at the end of the dmesg. the "re" insmod of i2c doesn't cause a rediscovery of devices, it seems.
I note one of the "Razer Razer Blade Pro" entries has moved to Virtual core keyboard now. All 3 were in core pointer.
/home/ben # xinput
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ HID 1241:1111 id=10 [slave pointer (2)]
⎜ ↳ ELAN Touchscreen id=11 [slave pointer (2)]
⎜ ↳ Razer Razer Blade Pro id=13 [slave pointer (2)]
⎜ ↳ Razer Razer Blade Pro id=14 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ Power Button id=6 [slave keyboard (3)]
↳ Video Bus id=7 [slave keyboard (3)]
↳ Power Button id=8 [slave keyboard (3)]
↳ Sleep Button id=9 [slave keyboard (3)]
↳ Razer Razer Blade Pro id=12 [slave keyboard (3)]
↳ USB Camera id=15 [slave keyboard (3)]
↳ AT Raw Set 2 keyboard id=16 [slave keyboard (3)]
↳ Razer Razer Blade Pro id=17 [slave keyboard (3)]
Is this something we could open up again? At the moment the status is: Resolved, Not our Bug. Alternately, is there someone upstream to be notified? it's a kernel bug. Feel free to continue discussing this here but it cannot be fixed in libinput. And moving to the kernel bugzilla/lkml may help fixing this faster. Anyway, if the ubuntu kernel detects and enumerates the touchpad, there must be a fix somewhere. So you should probably try to get the same upstream version ubuntu uses and grab their .config. Re-compile it under gentoo, and see how it goes. If the touchpad appears, then compare the 2 config files to see if anything obvious appears. If the 2 config files are equivalent, they have a specific patch and you should ask them to push it upstream. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.