After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 755849 - evdev: Recycle device ids after devices are removed
evdev: Recycle device ids after devices are removed
Status: RESOLVED FIXED
Product: clutter
Classification: Platform
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: clutter-maint
clutter-maint
Depends on:
Blocks:
 
 
Reported: 2015-09-30 06:31 UTC by Jonas Ådahl
Modified: 2016-02-16 11:05 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
evdev: Recycle device ids after devices are removed (8.10 KB, patch)
2015-09-30 06:31 UTC, Jonas Ådahl
committed Details | Review

Description Jonas Ådahl 2015-09-30 06:31:33 UTC
This patch fixes an issue in mutter where the ID is assumed to be lower than 255. We may reach device-id 255 quite fast if one does a lot of VT switches as we'd increase the device ID counter by N (where N is the number of input devices) for every VT switch. We could also probably change the assumptions made in mutter, but I figured it'd make sense to not constantly grow the device-id in clutter as well.
Comment 1 Jonas Ådahl 2015-09-30 06:31:36 UTC
Created attachment 312396 [details] [review]
evdev: Recycle device ids after devices are removed

In order to not grow the device id number forever, recycle the ids
whenever a device is released.
Comment 2 Jonas Ådahl 2015-12-23 07:58:21 UTC
Any objections to this, or should mutter (MetaIdleMonitor to be specific) be changed to be less picky about the range of possible IDs?
Comment 3 Jonas Ådahl 2016-02-16 11:03:31 UTC
Attachment 312396 [details] pushed as a102005 - evdev: Recycle device ids after devices are removed
Comment 4 Jonas Ådahl 2016-02-16 11:05:57 UTC
Happened to push this by accident since it was on my relative pointer branch. I'll leave it in anyway, since it fixes real issues. Please revert if it seems like a bad idea.