A few days ago, my mouse button releases began sometimes not being recognised when I release two of the buttons simultaneously. The logical state of one button therefore gets stuck on "down", causing annoying unintended actions until I press it again to reset it.
I could reproduce the issue monitoring mouse events in xev
(output sometimes doesn't show expected key release events). I could not reproduce the issue by monitoring events in /sys/kernel/debug/usb/usbmon
(output is always consistent with reality).
So the fault clearly lies with a software component at some abstraction below X11, but above USB.
What could be causing this? How could I narrow this down further?