[Wayland-bugs] [Bug 91563] libinput keep open motion sensor input device
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Mon Aug 31 04:55:31 PDT 2015
https://bugs.freedesktop.org/show_bug.cgi?id=91563
--- Comment #6 from Matthieu Gautier <dev at mgautier.fr> ---
Created attachment 118007
--> https://bugs.freedesktop.org/attachment.cgi?id=118007&action=edit
patch to add to linux tree, to add INPUT_PROP_ACCELEROMETER
Sorry for my silence but, as said Bastien, I was away.
(And, as I'm leaving again, I'll be silent for the next few weeks..)
Indeed, the tag INPUT_PROP_ACCELEROMETER is missing in applesmc. Adding it [1]
doesn't fix the problem. It shows that it is more complex that it seems ...
With the tag INPUT_PROP_ACCELEROMETER, a recent systemd version (>219, the
fedora22 version[2]) properly add the udev ID_INPUT_ACCELEROMETER=1 tag.
With this tag, libinput still open the device. However, it seems to be the
right thing to do. Gnome(-shell?) now detect the device is a accelerometer and
display a button to deactivate screen rotation, so we should keep the device
open.
So I've add a custom udev rules to remove the udev ID_INPUT (and
ID_INPUT_ACCELEROMETER) tag:
SUBSYSTEM=="input" ATTRS{properties}=="40" ENV{ID_INPUT}=""
ENV{ID_INPUT_ACCELEROMETER}=""
Without a ID_INPUT, libinput should ignore the device, but.. it doesn't.
The device is still open, but it seems to be never closed.
Each time, I go back to gdm (close user session), the device is open one more
time. lsof report each time that the gnome-shell process open N time the same
device.
I have still not found why. Once I'll go back, I'll investigate this again.
[1] I haven't submit my patch to kernel, but just apply the attached patch to
linux tree if you what to test.
[2] If you what to test with 219 systemd version, you can add a custom rules to
add the ID_INPUT_ACCELEROMETER yourself :
SUBSYSTEM=="input" ATTRS{properties}=="40" ENV{ID_INPUT_ACCELEROMETER}="1"
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/wayland-bugs/attachments/20150831/d37f82ad/attachment-0001.html>
More information about the wayland-bugs
mailing list