With the 4.19.4 kernel I keep getting input events from what i suspect is the lid sensor, which for some reason results in it spamming a "+" character in lightdm a lot. This makes it really hard to enter a password. Once in xorg everything keeps quiet though.
evtest /dev/input/event2
Input driver version is 1.0.1 Input device ID: bus 0x19 vendor 0x1 product 0x1 version 0x100 Input device name: "pyra-lid-wakeup" Supported events: Event type 0 (Sync) Event type 1 (Key) Event code 240 (Unknown) Event type 5 (?) Event code 0 (?) Testing ... (interrupt to exit) Event: time 1544296796.517339, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296796.517339, -------------- Report Sync ------------ Event: time 1544296796.540137, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296796.540137, -------------- Report Sync ------------ Event: time 1544296796.647227, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296796.647227, -------------- Report Sync ------------ Event: time 1544296796.688460, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296796.688460, -------------- Report Sync ------------ Event: time 1544296796.868398, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296796.868398, -------------- Report Sync ------------ Event: time 1544296796.876633, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296796.876633, -------------- Report Sync ------------ Event: time 1544296797.067187, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296797.067187, -------------- Report Sync ------------ Event: time 1544296797.091308, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296797.091308, -------------- Report Sync ------------
Hi,
Am 08.12.2018 um 20:30 schrieb aTc atc@k-n-p.org:
With the 4.19.4 kernel I keep getting input events from what i suspect is the lid sensor, which for some reason results in it spamming a "+" character in lightdm a lot. This makes it really hard to enter a password. Once in xorg everything keeps quiet though.
evtest /dev/input/event2
Input driver version is 1.0.1 Input device ID: bus 0x19 vendor 0x1 product 0x1 version 0x100 Input device name: "pyra-lid-wakeup" Supported events: Event type 0 (Sync) Event type 1 (Key) Event code 240 (Unknown) Event type 5 (?)
event type 5 is an EV_SW (switch).
https://elixir.bootlin.com/linux/v4.19.4/source/include/uapi/linux/input-eve...
So it should never be treated as a key event by user-space but I have no idea why it is.
Event code 0 (?) Testing ... (interrupt to exit) Event: time 1544296796.517339, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296796.517339, -------------- Report Sync ------------ Event: time 1544296796.540137, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296796.540137, -------------- Report Sync ------------ Event: time 1544296796.647227, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296796.647227, -------------- Report Sync ------------ Event: time 1544296796.688460, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296796.688460, -------------- Report Sync ------------ Event: time 1544296796.868398, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296796.868398, -------------- Report Sync ------------ Event: time 1544296796.876633, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296796.876633, -------------- Report Sync ------------ Event: time 1544296797.067187, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296797.067187, -------------- Report Sync ------------ Event: time 1544296797.091308, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296797.091308, -------------- Report Sync ------------
Hm. That is quite unexpected. Are you opening and closing the Pyra within 10 ms? More likely is some noise on the sensor or a broken pull-up.
Is my memory right that you have an older Pyra prototype? Which .dtb file is loaded?
BR and thanks, Nikolaus
Am 08.12.2018 um 21:24 schrieb H. Nikolaus Schaller hns@goldelico.com:
Hi,
Am 08.12.2018 um 20:30 schrieb aTc atc@k-n-p.org:
With the 4.19.4 kernel I keep getting input events from what i suspect is the lid sensor, which for some reason results in it spamming a "+" character in lightdm a lot. This makes it really hard to enter a password. Once in xorg everything keeps quiet though.
evtest /dev/input/event2
Input driver version is 1.0.1 Input device ID: bus 0x19 vendor 0x1 product 0x1 version 0x100 Input device name: "pyra-lid-wakeup" Supported events: Event type 0 (Sync) Event type 1 (Key) Event code 240 (Unknown) Event type 5 (?)
event type 5 is an EV_SW (switch).
https://elixir.bootlin.com/linux/v4.19.4/source/include/uapi/linux/input-eve...
So it should never be treated as a key event by user-space but I have no idea why it is.
Event code 0 (?) Testing ... (interrupt to exit) Event: time 1544296796.517339, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296796.517339, -------------- Report Sync ------------ Event: time 1544296796.540137, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296796.540137, -------------- Report Sync ------------ Event: time 1544296796.647227, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296796.647227, -------------- Report Sync ------------ Event: time 1544296796.688460, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296796.688460, -------------- Report Sync ------------ Event: time 1544296796.868398, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296796.868398, -------------- Report Sync ------------ Event: time 1544296796.876633, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296796.876633, -------------- Report Sync ------------ Event: time 1544296797.067187, type 1 (Key), code 240 (Unknown), value 1 Event: time 1544296797.067187, -------------- Report Sync ------------ Event: time 1544296797.091308, type 1 (Key), code 240 (Unknown), value 0 Event: time 1544296797.091308, -------------- Report Sync ------------
Hm. That is quite unexpected. Are you opening and closing the Pyra within 10 ms? More likely is some noise on the sensor or a broken pull-up.
Is my memory right that you have an older Pyra prototype? Which .dtb file is loaded?
I have checked and there are no differences betweeen board versions.
pyra-lid-wakeup { compatible = "gpio-keys";
pinctrl-names = "default"; pinctrl-0 = <&lid_pin &wwan_pins>;
#address-cells = <2>; #size-cells = <0>;
wwan_wakeup { label = "WWAN Wakeup"; linux,code = <KEY_UNKNOWN>; gpios = <&gpio1 15 GPIO_ACTIVE_HIGH>; /* gpio1_wk15 */ gpio-key,wakeup; /* debounce-interval */ };
display_lid { label = "Display Lid"; linux,input-type = <EV_SW>; linux,code = <SW_LID>; gpios = <&gpio1 6 GPIO_ACTIVE_HIGH>; /* gpio1_wk6 */ gpio-key,wakeup; };
};
So there is a mix between the WWAN Wakeup and the LID sensor in this event driver.
It should report an UNKNOWN KEY (240) if there is an incoming SMS or a call ringing reported from the Modem. And a SWITCH event with code 0x00 (SW_LID).
So the above keyboard events type Key and code 240 come from the Modem!
BTW: does the lid sensor work if you apply a magnet?
evtest --query /dev/input/event2 EV_SW 0 && echo on || echo off
BR, Nikolaus