Chrome OS: evdev does not properly send Alt+Search+1 key event to the userland |
||
Issue description(internal ARC bug: b/34050823) Reproduced with kernel 3.14 (samus beta channel) and 3.18. Haven't checked 4.4 What steps will reproduce the problem? 1. Open Google Docs (either web version or ARC app), create a new document, type something. 2. Remap Chrome OS' Search key to Ctrl 3. Press Search+Alt+1 to make the font larger What is the expected result? Since Search+Alt+1 is sent to Docs as Ctrl+Alt+1, the key press should change the font size. What happens instead of that? Nothing happens on Chrome/ARC side. Please note that Search+Alt+2, Search+Alt+3, ... _do_ work without any issues. Only Search+Alt+1 has the issue. I added some logging to Chrome's EventConverterEvdevImpl::ConvertKeyEvent() to see if Chrome was receiving a proper key event for "1", and it was not. For some reason, the kernel (evdev) sends "LeftMeta+repeated" when "1" is pressed. Here is evtest output: Search+Alt+2 (normal): Event: time 1490294421.121785, type 4 (EV_MSC), code 4 (MSC_SCAN), value db Event: time 1490294421.121785, type 1 (EV_KEY), code 125 (KEY_LEFTMETA), value 1 Event: time 1490294421.121785, -------------- SYN_REPORT ------------ Event: time 1490294421.127233, type 4 (EV_MSC), code 4 (MSC_SCAN), value 38 Event: time 1490294421.127233, type 1 (EV_KEY), code 56 (KEY_LEFTALT), value 1 Event: time 1490294421.127233, -------------- SYN_REPORT ------------ Event: time 1490294421.281096, type 4 (EV_MSC), code 4 (MSC_SCAN), value 03 Event: time 1490294421.281096, type 1 (EV_KEY), code 3 (KEY_2), value 1 Event: time 1490294421.281096, -------------- SYN_REPORT ------------ Event: time 1490294421.369309, type 4 (EV_MSC), code 4 (MSC_SCAN), value 03 Event: time 1490294421.369309, type 1 (EV_KEY), code 3 (KEY_2), value 0 Event: time 1490294421.369309, -------------- SYN_REPORT ------------ Event: time 1490294421.454084, type 4 (EV_MSC), code 4 (MSC_SCAN), value 38 Event: time 1490294421.454084, type 1 (EV_KEY), code 56 (KEY_LEFTALT), value 0 Event: time 1490294421.454084, -------------- SYN_REPORT ------------ Event: time 1490294421.488436, type 4 (EV_MSC), code 4 (MSC_SCAN), value db Event: time 1490294421.488436, type 1 (EV_KEY), code 125 (KEY_LEFTMETA), value 0 Event: time 1490294421.488436, -------------- SYN_REPORT ------------ Search+Alt+1: Event: time 1490294429.743632, type 4 (EV_MSC), code 4 (MSC_SCAN), value 38 Event: time 1490294429.743632, type 1 (EV_KEY), code 56 (KEY_LEFTALT), value 1 Event: time 1490294429.743632, -------------- SYN_REPORT ------------ Event: time 1490294429.783376, type 4 (EV_MSC), code 4 (MSC_SCAN), value db Event: time 1490294429.783376, type 1 (EV_KEY), code 125 (KEY_LEFTMETA), value 1 Event: time 1490294429.783376, -------------- SYN_REPORT ------------ Event: time 1490294430.033509, type 4 (EV_MSC), code 4 (MSC_SCAN), value db Event: time 1490294430.033509, type 1 (EV_KEY), code 125 (KEY_LEFTMETA), value 2 <---- unexpected Event: time 1490294430.033509, -------------- SYN_REPORT ------------ Event: time 1490294430.067280, type 4 (EV_MSC), code 4 (MSC_SCAN), value db Event: time 1490294430.067280, type 1 (EV_KEY), code 125 (KEY_LEFTMETA), value 2 <---- unexpected Event: time 1490294430.067280, -------------- SYN_REPORT ------------ Event: time 1490294430.101270, type 4 (EV_MSC), code 4 (MSC_SCAN), value db Event: time 1490294430.101270, type 1 (EV_KEY), code 125 (KEY_LEFTMETA), value 2 <---- unexpected Event: time 1490294430.101270, -------------- SYN_REPORT ------------ Event: time 1490294430.119608, type 4 (EV_MSC), code 4 (MSC_SCAN), value 38 Event: time 1490294430.119608, type 1 (EV_KEY), code 56 (KEY_LEFTALT), value 0 Event: time 1490294430.119608, -------------- SYN_REPORT ------------ Event: time 1490294430.125775, type 4 (EV_MSC), code 4 (MSC_SCAN), value db Event: time 1490294430.125775, type 1 (EV_KEY), code 125 (KEY_LEFTMETA), value 0 Event: time 1490294430.125775, -------------- SYN_REPORT ------------ I think either the kernel or EC is not handling Search+Alt+1 properly. gwendal@, could you triage?
,
Mar 23 2017
Per waihong@, assigning to rspangler@ for triage.
,
Mar 23 2017
This is a hardware limitation of the keyboard scan matrix. Search is (1,0) 1 is (1,6) RightAlt is (10,0) LeftAlt is (10,6) When any 3 of the keys are pressed, they electrically connect around the matrix to connect the 4th key. This is called "ghosting". The low-level keyboard scanning code detects the ghosting and stops sending keyboard events until any of the 3 keys is released. The normal control keys are at (0,2) and (0,4), and the shifts are at (7,5) and (7,7), and they and Alt are on sparsely-populated rows in the matrix. This way, Control, Alt, and Shift can be pressed in any combination with any other single key without making an L-shape connection on the keyboard matrix which causes ghosting. But Search doesn't have that special property on the keyboard scan matrix.
,
Mar 31 2017
|
||
►
Sign in to add a comment |
||
Comment 1 by victorhsieh@chromium.org
, Mar 23 2017Owner: rspangler@chromium.org