[PATCH xf86-input-synaptics 1/2] Revert "Replace the motion estimator"

Peter Hutterer peter.hutterer at who-t.net
Wed Feb 8 14:19:45 PST 2012


On Wed, Feb 08, 2012 at 03:45:26PM -0600, Derek Foreman wrote:
> On 02/08/2012 08:42 AM, Peter Hutterer wrote:
> >On Tue, Feb 07, 2012 at 01:07:07PM -0800, Chase Douglas wrote:
> >>The algorithm is completely wrong because it uses subtraction of
> >>unsigned variables. The negative effects of this commit manifest in
> >>cursor warps to edges or corners of the screen.
> >>
> >>Since the algorithm has never worked right, previous testing must be
> >>disregarded. Revert it until we have a tested algorithm.
> >>
> >>This reverts commit b26125e412a130b7a8f8b6adf9ffc8e9cc8df42c.
> >>
> >>Conflicts:
> >>
> >>	src/synaptics.c
> >>
> >>Signed-off-by: Chase Douglas<chase.douglas at canonical.com>
> >
> >verified, tm is always garbage and so is t in the same hunk. Swapping the
> >first to HIST_DELTA(0, i, millis) seems to do something (slowing down the
> >cursor, mainly) but I didn't look into it further.
> >Applied, commit is reverted, thanks.
> >
> >    141d912..49f6109  master ->  master
> >
> >Derek, any comments?
> 
> Somebody please hand me a brown paper bag.  :(
> 
> This patch was a cherry-pick from a larger body of work that made
> more invasive changes to the motion history stuff... it missed some
> fix-ups the later work provided.
> 
> All callers of HIST_DELTA() within regress() have their first two
> parameters reversed.  Additionally, the calculation of *dx and *dy
> have hw->millis and start_time reversed.

fwiw, I did test this before reverting and while the first one (calculation
of tm) does something, the second one (double t = HIST_DELTA...) causes the
pointer to be stuck in the upper left corner of the screen when the
parameters are reversed. I suspect that there is something else that's not
quite right.

> I'll submit a new patch after I'm confident that's the only thing missing.
thanks, much appreciated.

Cheers,
  Peter



More information about the xorg-devel mailing list