Bug 45354 - XFree XInput device bug (patch included)
Summary: XFree XInput device bug (patch included)
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: XFree86   
(Show other bugs)
Version: 7.1
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Mike A. Harris
QA Contact: David Lawrence
Depends On:
TreeView+ depends on / blocked
Reported: 2001-06-21 14:10 UTC by Joe Krahn
Modified: 2007-04-18 16:33 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-06-21 14:10:57 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Joe Krahn 2001-06-21 14:10:52 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.76 [en] (X11; U; Linux 2.4.2-SGI_XFS_1.0 i686)

Description of problem:
XFree86 internal XInput calls does not correctly process device valuator
data that does not report starting from valuator 0. Most XInput devices
report all valuators from 0, and are not affected. I have created/updated 3
XInput devices that are affected, in particular the SGI 8-knob dialbox.

Fortunately, the fix is simple. Please add the patch to the next XFree86
release so that I can distribute the new (beta) XInput drivers. See the
patch in Additional Info. section. (Bug has been reported to XFree86 as

How reproducible:

Steps to Reproduce:
Install an XInput device that reports valuators staring other than zero. (I
don't think any of the current 4.x supported drivers do this)

Actual Results:  Running: xinput test dial+buttons, all knobs report as
valuator 0.

Expected Results:  XEvents should report valuators 0-7.

Additional info:

PATCH for 4.1.0 source (4.0.3 source is identical)

*** xc/programs/Xserver/hw/xfree86/common/xf86Xinput.c.orig     Tue Jun 19
13:55:17 2001
--- xc/programs/Xserver/hw/xfree86/common/xf86Xinput.c.new      Tue Jun 19
13:55:17 2001
*** 931,937 ****
      va_start(var, num_valuators);
!     loop_start = 0;
      for(loop=0; loop<num_valuators; loop++) {
        valuator[loop%6] = va_arg(var,int);
--- 931,937 ----
      va_start(var, num_valuators);
!     loop_start = first_valuator;
      for(loop=0; loop<num_valuators; loop++) {
        valuator[loop%6] = va_arg(var,int);
*** 1074,1080 ****
                    axisvals[1] = y;
!           loop_start = loop + 1;
--- 1074,1080 ----
                    axisvals[1] = y;
!           loop_start += 6;

Comment 1 Mike A. Harris 2001-07-13 01:39:09 UTC
I appreciate your patch, and your efforts of submitting it to us, however
Xinput drivers are not an area I'm familiar enough with to feel confident
that this enhancement is non-intrusive.  Also, I do not want our release to be
incompatible in any way to XFree86 sources in significant ways wherever
possible.  As such I would much rather wait until the patch is accepted
into the main XFree86 codebase, then I can pick up the patches when I
code merge with XFree86 xf-4_1-branch, or if it is in head CVS, when I
pick up the next release of XFree86.

Thanks again however for your submission.

Note You need to log in before you can comment on or make changes to this bug.