Bug 113481

Summary: Touchscreen no longer works on ASUS T100-CHI - Regression
Product: Drivers Reporter: jbMacAZ (jbMacBrodie)
Component: Input DevicesAssignee: drivers_input-devices
Status: RESOLVED CODE_FIX    
Severity: blocking CC: benjamin.tissoires, dmitry.torokhov
Priority: P1    
Hardware: Intel   
OS: Linux   
Kernel Version: 4.3.6 - 4.5-rc6 Subsystem:
Regression: Yes Bisected commit-id:
Attachments: hid-recorder log
0001-HID-multitouch-force-retrieving-of-Win8-signature-bl.patch
HID-recorder patched output

Description jbMacAZ 2016-03-01 03:27:16 UTC
Touchscreen stopped working as of version 4.4-rc1.  Two commits for elantech hid-multitouch when restores touchscreen operation.  The touchscreen has been working since before 4.0 versions until 4.3.6.  Backport from 4.4.x to 4.3.6 allowed me to "bisect" this vexing problem.  Manjaro(Arch) kernels started working again at 4.4-rc8 for unknown reasons but reverting these commits in Manjaro is harmless for the CHI .

Please adjust the commits to work with T100-CHI or revoke them


CHI uses Synaptic touchscreen unlike some of the other Asus T100 models.
Comment 1 jbMacAZ 2016-03-01 03:30:47 UTC
Commit ID's
fee906f035f0bd18ff12d84d58766c44a2ab0918
1c141a118520e7a61a6f189164f07c512b828dea
reverting these commits restores touchscreen operation on the Asus T100-CHI
Comment 2 jbMacAZ 2016-03-02 06:18:05 UTC
Reviewing my original post, it was not clear that I was reporting debian style kernels.  Versions 4.3.6, 4.4.x and 4.5-rcx do support the CHI touchscreen unless I revert the elantech hid_multitouch commits.  Manjaro(Arch based) kernel versions 4.4-rcx also had the same touchscreen problem until rc8.  I do not know how it was fixed in Manjaro.

FWIW the T100-CHI tech spec claims it can support 10 point multi-touch, which is 9 more than I need.
Comment 3 jbMacAZ 2016-03-02 06:26:56 UTC
This bug system needs editing capability (10 minute time limit??).

 (In reply to jbMacAZ from comment #2)
> Reviewing my original post, it was not clear that I was reporting debian
> style kernels.  Versions 4.3.6, 4.4.x and 4.5-rcx do
    - NOT - 
> support the CHI touchscreen unless I revert the elantech hid_multitouch 
> commits.
Comment 4 Benjamin Tissoires 2016-03-02 08:44:51 UTC
(In reply to jbMacAZ from comment #1)
> Commit ID's
> fee906f035f0bd18ff12d84d58766c44a2ab0918
This commit is in the linux-4.3.y branch -> commit 6d4f5440a3a2bb2e9d0d582bbf98234e9e9bb095 upstream.

> 1c141a118520e7a61a6f189164f07c512b828dea
idem -> commit 73e7d63efb4d774883a338997943bfa59e127085 upstream.

> reverting these commits restores touchscreen operation on the Asus T100-CHI

OK, so if I understand, you have a Synaptics touchscreen which doesn't work because stable backported those two commits.

If so, can you provide a hid-recording (project hid-replay[1]) of your device while making few inputs on the screen. This way, I will have a better idea of why this doesn't work.

[1] http://bentiss.github.io/hid-replay-docs/
Comment 5 jbMacAZ 2016-03-02 19:29:54 UTC
The event recorder does not see any events with 4.3.6.  The --debugfs option made no difference.  The recorder does see events when I revert the elantech commits.  I can post an event file for that case if that would help.

HID-recorder shows the device as /dev/hidraw4: SYNA7508:00 06CB:11E5 With the --debugfs it shifts to /sys/kernel/debug/hid/0018:06CB:11E5.0005/events.  The lsmod | grep hid is the same for the working and non-working cases.

Other misc info:  CHI has HDPI (1920x1200 pixels) and also supports an active sylus (with commits reverted!)  

My guess is that the original code masked a 3rd bug (initialization probably) that by dumb luck worked for the synaptics touchscreen.  Other Asus T100 models (TA/TAF/TAS/TAM) work fine with or without the elantech commits.  They use various brands of typical pixel count touch/screens.
Comment 6 Benjamin Tissoires 2016-03-02 19:44:41 UTC
I am actually more interested in the static part of the recording. Please attach the log anyway (with or without the events).
Comment 7 jbMacAZ 2016-03-02 23:12:40 UTC
Created attachment 206681 [details]
hid-recorder log

Attached is the hid-recorder output from kernel 4.3.6 (no events recorded).
Comment 8 Benjamin Tissoires 2016-03-04 16:29:19 UTC
Created attachment 207641 [details]
0001-HID-multitouch-force-retrieving-of-Win8-signature-bl.patch

Long shot: 6d4f5440a3 disables the retrieving of all feature reports when we detect a Win 8 certified touchscreen. We should be close enough to what the Windows driver does in Linux. The weird part is that your device does not present any fancy feature reports that would be checked by the Windows driver besides the hardware quality assurance blob.

Let's try to fetch this blob at probe and see if this enables the device. If this doesn't work, we will have to add a specific quirk for your device, which I am not particularly found of.
Comment 9 jbMacAZ 2016-03-04 20:40:29 UTC
Created attachment 207671 [details]
HID-recorder patched output

I want to double check my build, but the patch appears to be successful.  Both the touchscreen and the active stylus work as expected.  I've posted another hid-recording from 4.3.6 w/ your patch.  Since 4.3 is EOL, I'll try the patch on 4.4.4 (Ubuntu i386).  I'll also try it over on Manjaro(x86_64) to make sure nothing obvious broke over on the ARCH side.  That will probably take the rest of the afternoon.

Appreciate the help so far.
Comment 10 jbMacAZ 2016-03-05 01:26:58 UTC
Manjaro15.10_x86_64 and Ubuntu15.10_i386 both work fine with the elantech commits restored and the 0001-HID-multi...patch added to their respective 4.4.4 custom kernels for ASUS T100-CHI with Synaptic HDPI touchscreen.

If you need an alternate patch tested, let me know.  What happens next to this patch?

Thanks again for your help.
Comment 11 Benjamin Tissoires 2016-03-05 07:55:18 UTC
Thanks for the tests.

(In reply to jbMacAZ from comment #10)
> If you need an alternate patch tested, let me know.

That should be fine now :)

> What happens next to this patch?

I'll submit it upstream and request it to be backported to stable (given the regression). There should be no more actions needed from you now.
Comment 12 jbMacAZ 2016-03-09 20:53:07 UTC
Resolved pending upstream acceptance!
Comment 13 Benjamin Tissoires 2016-03-10 12:52:45 UTC
(In reply to jbMacAZ from comment #12)
> Resolved pending upstream acceptance!

Well, it's already accepted: https://git.kernel.org/cgit/linux/kernel/git/jikos/hid.git/commit/?h=for-4.6/multitouch&id=45c5c6828214605eaefa6755c47bd1a2c7eb203e

It will be in Linus' tree during the next opening window (and backported to stable soon after).
Comment 14 jbMacAZ 2016-03-10 18:14:30 UTC
Excellent.  Thank you so much - I'll look for the fix starting with linux-4.6.