Bug 137190 - [usb8][patch] inhibit spurious button releases for some complex mices
Summary: [usb8][patch] inhibit spurious button releases for some complex mices
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: usb (show other bugs)
Version: 8.0-BETA2
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-usb (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-27 21:00 UTC by Eygene Ryabinkin
Modified: 2017-12-31 22:34 UTC (History)
0 users

See Also:


Attachments
0007-ums-avoid-spurious-button-releases-for-complex-mices.patch (5.50 KB, patch)
2009-07-27 21:00 UTC, Eygene Ryabinkin
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eygene Ryabinkin 2009-07-27 21:00:10 UTC
My Microsoft Wireless Laser Mouse 5000 shows weird behaviour when I do
press some button and trying to select the text inside the terminal
moving the pointer: looks like extra button press/release events are
generated.  Running 'xev' I see such events in the utility's output.

Fix: The problem is that this mice is "complex": it has other output descriptors
whose output also goes to the ums(4) driver.  It produces no data that will
be consumed by the driver, but due to the logics of the callback function,
variable 'buttons' will be different from the initial softc's button state
of some button was physically pressed when this "foreign" data comes.

The following patch makes ums(4) to be resistant to such callback input.
How-To-Repeat: 
Get the mentioned mice and try to select some text in the terminal:
you'll likely won't be able to select everything you want.
Comment 1 Hans Petter Selasky freebsd_committer 2009-07-27 21:43:38 UTC
On Monday 27 July 2009 21:58:03 Eygene Ryabinkin wrote:
> The problem is that this mice is "complex": it has other output descriptors
> whose output also goes to the ums(4) driver.  It produces no data that will
> be consumed by the driver, but due to the logics of the callback function,
> variable 'buttons' will be different from the initial softc's button state
> of some button was physically pressed when this "foreign" data comes.
>
> The following patch makes ums(4) to be resistant to such callback input.

For multi descriptor mouse devices, please try this patch and report back.

http://perforce.freebsd.org/chv.cgi?CH=166592
http://perforce.freebsd.org/chv.cgi?CH=166590

Download the latest version from USB P4	and report back.

--HPS
Comment 2 Mark Linimon freebsd_committer freebsd_triage 2010-02-08 12:54:50 UTC
State Changed
From-To: open->feedback

To submitter: did the patch work for you?
Comment 3 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 08:00:10 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped